I have a CSV file of attributes that I want to assign to a new CSV file and have been trying to use the FeatureMerger to assign the original attribute to the new attribute but it doesn't work, any suggestions?
I want to assign attributes from the Coreo-Output file to attributes in the new CSV file and to carry across the information. I get my data output in the unused supplier section?
Maybe a stupid question but did you fill in the right propereties in the FeatureMerger? In this image it is not clear on what attributes you're trying to merge the two streams together.
There seem to be no features coming in from the CSV reader. Can you check that the reader is configured properly. To me it's clear there are unused suppliers because there is no data to join to
There seem to be no features coming in from the CSV reader. Can you check that the reader is configured properly. To me it's clear there are unused suppliers because there is no data to join to
so the CSV file contains a single row of attribute names (see below) that I am hoping to assign from the data in the other file. I'm not sure how to check as I am new to FME? can you explain that further?
Maybe a stupid question but did you fill in the right propereties in the FeatureMerger? In this image it is not clear on what attributes you're trying to merge the two streams together.
unsure tbh!
I have attached below my test on one of the attributes 'ukHabpCode'. In the feature merger window, I wrote the requester as the destination attribute 'ukHabPCode' (where I want the other data to go) and the supplier with the text '@ReplaceString(@Value(ukHabpCode),"XX","00")' as I want to carry across the attributes from ukHabpCode (old CSV) to ukHabPCode (new file). Hope that makes sense!
Can you confirm that you have a ukHabPCode in both the Old CSV and New CSV? If so, would you mind providing a sample value for the ukHabPCode from both CSV's (for corresponding rows you'd like joined)? I see you are using a @ReplaceString function. I'm wondering if we need to ensure that is being used correctly.
Could you possibly provide a small sample of both your old and new CSV's (feel free to anonymize any values if needed)?
so the CSV file contains a single row of attribute names (see below) that I am hoping to assign from the data in the other file. I'm not sure how to check as I am new to FME? can you explain that further?
There seems to be only a row of attributenames and no rows with actual data in your csv. If there is no data in your csv there is nothing to be merged.
so the CSV file contains a single row of attribute names (see below) that I am hoping to assign from the data in the other file. I'm not sure how to check as I am new to FME? can you explain that further?
is there a transformer in FME that will allow me to assign data from the old CSV to the new attribute names? that is what I am trying to do.
so the CSV file contains a single row of attribute names (see below) that I am hoping to assign from the data in the other file. I'm not sure how to check as I am new to FME? can you explain that further?
AttributeManager or AttributeRenamer or, a bit more complicated, SchemaMapper. In the AttributeRenamer you can import your new attributenames from your csv.
yes, I do, although they are slightly different (caps in one and not the other) I want to move the data from the old UKhabPCode CSV to the new ukHabPCode. attached image below to try and show you. the original file is the Coreo_output and I want the 17 columns to be transferred to the new CSV under ukHabPCode. Thank you for your help
Does the CSV that you are reading in (the one linked to the Requestor port in your previous screenshot) have any data? As @arnovananrooij pointed out, there doesn't seem to be any features being read into FME from that CSV (no numbers coming out of the reader feature type):
If you are simply wanting to transfer attribute values from your source to your destination, you might just want to Read your source data, and a write to your destination CSV (add a CSV Writer instead of Reader) and then use something like an AttributeManger to rename/map the attributes to your destination schema.
The FeatureMerger is actually commonly used to perform a table join/merge. The result is often one dataset with all the attributes combined as illustrated here (with a FeatureJoiner, similar outcome to a FeatureMerger):
It doesn't sound like this is what you're looking for. I think simply going one way from your source dataset (Reader) to a CSV writer that points to your destination might do the trick (with an AttributeManager if you need modify any of the source attributes to match the attributes in your destination). Check out this video which demonstrates this concept: https://www.youtube.com/watch?v=hebvRLoFbVc
I hope that helps!
Does the CSV that you are reading in (the one linked to the Requestor port in your previous screenshot) have any data? As @arnovananrooij pointed out, there doesn't seem to be any features being read into FME from that CSV (no numbers coming out of the reader feature type):
If you are simply wanting to transfer attribute values from your source to your destination, you might just want to Read your source data, and a write to your destination CSV (add a CSV Writer instead of Reader) and then use something like an AttributeManger to rename/map the attributes to your destination schema.
The FeatureMerger is actually commonly used to perform a table join/merge. The result is often one dataset with all the attributes combined as illustrated here (with a FeatureJoiner, similar outcome to a FeatureMerger):
It doesn't sound like this is what you're looking for. I think simply going one way from your source dataset (Reader) to a CSV writer that points to your destination might do the trick (with an AttributeManager if you need modify any of the source attributes to match the attributes in your destination). Check out this video which demonstrates this concept: https://www.youtube.com/watch?v=hebvRLoFbVc
I hope that helps!
I tried SchemaMapper as suggested by @arnovananrooij, and it worked! thanks for your help.
I tried SchemaMapper as suggested by @arnovananrooij, and it worked! thanks for your help.
Wonderful, glad to hear that did the trick!