This content has been marked as final. Show 8 replies
I checked that article however I think I might be able to do what I want using ADF BC.
See, what I'm trying to do is to get a record from a database and show it to the user on the initiator UI.
I have been able to work with ADF BC and View Objects to get all the rows and show them to the user in a table.
However, when I try to run the same query in the parameterized form to just return a single row, I hit a wall.
In short, My problem is like this:
I have an Application Module which has an entity object and a view object.
My database is SQL Server 2008.
when I try to create a new read only view object to return a single row I face the problem.
The query I have in the query section of my View Object is like this:
which works fine.
select * from dbo.Employee where EmployeeCode= 99
However when I define a bind variable, input_code for example, and change the query to the following it won't validate.
It just keeps saying
select * from dbo.Employee where EmployeeCode= :input_code
incorrect syntax near ":"I don't know if this has to do with my DB not being Oracle or I'm doing something wrong.
Can you help me with this problem please?
nope! doesn't work! :(
done all variants.. gap after the equal sign, gap before .. gap on both ends...
I don't think that has anything to do with the gap.
One thing I noticed is my Binding Style is JDBC Positional, which can not be changed. It may be though to the fact that my DB is SQL Server.
I don't know if that has anything to do with it though!
My problem was solved in the following thread:
ADF BC connection to SQL Server with parameterized variable for View Object
I should've used the '?' instead of ':' since my DB was SQL Server.
select * from dbo.Employee where EmployeeCode= ?