Skip to Main Content

ORDS, SODA & JSON in the 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!

Looking for example of GET handler with source type of PL/SQL

Anthony SanchezJan 14 2016 — edited Feb 17 2016

Hello,

I currently have a working GET handler with a source type of QUERY running in ords 3.0.  The call returns many records (hundreds and sometimes 10's of thousands) in JSON and allows the user to page through the results.

The call accepts several parameters that I simply pass into the where clause of the query behind the handler.  Data is retrieved by date range(s).

To prevent runaway queries with long date ranges, I've implemented some logic in the sql statement to limit the requester.  The requester has asked for an error to be thrown instead.  There are other limits I impose on other inputs that I need to provide useful errors for as well.

I'd like to modify the GET call to use PL/SQL type instead of QUERY type so that I can do validations on the inputs and pass back useful error messages if required, however I cannot seem to find any examples online.

Any examples (or alternatives) would be greatly appreciated.

thank you

Anthony

This post has been answered by D.C on Jan 20 2016
Jump to Answer
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Mar 16 2016
Added on Jan 14 2016
5 comments
2,533 views