Page 1 of 1
Urgent *In Sequential file ^@ junk characters are coming**
Posted: Tue Apr 12, 2011 11:38 pm
by dsscholar
Hi All,
In My source sequentail file i am getting ^@ characters afters column value and also in between.so i have tried through convert function convert(convert(lnk_non_cardinal_invoice_line.DEPT_NUM,CHAR(10),' '),CHAR(13),' ') but again lookup failed and reject file contains the same characters also it is a single character in unix so mgt be the ascii value is wrong also i have tried through somore ascii values alos like chr(64),chr(94)... but again not worked can anyone plz help me out to resolve thiss issue.
Posted: Wed Apr 13, 2011 1:55 am
by ray.wurlod
1. It's not urgent for us.
2. Please explain why this question falls under the heading "data quality best practices" or post it in the correct forum.
3. ^@ (or Ctrl-@) characters are not junk. These are ASCII NUL characters, presumably padding Char fields based on the string pad character environment variable.
Search DSXchange for more information.
Posted: Tue Jan 03, 2012 4:41 am
by manoj_23sakthi
HI,
Use trim A function with below junk character it will remove all occurances
Thanks & regards,
manoj kumar
Posted: Tue Jan 03, 2012 7:39 am
by chulett
Off we go to where I think this belongs based on your posting history.
Posted: Tue Jan 03, 2012 7:49 am
by pandeesh
This is the one liner you require in Filter option in sequential file stage:
Code: Select all
echo hi^@ghgh@^|sed -e 's/\^//g' -e 's/\@//g'
highgh
Posted: Tue Jan 03, 2012 8:00 am
by pandeesh
How you are doing in Convert()?
works good for me,
Posted: Tue Jan 03, 2012 8:00 am
by chulett
No, it's not. Re-read Ray's post, specifically point #3. Those are representations of a single character, not a "^" character followed by an "@".
Posted: Tue Jan 03, 2012 8:07 am
by zulfi123786
pandeesh wrote:Code: Select all
echo hi^@ghgh@^|sed -e 's/\^//g' -e 's/\@//g'
highgh
The ^@ character what the user dsscholar speaks about is not a combination of '^' followed by '@' characters. Its actually a single nonprintable character which appears to be '^@' so the sed code wouldn't work
Posted: Tue Jan 03, 2012 8:08 am
by zulfi123786
Oops Craig for the second time reached while i was typing
![Wink :wink:](./images/smilies/icon_wink.gif)
Posted: Tue Jan 03, 2012 8:37 am
by pandeesh