Prathiba
Active Member
UBE runs fine locally, fails on AS400 with error: SQL0104 - Token &1 was not valid Valid tokens: &2. OS400QL017 - PrepareAnd
Hi,
We are on JDE E1 8.11 SP1, Tools 8.98.3.4 on AS400 V5R4.
I have a need to write a report selecting only split lines (line numbers like 1.001, 1.002, 1.1, 1.2 etc) from Purchase Order file F4311. I built this custom report by using internal data selection that results in SQL like this:
Select *
from crpdta/F4311
where (pdnxtr <'999' and pdlnid >1 and pdlnid < 2)
OR (pdnxtr <'999' and pdlnid >2 and pdlnid < 3)
OR (pdnxtr <'999' and pdlnid >3 and pdlnid < 4)
.....
OR (pdnxtr <'999' and pdlnid >997 and pdlnid <998)
I am stopping at line 998 since I dont think we will ever have to go there. The report runs successfully in about a minute locally on a windows fat client and produces correct results. However, when I kick it off on server it errors out. The jde.log shows:
1004/9 MAIN_THREAD Mon Mar 26 13:10:25.269832 dbdrv_log.c196
OS400QL017 - PrepareAndOrDescriberepare failed. QSQLMSG *LIBL - SQL0104 - Token &1 was not valid. Valid tokens: &2
1004/9 MAIN_THREAD Mon Mar 26 13:10:25.270168 dbdrv_log.c196
OS400AG005 - DoPrepare:Statement is not prepared.
1004/9 MAIN_THREAD Mon Mar 26 13:10:25.270280 jdb_drvm.c1038
JDB9900168 - Failed to initialize db request
When I try to turn on logging and debug locally, the ER debugger just hangs and kicks me out of JDE.
Have any of you faced this problem? Also, any other suggestions to "select" only split lines?
I dont want to select all lines and do "IF/ELSE" logic to pick split lines since that adds unnecessary processing. This is more than a report, I will have additional logic for split lines that will involve file I/O etc.
Any help is greatly appreciated.
Thanks,
Prathibha
Hi,
We are on JDE E1 8.11 SP1, Tools 8.98.3.4 on AS400 V5R4.
I have a need to write a report selecting only split lines (line numbers like 1.001, 1.002, 1.1, 1.2 etc) from Purchase Order file F4311. I built this custom report by using internal data selection that results in SQL like this:
Select *
from crpdta/F4311
where (pdnxtr <'999' and pdlnid >1 and pdlnid < 2)
OR (pdnxtr <'999' and pdlnid >2 and pdlnid < 3)
OR (pdnxtr <'999' and pdlnid >3 and pdlnid < 4)
.....
OR (pdnxtr <'999' and pdlnid >997 and pdlnid <998)
I am stopping at line 998 since I dont think we will ever have to go there. The report runs successfully in about a minute locally on a windows fat client and produces correct results. However, when I kick it off on server it errors out. The jde.log shows:
1004/9 MAIN_THREAD Mon Mar 26 13:10:25.269832 dbdrv_log.c196
OS400QL017 - PrepareAndOrDescriberepare failed. QSQLMSG *LIBL - SQL0104 - Token &1 was not valid. Valid tokens: &2
1004/9 MAIN_THREAD Mon Mar 26 13:10:25.270168 dbdrv_log.c196
OS400AG005 - DoPrepare:Statement is not prepared.
1004/9 MAIN_THREAD Mon Mar 26 13:10:25.270280 jdb_drvm.c1038
JDB9900168 - Failed to initialize db request
When I try to turn on logging and debug locally, the ER debugger just hangs and kicks me out of JDE.
Have any of you faced this problem? Also, any other suggestions to "select" only split lines?
I dont want to select all lines and do "IF/ELSE" logic to pick split lines since that adds unnecessary processing. This is more than a report, I will have additional logic for split lines that will involve file I/O etc.
Any help is greatly appreciated.
Thanks,
Prathibha