View previous topic :: View next topic
|
Author |
Message |
johnnymossin
New User
Joined: 12 Jan 2021 Posts: 2 Location: denmark
|
|
|
|
I trying to select some records from a ascii encoded dataset.
this is working:
INCLUDE COND=(1,5,CH,EQ,X'3031323334')
I was guessing that this should be the same, but does not select any records:
INCLUDE COND=(1,5,AC,EQ,C'01234')
maybe AC format does not work like this. but this example is very simplified, and I could really use the extra space pr line, that a C'' would give, rather than be forced to use X''. |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2135 Location: USA
|
|
|
|
1. Print your ACTUAL input field to verify this:
Code: |
BUILD=(1,5,HEX,...) |
2. According to SORT manual, in your INCLUDE/OMIT statements the format AC can be compared only to AC, and nothing else.
Sometimes reading the manual could help.
3. AC format definition: EBCDIC characters are translated to their ASCII equivalent before merging (and whatever else). Your understanding is just opposite to this definition. |
|
Back to top |
|
|
johnnymossin
New User
Joined: 12 Jan 2021 Posts: 2 Location: denmark
|
|
|
|
thanx for a very fast answer.
I did read the manual, and saw the matrix on include cond formats.
and I guessed as much, I just posted the question to be sure, since I could really use the extra space pr line.
and if AC can't be compare to C'01234', sort might have given me an error msg. |
|
Back to top |
|
|
sergeyken
Senior Member
Joined: 29 Apr 2008 Posts: 2135 Location: USA
|
|
|
|
johnnymossin wrote: |
and if AC can't be compare to C'01234', sort might have given me an error msg. |
This is not syntax error, there is no error message.
This is logical error in your algorithm. Same as
Code: |
x = 100;
y = 0;
z = x / y; |
There is no compiler error message, but the result will be not what you might expect... |
|
Back to top |
|
|
Rohit Umarjikar
Global Moderator
Joined: 21 Sep 2010 Posts: 3076 Location: NYC,USA
|
|
Back to top |
|
|
|