Archive for the 'SQR' Category

Writing an SQR output to a custom file and post it to web

The background of the issue is in older versions of PeopleSoft SQR programs used to execute from a client workstation and there was no 4-tier concept, so People used to hardcode the output file path with in the program.
PeopleSoft 8 onwards reports are being posted to web and people can view the reports in the [...]

SQL Error = (226) TRUNCATE TABLE command not allowed within multi-statement transaction.

The below error was came up when one of my colleague was trying to truncate a table with in an SQR procedure. I don’t know whether this is a Sybase specific or for all the databases.
SQL Error  = (226) TRUNCATE TABLE command not allowed within multi-statement transaction.
The Solution is to COMMIT before and after the [...]

(SQR 4045) Function or operator ‘dateadd’ requires date

(SQR 4045) Function or operator ‘dateadd’ requires date argument. The above error will show up if you use dateadd function in SQR and didn’t declare the variable as date. use the following example.
declare-variable
date $sunday
end-declare
….let $date1 = dateadd($sunday,’minute’,1)