2
votes

I have created a virtual procedure in JBoss Teiid ,i want to call it using odata protocol. I have tried to call it by .....url/odata/PROCEDURE NAME

It is not working .

Can anyone please tell me the corect syntax to call stored procedure in odata.

2
could you query metadata by url/odata/$metadata ?Maya
yes. We can expose data by odata protocol.madhurika
Then, according to docs.jboss.org/author/display/TEIID/OData+Translator and docs.jboss.org/author/display/TEIID/OData+Support, stored procedure should be mapped to FunctionImport. Did you see the related FunctionImport in $metadata?Maya
Hi Maya, Thanks for your reply. Yes, we are able to see the $metadata and also FunctionImport is showing both source and view. So, looks like I just need to provide more info for you. We have a procedure that takes two parameters (both strings). Teiid returns a result set by default. We wanted actual column values to be returned. Hence we added all the required columns as per the query using which we created the stored procedure. Now, we want a odata query through which we can call that stored procedure. locahost:8080/odata/vdbname/$metadata works. Now onwards,how do I build query?madhurika

2 Answers

2
votes

I believe this will work:

http://127.0.0.1:8080/odata/<vdbname>/FunctionImportName?Parameter1Name='Parameter1Value'&Parameter2Name='Parameter2Value'
0
votes

Try locahost:8080/odata/vdbname/FunctionInportName(Parameter1Name=Parameter1Value, Parameter2Name=Parameter2Value)