Focal Point
Oracle SQL causing error in WebFocus but not SQL Nav

This topic can be found at:
https://forums.informationbuilders.com/eve/forums/a/tpc/f/7971057331/m/8281039361

April 17, 2006, 04:13 PM
Sara
Oracle SQL causing error in WebFocus but not SQL Nav
I receive the following error when executing a procedure that utilizes the SQL Wizard.

(FOC1400) SQLCODE IS 24373 (HEX: 00005F35)
: ORA-24373: invalid length specified for statement
L (FOC1405) SQL PREPARE ERROR.
0 ERROR AT OR NEAR LINE 290 IN PROCEDURE fdas5owvFOCEXEC *
(FOC205) THE DESCRIPTION CANNOT BE FOUND FOR FILE NAMED: SQLOUT
BYPASSING TO END OF COMMAND

When using SQL Navigator expected results are produced (i.e. I recieve no error). Does anyone know if there's a restriction on the size of a SQL query embedded into a procedue via the SQL Wizard? Or what exactly happens when WebFocus sends the code to the database?


WebFocus Reporting 7.1.1 Windows
April 18, 2006, 10:30 AM
S.J. Kadish
Could you send the full code for the SQL pass-through? Just as a guess you might have a problem with a Case statement, but we should see more.


Sandy Kadish
Dev: 8.2.04- PostgreSQL
Test: 8.2.04 - PostgreSQL
Prod: 8.2.04 - PostgreSQL
April 18, 2006, 11:29 AM
Sara
My code does not include any case statements, the statements are mostly aggregation functions and datatype conversions.

Due to my company's security restrictions I cannot send the actual code however I could mock up the code with fictious tables and columns though. Would that yield something you could diagnose?

Also, after some additional research I was able to narrow down to a range of characters (space not included) in a query that produced results versus throwing the above error. I found this by replicating the same exact query using unions. This leads me to believe there is a character limit somewhere?


WebFocus Reporting 7.1.1 Windows
April 18, 2006, 11:38 AM
Tony A
Sara,

Check out this document that gives info on the SQL supported. However, bear in mind that it does not cover SQL passthru.

I am not sure how long you have been using WF, but most folks find that resorting to SQL passthru provides many benefits, the most important being that WF does not change your SQL and only the target (Oracle in your case) SQL interpreter has to be satisfied.

T



In FOCUS
since 1986
WebFOCUS Server 8.2.01M, thru 8.2.07 on Windows Svr 2008 R2  
WebFOCUS App Studio 8.2.06 standalone on Windows 10 
April 19, 2006, 11:49 AM
KevinG
Sara,

We use DB2 and dynamically build most of our SQL statements based on parameter values. There is a limit to the size of the SQL statement we can pass (about 64kb)through the SQL Engine in WF. Some of our longer queries, have had to be rewritten using 2 or 3 charater aliases, rather than the full table names. I don't know if this is what you are running into or not, but if the query is lengthy, try shortening it using aliases.


WF 7.6.10 / WIN-AIX
April 20, 2006, 02:16 PM
Sara
Tony, great document...thanks so much!

Kevin, I found reducing the aliases alleviated the problem as well...thanks so much for your input!


WebFocus Reporting 7.1.1 Windows