× 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.


  • Subject: RE: EDTCDE(Z) in a alfa field
  • From: Joel Fritz <JFritz@xxxxxxxxxxxxxxxx>
  • Date: Wed, 7 Jul 1999 08:51:19 -0700

Check out the %editc() built in function.  You pass it a number and an edit
code and it returns a character string formatted according to the rule for
that edit code.  E.g. eval numericchar = %editc(number : 'Z').  If number is
56, the value of numericchar would be ' 56' assuming numericchar is 3 bytes
long.  %trim() takes care of leading or trailing blanks.  You can also
concatenate the results of %editc() directly without putting them in a
temporary variable.  E.g. eval title = %trim(%editc(population : 'J') + '
Warthogs Weren't Enough'.

###########################################
The above is my personal opinion and is not intended to represent good
programming practice or the product of a sound mind.

Joel Fritz 

> -----Original Message-----
> From: Silvio Santos [mailto:Silvio.Santos@brainag.com]
> Sent: Wednesday, July 07, 1999 4:10 AM
> To: 'RPG400'
> Subject: EDTCDE(Z) in a alfa field
> 
> 
> I have an integer (3,0) that I need to CONCAT with another 
> field to send to the screen as an alfa field.
> When I do a MOVELVNT VALF, if my variable as the value "56" 
> when it will happens that the VALF will 
> have the "056" value. My question is how can I eliminate the 
> "0" and therefore have the value "56 " in VALF ?
> 
> TIA,
> Silvio.
> 
> 
> 
> 
> 
> 
> 
> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * 
> * * * * * *
> * This is the RPG/400 Discussion Mailing List!  To submit a 
> new         *
> * message, send your mail to "RPG400-L@midrange.com".  To 
> unsubscribe   *
> * from this list send email to MAJORDOMO@midrange.com and 
> specify       *
> * 'unsubscribe RPG400-L' in the body of your message.  
> Questions should *
> * be directed to the list owner / operator: 
> david@midrange.com          *
> * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * 
> * * * * * *
> 
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
* This is the RPG/400 Discussion Mailing List!  To submit a new         *
* message, send your mail to "RPG400-L@midrange.com".  To unsubscribe   *
* from this list send email to MAJORDOMO@midrange.com and specify       *
* 'unsubscribe RPG400-L' in the body of your message.  Questions should *
* be directed to the list owner / operator: david@midrange.com          *
* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *


As an Amazon Associate we earn from qualifying purchases.

This thread ...


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.