Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
I am attempting to run a stored procedure in and bring back the entire file it generates. I’ve turned on my read/writein the preferences>security tab. Sofar I’ve gotten this far on the syntax with the help of the forums:
ODBC CONNECT TO [Database]
Load *;SQL
Execute
[Schema].[Procedure] (##, NULL, V_Field);
exit script;
The error I am getting is:
SQL##f - SqlState: 37000, ErrorCode: 0, ErrorMsg:[Oracle][ODBC]Syntax error or access violation.
SQL
What should my next steps be?
What line is generating the error?
The double hash looks odd to me, but I'm not very familiar with Oracle. Is that actually what you're including, or is it a placeholder to avoid exposing business information (I assume you don't *really* have a schema named Table and a stored procedure named Procedure)?
What do you get if you run that exact SQL statement directly in your database?
The error is a direct copy from the error box, no alterations. And you are right, … is actually a schema, correction made.
So the query runs OK in Toad? Hmm.
Like I said, I'm not very familiar with Oracle, but what leaps out are the parameters you're passing. What does a double hash represent in PL/SQL? Here's a laugh: I Googled "oracle sql "double hash"" and this thread is the first result - fast work, Google! The only thing I've found suggests that "##" represents the beginning of a comment, like "//" in C++ or "--" in ANSI SQL. If this is the case in PL/SQL, you'd have an unmatched parenthesis.
Also, V_Field looks like a field or variable name, and therefore will be undefined in this context. Unless V_Field is some kind of Oracle magic keyword?
Do you get any results if you use a simpler sproc with no parameters?