Skip to Main Content

NoSQL Database

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

sql prepared statement error

Eric JingMar 18 2020 — edited Mar 27 2020

Dear sir,

I got an error when try to compile the prepared statement:

'declare $age integer; $vcount integer; select count(*) from userTable into $vcount where age >$age'

If it's impossible to use 'into $v' within above select count statement, then I have to write some post processing code in java to get the number of the results after executing above query(which may not be the most optimized way)

Could you give me some tips of how to use select count(*) from userTable into v (a variable)? Thank you.

This post has been answered by Gmfeinberg-Oracle on Mar 23 2020
Jump to Answer
Comments
Post Details
Added on Mar 18 2020
3 comments
498 views