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



On 11/21/2016 4:23 PM, Justin Taylor wrote:
I've spent two hours on this, and I figure it out five minutes after posting the question. I guess I just needed to spell out the problem.

The 'cardboard analyst' strikes again :-)
http://imho.midrange.com/2005/12/18/cardboard-analyst/

I'm concatenating the column values together into a single varchar() variable. After each row is processed, I set the varchar() variable to blank (myVar = *blank;). Apparently that also pads myVar with blanks so the next time I try to append a new value (myVar += columnValue;) nothing happens. I can't believe I've never encountered this before.

I got burnt by this long ago, when varying was first introduced. Harsh
lesson, but still never forgotten :-/

For those following along in the archives:

dcl-s thisVar varchar(25);
// load 25 blanks into thisVar
thisVar = *blanks;
// clear thisVar
thisVar = '';


As an Amazon Associate we earn from qualifying purchases.

This thread ...

Follow-Ups:
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.