Skip to Main Content

Oracle Developer Tools for Visual Studio

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!

Interested in getting your voice heard by members of the Developer Marketing team at Oracle? Check out this post for AppDev or this post for AI focus group information.

Dataset Tableadapter Parameter Usage - Not All Variables Bound

Da2u4nowDec 17 2012
In VS 2010 with Oracle 11G, this simplified SQL pseudo example works fine now with two parameters and is indicated by the tableadapter GUI with getdata (PARAM1, PARAM2).

Select fname, lname from as_person where person_type = 'A' and person_id = ? union select fname, lname from as_person where person_type = 'B' and person_id = ?

The table adapter configuration wizard shows the SQL as above and works when doing a preview providing two parameters. The query builder window shows the SQL as below and works when doing an execute query providing two parameters.

Select fname, lname from as_person where person_type = 'A' and person_id = :PARAM1 union select fname, lname from as_person where person_type = 'B' and person_id = :PARAM2

This difference in SQL representation coming from the same object plus the parameter marker characters usage is a bit confusing. I am trying to design SQL that can use the same parameter in multiple spots like

Select fname, lname from as_person where person_type = 'A' and person_id = :PARMSAME union select fname, lname from as_person where person_type = 'B' and person_id = :PARMSAME

Any help or enlightenment appreciated.

Note that the following link represents some of my travel http://www.fullstackbusinessdesign.com/forums/ORA-01008.html
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jan 14 2013
Added on Dec 17 2012
0 comments
820 views