Skip to main content
Question

FTP Caller won't upload a file without a hardcoded file path


nedwaterman
Contributor
Forum|alt.badge.img+9

Hi,

I'm using the FTPcaller to upload data on a weekly basis. In order to preserve data already posted, the new file has an changing date in the file name.

I've configured the Transfer > URL portion of the FTPCaller to accept an attribute value which works fine. However, when I try and do this with the Upload From A File > File To Upload portion, the FTPCaller fails, saying it cannot find the file:

imageimageimageAny idea what I am doing wrong?

9 replies

nielsgerrits
VIP
Forum|alt.badge.img+54

Not sure as I did not test this, but maybe is is a simple as adding one or two extra backslashes in the fileLink attribute, as it is also an escape character and the log only shows one?


nedwaterman
Contributor
Forum|alt.badge.img+9
  • Author
  • Contributor
  • January 17, 2024

Hi Niels,

Sadly not as FME cannot still find the file even with the escapaed backslashes:

image


nedwaterman
Contributor
Forum|alt.badge.img+9
  • Author
  • Contributor
  • January 17, 2024

I have just fixed this using an AttributeManager rather than a AttributeCreator. I didn't have to escape the backslash so all good. Thanks for your help!


nielsgerrits
VIP
Forum|alt.badge.img+54
nedwaterman wrote:

I have just fixed this using an AttributeManager rather than a AttributeCreator. I didn't have to escape the backslash so all good. Thanks for your help!

Nice! Thanks for the feedback.

 

Really puzzled. Can you please retest if this does not work with an AttributeCreator? Copy pasting the line from the manager to the creator? What version do you use?

 

Personally, I never use the AttributeManager (I can't stand the red cog when changing the attributestructure upstream...) so I wonder why this is happening.


nedwaterman
Contributor
Forum|alt.badge.img+9
  • Author
  • Contributor
  • January 17, 2024
nielsgerrits wrote:

Nice! Thanks for the feedback.

 

Really puzzled. Can you please retest if this does not work with an AttributeCreator? Copy pasting the line from the manager to the creator? What version do you use?

 

Personally, I never use the AttributeManager (I can't stand the red cog when changing the attributestructure upstream...) so I wonder why this is happening.

Ah so, the issue seems to be not the ButeManager / ButeCreator but the fact I was readiing in the filepaths from a csv I had created with Excel.

Using the FeatureReader to pull these out, and then using the AttributeCreator to create the entire file path results in the FTPCaller not finding the file:

image.pngimageimageimageOdd!

 


nielsgerrits
VIP
Forum|alt.badge.img+54
nielsgerrits wrote:

Nice! Thanks for the feedback.

 

Really puzzled. Can you please retest if this does not work with an AttributeCreator? Copy pasting the line from the manager to the creator? What version do you use?

 

Personally, I never use the AttributeManager (I can't stand the red cog when changing the attributestructure upstream...) so I wonder why this is happening.

Happy to hear the issue was not solved by the AttributeManager :S :D

 

I think you should check if your CSV reader does interpretation of the field types, I think this is the case as it is default. This might result in an incorrect attribute type for what you want. You can set it manually to string.


nedwaterman
Contributor
Forum|alt.badge.img+9
  • Author
  • Contributor
  • January 17, 2024
nielsgerrits wrote:

Nice! Thanks for the feedback.

 

Really puzzled. Can you please retest if this does not work with an AttributeCreator? Copy pasting the line from the manager to the creator? What version do you use?

 

Personally, I never use the AttributeManager (I can't stand the red cog when changing the attributestructure upstream...) so I wonder why this is happening.

Thanks Niels, good to know! I will check that for the future.

nielsgerrits
VIP
Forum|alt.badge.img+54
nielsgerrits wrote:

Nice! Thanks for the feedback.

 

Really puzzled. Can you please retest if this does not work with an AttributeCreator? Copy pasting the line from the manager to the creator? What version do you use?

 

Personally, I never use the AttributeManager (I can't stand the red cog when changing the attributestructure upstream...) so I wonder why this is happening.

This part.

CsvParameters


nedwaterman
Contributor
Forum|alt.badge.img+9
  • Author
  • Contributor
  • January 17, 2024
nielsgerrits wrote:

Nice! Thanks for the feedback.

 

Really puzzled. Can you please retest if this does not work with an AttributeCreator? Copy pasting the line from the manager to the creator? What version do you use?

 

Personally, I never use the AttributeManager (I can't stand the red cog when changing the attributestructure upstream...) so I wonder why this is happening.

Hi Niels,

Thank you - I did alter that part and am now testing.


Reply


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