Jonathan
-----Original Message-----
From: midrange-l-bounces+jonathan.mason=astradyne-uk.com@xxxxxxxxxxxx
[mailto:midrange-l-bounces+jonathan.mason=astradyne-uk.com@xxxxxxxxxxxx] On
Behalf Of Silva Marco
Sent: 14 September 2007 08:25
To: Midrange Systems Technical Discussion
Subject: RE: Query> if then else in queries.
Hi. How can I do that is AS/400 using the STRQRY
Obrigado,
Marco Silva
-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Jonathan Mason
Sent: sexta-feira, 14 de Setembro de 2007 1:02
To: 'Midrange Systems Technical Discussion'
Subject: RE: Query> if then else in queries.
Hi Marco
Create a second file to be used as a cross reference. It should just
have
two fields on each record, a FROMCODE and a TOCODE. Use DFU to add two
records to the file, one with a FROMCODE = '*' and a TOCODE = '1' and
another with a FROMCODE = ' ' and a TOCODE = 'N'.
In your query join file RECEIVED to this new cross reference file using
FROMCODE and the original code field from file RECEIVED as the join key.
Select field TOCODE for output in your report.
Hope it helps
Jonathan
-----Original Message-----
From: midrange-l-bounces@xxxxxxxxxxxx
[mailto:midrange-l-bounces@xxxxxxxxxxxx] On Behalf Of Silva Marco
Sent: 14 September 2007 00:47
To: Midrange Systems Technical Discussion
Subject: Query> if then else in queries.
Hello,
I need your help once again.
I have to create a query, but in that in that query I have to create a
new field.
The condition is: in filed RECEIVED If I have this * I want that appears
1 (can be a digit and not a number) if the field is blank or has nothing
I want to appear N
Example:
*=1
'blank'=N
'blank' means that the field has nothing on it.
Is it possible?
Best Regards,
Marco
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact
[javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.