× The internal search function is temporarily non-functional. The current search engine is no longer viable and we are researching alternatives.
As a stop gap measure, we are using Google's custom search engine service.
If you know of an easy to use, open source, search engine ... please contact support@midrange.com.



Hi,
  here is my select statement:
SELECT NUMBER FROM DLESTER/RSFILE WHERE CURRENCYISOCD = 'USD'
I get Number = 2 when I execute this SQL statement.
----------
So I have to insert 2 spaces after period (0.) in the eval statement....
My eval statement is as below:
eval M_MSGDATA 
= 
%trim(%editw(+ 
X_AUTHAXY:' , , , , , 0 . -')) 

To make it more clear

eval M_MSGDATA 
= 
%trim(%editw(+ 
X_AUTHAXY:' , , , , , 0 .(onespace)(onespace)-')) 

It is hard coded in my program with 2 spaces after period.
Depending on the NUMBER value after executing SQL statement it should give that 
many spaces after the period.

Eg:
If the NUMBER value after executing SQL statement is 1 then I should insert 1 
space after the period.
If the NUMBER value after executing SQL statement is 3 then I should insert 3 
spaces after the period. With 3 spaces it look like below:

eval M_MSGDATA 
= 
%trim(%editw(+ 
X_AUTHAXY:' , , , , , 0 .(onespace)(onespace)(onespace)-'))


  Please help me get logic to make it work by imbedding SQL in my RPGLE.
   
  Thanks
  Donna.

 
---------------------------------
Sponsored Link

Degrees for employed people - in as fast as 1 year. A.S. / Bachelors / Masters

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:

Follow On AppleNews
Return to Archive home page | Return to MIDRANGE.COM home page

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.