Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

recursive escape sequence

Hi,

I have a context variable for an input directory defined like so:

input_dir = d:\\ref_data\input\

 

This context variable is used by other components such as tFileList, tFileCopy etc. I have hit a problem with this:

Talend is reading the value of this context variable as(in words) - letter D, followed by colon, followed by backslash-r, now backslash-r or \r is the Java escape sequence for carriage return, so if I print out my context variable, the output is:

d:<blank spaces                                                                                                                                                                      >

ef_data\input. So it seems that after \\ is interpreted to mean a single backslash, that single backslash is then combined with r to create \r. Instead , I do not want to escape r, r should be taken literally as it is. How do I go about this.

 

Strangely, I tried the java filename format d:/ref_data/input, that only works in Talend Data Fabric Studio, once scheduled in Talend Administration Center, that doesn't work anymore as it seems TAC is expecting the Windows/DOS filenames.

 

Thanks.

 

 

Labels (4)
1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

In Java \ is a control character. You need to escape it with another \

C:\\\\refdata\\somefolder

In Talend / should work as well. Where in TAC is / not working. Can you put screenshots, logs etc?

View solution in original post

1 Reply
Anonymous
Not applicable
Author

In Java \ is a control character. You need to escape it with another \

C:\\\\refdata\\somefolder

In Talend / should work as well. Where in TAC is / not working. Can you put screenshots, logs etc?