[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index]
[Date Index]
[Thread Index]
[SQR-USERS Info]
[SQRUG Home Page]
Re: Upward Compatibility of SQR Versions
On Fri, Jul 02, 1999 at 09:37:21AM -0400, White, Denise wrote:
> one version of SQR running for both systems. He plans to do some testing of
> the ERP SQRs, but he assumes that any SQR written in version 2 or 3 will run
> successfully in version 4. I have heard at a PeopleSoft User Group meeting
> that it is extremely important to thoroughly test every SQR program, which
> leads me to believe there may be some incompatibilities. Can anyone shed
> some light on this issue?
Yes, there are some incompatibilities, and you should plan to spend a
little time making the switch.
Most of the changes are very simple, and involve compile-time error
messages. Thus, you can simply set up a batch job to do an "sqr -rs" on
all of your source programs and look for the programs that don't
compile.
For example, if you have a
move $string_var to #num_var 9,999
command (that is, an edit mask on a move TO a #num_var),
the bogus edit mask will now cause a compile-time error.
You can simple delete the edit mask and recompile the program.
If you are doing a lot of date manipulations, moving those to SQR 4
is a little harder because sometimes the problems don't show up until
run time. It's well worth upgrading to use SQR v4's new date features,
but if you don't do thorough pre-testing you may stumble across problems
as your users run certain programs for the first time under SQR 4.
In very rare situations you may run into trouble with the new, more
precise numerice variables in SQR 4 (if your program somehow relied on
rounding errors, for example). You may need to look at DEFAULT-NUMERIC
in SQR.INI.
> One thing I have heard is that in SQR 4, you cannot do "alter session set
> nls_date_format = 'DD-MON-YYYY';". Unfortunately, I have just recently
> modified most of my SQRs to use this, after having found that my date math
> was not working correctly and was not including century in the calculations
> (another interesting decision had been made here to leave the Oracle default
> at DD-MON-YY and just program around it for Y2K compliance)! This had
> seemed by far the easiest solution - how do I do it in SQR 4?
You can still use nls_date_format; it's just that SQR 4 now does its own
conversions from date columns, ignoring this setting when you directly
select a date column into an SQR &variable.
(Thenls_date_format would still be used if you did a
begin-select
....
from XXXX
where to_char(DATE_COLUMN) like '%-1997'
end-select
Note that I'd never recommend this particular where clause; the point is
that nls_date_format might still be needed in some situations.)
The answer to your specific question is that you want to look at the
SQR.INI setting SQR_DB_DATE_FORMAT.
Nathan
----------------------------------------------------------------------------
Nathan Stratton Treadway | Ray Ontko & Co. | Software consulting services
nathant@ontko.com | Richmond, IN | http://www.ontko.com/