[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
Re: Irritating sqr error -Reply
- Subject: Re: Irritating sqr error -Reply
- From: Jim Hardesty <jhardest@LMBERRY.COM>
- Date: Wed, 27 Oct 1999 15:59:13 -0400
The problem only occurs when the variable being assigned ends in #,$ etc. So
database column names are not an issue. Unless you are assigning values to
database columns after they have been selected (shudder).
It is true that I do have the ability to name my variables other names. But I don't
really appreciate having to write code like the following just because the compiler
isn't all that smart. I don't like code with unnecessary complications just waiting
to trip someone up during the next upgrade.
Where pc.check# = #selected_check_number instead of the prettier
Where pc.check# = #selected_check#
Also, in many cases I am modifying existing peoplesoft programs and I do not
have the option of changing the variable name. Instead I am forced to use the
more efficient MOVE command instead of the slow, plodding LET command I
prefer. :)
jim
>>> the dragon <ceprn@HOTMAIL.COM> 10/27/99 03:37pm >>>
Jim,
Yes, I agree that someone was watching their tonsils when the designed the
databases, in more ways than one... However, keep in mind that if you are
ever dealing with a #variable# or $variable$ in a program, you have yourself
to blame. It's very simple to change the name of a variable as it is
selected from the database - creating a &variable that won't cause problems
and then a $variable or #variable that doesn't cause problems. No one ever
said you have to use the column name as a variable internally to the sqr.
Yes, this makes the code less confusing (in some cases), but it can also
cause processing problems.
begin-select
tbl.page# &page_nbr
tbl.line# &line_nbr
tbl.transit# &transit_nbr
let #page_nbr = &page_nbr
let #line_nbr = &line_nbr
let $transit_nbr = &transit_nbr
from ps_stoopid_over_normalized_table tbl ! :-)
where 1 = 1
and tbl.page = 67 ! don't know if this is number or character
end-select
clark 'the dragon' willis
dragon enterprises, consulting services
you wrote....
If only PS hadn't named all these fields page#, line#, transit#, etc etc
etc.
jim
______________________________________________________
Get Your Private, Free Email at http://www.hotmail.com