Skip to main content
Question

How to use AttributeJSonPacker and Unpacker

  • September 12, 2017
  • 7 replies
  • 22 views

Forum|alt.badge.img

I need to pack all the attributes of DGN file by using AttributejSonPacker but unable to expose the attribute "_packer" how can i unpacked the same?

7 replies

danilo_fme
Evangelist
Forum|alt.badge.img+45
  • Evangelist
  • September 12, 2017

Hi @dheeraj,

The custom transformer AttributeJsonPacker is prepared to receive a Json struture:

Have you tried to expose the Format Attributes from your DGN?

Thanks,

Danilo


daveatsafe
Safer
Forum|alt.badge.img+19
  • Safer
  • September 12, 2017

Hi @dheeraj,

You can expose the "_packer" attribute using the AttributeExposer transformer. I will take another look at that transformer to see if we can have it automatically expose that attribute.


Forum|alt.badge.img
  • Author
  • September 13, 2017
danilo_fme wrote:

Hi @dheeraj,

The custom transformer AttributeJsonPacker is prepared to receive a Json struture:

Have you tried to expose the Format Attributes from your DGN?

Thanks,

Danilo

Yes, I have tried to expose attribute by AttributeExposer Transformer as well but i am unable to see "_packed" attribute in list...

 

If the attribute is not visible to me then how can i unpack it again?

 

 

 


Forum|alt.badge.img
  • Author
  • September 13, 2017
daveatsafe wrote:

Hi @dheeraj,

You can expose the "_packer" attribute using the AttributeExposer transformer. I will take another look at that transformer to see if we can have it automatically expose that attribute.

I have tried with attribute Exposer but unable to get attribute in list

 

 


takashi
Influencer
  • September 13, 2017

Hi @dheeraj, the AttributeJSONUnpacker has the parameter "Attributes to Expose", so you can expose required attribute names via the parameter. Of course the AttributeExposer can also be used in the subsequent workflow alternatively.

Note that FME Workbench doesn't list automatically the attribute names that will be unpacked with the transformer. You will have to enter their names manually, if necessary.


Forum|alt.badge.img
  • Author
  • September 20, 2017
takashi wrote:

Hi @dheeraj, the AttributeJSONUnpacker has the parameter "Attributes to Expose", so you can expose required attribute names via the parameter. Of course the AttributeExposer can also be used in the subsequent workflow alternatively.

Note that FME Workbench doesn't list automatically the attribute names that will be unpacked with the transformer. You will have to enter their names manually, if necessary.

Hi, In this case i am unable to use attr1, attr2, attr3 ? either by using attribute exposer,

 

 

I just can view $_NEW_Attributes.

takashi
Influencer
  • September 20, 2017
takashi wrote:

Hi @dheeraj, the AttributeJSONUnpacker has the parameter "Attributes to Expose", so you can expose required attribute names via the parameter. Of course the AttributeExposer can also be used in the subsequent workflow alternatively.

Note that FME Workbench doesn't list automatically the attribute names that will be unpacked with the transformer. You will have to enter their names manually, if necessary.

What version (build number) of FME are you using? Possibly FME with some specific build numbers has an issue on exposing new attribute names created within a custom transformer. If the Attributes to Expose parameter in the AttributeJSONUnpacker doesn't work fine, leave the parameter empty and try using the AttributeExposer instead.

 

 


Cookie policy

We use cookies to enhance and personalize your experience. If you accept you agree to our full cookie policy. Learn more about our cookies.

 
Cookie settings