What is your error, what version are you using, and does your procedure have arguments?
Procedure invocation is similar to Entity invocation, try http://localhost:8080/odata/abcViewVDB/abc.abcView
if you have parameters
I am querying through OData like this:
http://localhost:8080/odata/vdbname/Procedures?$filter=para1 eq '123' and para2 eq 'ABC'
TEIID31118 Element "para1" is not defined by any relevant group.
I am using Teiid 8.4.0
I am passing two arguments in my procedure.
Use of $filter during the procedure invocation is not part of the OData specification, although it mentions that some providers may have extensions like that, however Teiid does not provide it extension currently. If you think that is very useful feature, then you can log an enhancement request in Teiid JIRA.
I am able to get the data through the way you told me only if i change my view as a table.
Meaning Database(Stored Procedure) > Source (Stored Procedure in Teiid)>View(Table in Teiid)>odata.This is working .
But if View is a Procedure then because i am not able to tag any column as primary key , i am not getting any data there.
> But if View is a Procedure then because i am not able to tag any column as primary key , i am not getting any data there.
Procedures do not have a concept of a primary key.
Did you try calling it without using the filter argument as Ramesh suggested?
ya i have tried that but it's not working.
I guess because usually when i create VDB for table after hitting http://localhost:8080/odata/vdbname
It shows my view table like this:
but in case of procedure , i am not getting any data collection like this.
> ya i have tried that but it's not working.
What's not working about it?
> but in case of procedure , i am not getting any data collection like this.
I see that locally as well. I'll have to check whether it's expected for a procedure with a resultset to report that result set as a collection. My guess is that it's not as that would be something like our procedureal relational feature that automagically treats procedures like they are tables.
If you issue a metadata query:
You should see the procedure in that output:
<FunctionImport Name="abcView" ...>