Running SELECT … INTO :bind_variable from SQL | Tanel Poder Consulting #50
Replies: 1 comment
-
I had this today... Thanks for the tip! :) |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
Running SELECT … INTO :bind_variable from SQL | Tanel Poder Consulting
I just wasted a few minutes troubleshooting one of my scripts – and realized that while SELECT … INTO :bind_variable does not error out when executed as top-level SQL, it doesn’t seem to populate the resulting bind variable:
SQL> VAR blah VARCHAR2(10)
SQL> SELECT dummy INTO :blah FROM dual;
D
X
SQL> print blah
BLAH
See, the bind variable is empty…
Now, let’s run the same statement via PL/SQL engine: - Linux, Oracle, SQL performance tuning and troubleshooting - consulting & training.
https://tanelpoder.com/2011/04/10/running-select-into-bind_variable-from-sql/
Beta Was this translation helpful? Give feedback.
All reactions