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

Announcements
Join us in NYC Sept 4th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Text Enclosure and Escaping Character

TestColumn1;TestColumn2;"TestColumn3:1;TestColumn3:2";TestColumn4

the above sample data contains delimiter as data in the 3rd column and i wish to fetch the data as 

TestColumn1

TestColumn2

"TestColumn3:1;TestColumn3:2

TestColumn4

 

the main concern here is to understand the working of "Text Enclosure and Escaping Character" option in tfileInputdelimited .

it would be really helpful if someone can explain this in detail that what these 2 options works and how they works.

Labels (2)
1 Solution

Accepted Solutions
manodwhb
Champion II
Champion II

@CK395,for input :< TestColumn1;TestColumn2;"TestColumn3:1;TestColumn3:2";TestColumn4> you will get the below output.

.-----------+-----------+---------------------------+-----------.
| tLogRow_1 |
|=----------+-----------+---------------------------+----------=|
|newColumn |newColumn1 |newColumn2 |newColumn3 |
|=----------+-----------+---------------------------+----------=|
|TestColumn1|TestColumn2|TestColumn3:1;TestColumn3:2|TestColumn4|
'-----------+-----------+---------------------------+-----------'

 

 

if you wan to know more about these,try to create metadata in the repository by using CSV option and you can play with option and get to know how the would be extracted form that csv.

View solution in original post

7 Replies
manodwhb
Champion II
Champion II

@CK395,since when you enable CSV option,in  tFileInputDelimited,you can set those two options.

 

check the below link,you will understand the use case.

https://stackoverflow.com/questions/43512095/usage-of-escape-char-and-text-enclosure

Anonymous
Not applicable
Author

Hi @manodwhb ,

I am through that link already and it did not perform as it mention.

it would be helpful if you can explain it.

 

 

Regards 

Chandra Kant 

manodwhb
Champion II
Champion II

@CK395,for Text Enclosure,for suppose your filed data is in like "Hello" then you will specify the """ .

for Escaping Character,which you want to be print as part of the data.

Anonymous
Not applicable
Author

Hi @manodwhb,

You mean if the data contains  inverted commas <"$$$$$$"> then only data<$$$$$$$>  can be fetched using TextEnclosure """ and to keep some symbol within the data that must be specified as Escape Character.

 

can you specify the <Text Enclosure> and <Escape Character> for case given below and please test it in a job.

input :< TestColumn1;TestColumn2;"TestColumn3:1;TestColumn3:2";TestColumn4>

output :

Column1 Column2 Column3 Column4
TestColumn1 TestColumn2 TestColumn3:1;TestColumn3:2 TestColumn4

or

Column1 Column2 Column3 Column4
TestColumn1 TestColumn2 "TestColumn3:1;TestColumn3:2" TestColumn4

 i think it would clear some doubts.

 

 

 

Regards

Chandra Kant

manodwhb
Champion II
Champion II

@CK395,for input :< TestColumn1;TestColumn2;"TestColumn3:1;TestColumn3:2";TestColumn4> you will get the below output.

.-----------+-----------+---------------------------+-----------.
| tLogRow_1 |
|=----------+-----------+---------------------------+----------=|
|newColumn |newColumn1 |newColumn2 |newColumn3 |
|=----------+-----------+---------------------------+----------=|
|TestColumn1|TestColumn2|TestColumn3:1;TestColumn3:2|TestColumn4|
'-----------+-----------+---------------------------+-----------'

 

 

if you wan to know more about these,try to create metadata in the repository by using CSV option and you can play with option and get to know how the would be extracted form that csv.

Anonymous
Not applicable
Author

hi @manodwhb,

this one simply worked with Escape<"""> and Enclosure<"""> once I restarted the Talend but was not working previously ,

Talend might be having some processing issues.

I appreciate your helpful replies and patience.

 

 

 

Thanks and Regards

Chandra Kant 

manodwhb
Champion II
Champion II

@CK395,great, Please provide Kudos also0683p000009MACn.png