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



While it's pretty simple to write a procedure to do this, if I were going to ask for a new BIF, I'd ask for a version of the more general SQL scalar function REPEAT(string, number), e.g.

myString = %repeat("Hello " : 5)

would return "Hello Hello Hello Hello Hello ".

A bit more flexible than just returning spaces.

--
*Peter Dow* /
Dow Software Services, Inc.
909 793-9050
petercdow@xxxxxxxxx
pdow@xxxxxxxxxxxxxx /

On 7/30/2024 9:00 PM, Javier Sanchez wrote:
Team,

Honestly, I didn't want to go and look for the already posted proposals for
new TRs in RPG.

If this already exists and was rejected, just throw me a lot of rotten eggs
(LOL).

I am thinking of a new BIF: %SPACES(nSpaces)

This would help a lot to stuff in a string a number of spaces when
concatenating several pieces of other strings.

Example:

stmfString = var1 + %SPACES(50) + var2 + %SPACES(20);

The literal number of spaces can also be a variable containing a valid
positive value for the number of spaces to stuff in.

Opinions? (Or rotten eggs).

Thanks,

JS

As an Amazon Associate we earn from qualifying purchases.

This thread ...

Replies:

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.