I had found this bug a really long time ago on version 7.1.
It still exists.
I was trying Set Fields through SQL to capitalize the first letter of a word
after the 6th character so this should have returned only $1$ as a possible
choice of results.
select substr('$FieldName$', 1, 6) || initcap(substr('$FieldName$', 7)) from
dual
However, I get $1$, $2$, $3$ and $4$ to choose from. It appears like the
ARSystem API looks at every comma between select and from and thinks that
there are that many column values to return, which would explain the 4
dollar columns in the result list to choose from.
Fortunately using $1$ (which should have been the only choice to choose
from) gets me the right results.
Has anybody else reported this to BMC Support? I had reported this years ago
but it appears like it has not yet got fixed. Fortunately, back then too, I
needed just the first column so I did not have any real problem.
I have not tested to see if I need more than one column, if the $ variables
would return the right results. Also I have not tested what $2$, $3$ and $4$
holds. Probably nulls. Or may return an error at run time if you select
them.
Cheers
Joe
_______________________________________________________________________________
UNSUBSCRIBE or access ARSlist Archives at www.arslist.org
"Where the Answers Are, and have been for 20 years"