Parameters to Apex RESTful service

I am having issues getting parameters to pass to a region I have published as REST. I am using the following URL:
http://apex:8000/apex/apex_rest.getReport?app=145&page=2&reportid=RestTest&parmvalues=P2_ID,1969&output=xml
And I have the SQL for the report defined as:
select * from accounts
where id=nv('P2_ID')
or nv('P2_ID') IS NULL
The report runs and filters fine from the web page, but does not honor the parameter when passed as above.
Any thoughts?
This is Apex 4.0.0.00.46
Randy

Hi Randy,
I was having a similar issue to yours and wondered if you made any progress with it?
I have a test report based on this SQL :
select empno,ename,job,mgr,hiredate,sal,comm,deptno
  from empwhich when enabled for RESTful access I can get the data just fine with this :
http://<server>/apex/apex_rest.getReport?app=39830&page=16&reportid=111however if I add a hidden page item (P16_DEPTNO) and use that in the SQL :
select empno,ename,job,mgr,hiredate,sal,comm,deptno
  from emp
where deptno = :P16_DEPTNOand change my RESTful URL to :
http://<server>/apex/apex_rest.getReport?app=39830&page=16&reportid=111&parmvalues=P16_DEPTNO,10then I get an error :
The requested URL /apex/apex_rest.getReport was not found on this server
The page works fine when viewed normally so i don't think there are any page errors.
Any ideas?
Thanks,
Steve

Similar Messages

  • Calling Apex restful service in android

    Hi frnds i have created apex restful service, now i want to access it in android...
    So any one can help me how to call restful services using ksoap2.jar

    I got solution using HttpClient, but i can acces only "GET" method of restful services
    But how to access Restfukl service using "POST" method
    here is my code that i use to access rest service using "GET"
    String url = "http://198.16.11.12:2000/apex/jigar/mr/employees/10";
    HttpClient httpclient = new DefaultHttpClient();
    HttpGet hg = new HttpGet(url);
    HttpResponse response = httpclient.execute(hg);
    str = inputStreamToString(response.getEntity().getContent());
    Now insted of GET when i use POST to access service it returns null, what can be my URl in case of post?

  • Mutliple Query String input to APEX RESTful Services

    Does Oracle APEX (latest version via APEX Listener) support passing in multiple query string parameters to support a restful service query? E.g.
    http://ofmindus.induscorp.com:7000/apex/servicetest/animals/dogs/spot
    http://ofmindus.induscorp.com:7000/apex/servicetest/animals/dogs?name=spot
    http://ofmindus.induscorp.com:7000/apex/servicetest/animals/dogs?name=spot?location=Maryland
    As you can see the progression above, the last url will query a dogs table using where name = 'spot' and location = 'Maryland'. Is this possible? If so can someone explain how to setup the URI/Bind Variables? Also, if its possible, do I need templates to support each variation of the input that is possible using a priority setting to help APEX pick the right query to execute?
    Edited by: user2777903 on Feb 11, 2013 10:19 AM

    Hi Nilesh,
    We tried to connect to Oracle Cloud Database using the way you suggested above, but unfortunately it is not working as well.
    Can you let us know the authentication process with Oracle Cloud Database? We found in documentation that it uses OAM (Oracle Access Manager) for authentication. Can you tell us a bit about that? That will be extremely helpful.
    Thanks,
    - Neeraj

  • Apex restful service on localhost

    I have install Apex 4.2.1 on 11g o my localhost
    while creating a restful services i am not getting "test" and "bind variable" buttons.
    and i can't access the restful service.. please give me some idea
    Edited by: 980054 on Jan 5, 2013 1:33 AM

    Hi
    I have installed oracle 11g on a new PC, and install apex but still the problem remains same, TEST button is hidden.
    I start apex listener in standalone mode
    C:\Temp>java -jar apex.war
    Jan 17, 2013 2:33:48 PM oracle.dbtools.standalone.Standalone execute
    INFO: NOTE:
    Standalone mode is designed for use in development and test environments. It is
    not supported for use in production environments.
    Jan 17, 2013 2:33:48 PM oracle.dbtools.standalone.Standalone execute
    INFO: Starting standalone Web Container in: C:\Temp\temp\apex
    Jan 17, 2013 2:33:48 PM oracle.dbtools.standalone.Deployer deploy
    INFO: Will deploy application path = C:\Temp\temp\apex\apex\WEB-INF\web.xml
    Jan 17, 2013 2:33:48 PM oracle.dbtools.standalone.Deployer deploy
    INFO: Deployed application path = C:\Temp\temp\apex\apex\WEB-INF\web.xml
    Jan 17, 2013 2:33:48 PM oracle.dbtools.common.config.file.ConfigurationFolder l
    gConfigFolder
    INFO: Using configuration folder: C:\Temp\temp\apex
    Configuration properties for: apex
    cache.caching=false
    cache.directory=/tmp/apex/cache
    cache.duration=days
    cache.expiration=7
    cache.maxEntries=500
    cache.monitorInterval=60
    cache.procedureNameList=
    cache.type=lru
    db.hostname=localhost
    db.password=******
    db.port=1521
    db.sid=xe
    debug.debugger=false
    debug.printDebugToScreen=false
    error.keepErrorMessages=true
    error.maxEntries=50
    jdbc.DriverType=thin
    jdbc.InactivityTimeout=1800
    jdbc.InitialLimit=3
    jdbc.MaxConnectionReuseCount=1000
    jdbc.MaxLimit=10
    jdbc.MaxStatementsLimit=10
    jdbc.MinLimit=1
    jdbc.statementTimeout=900
    log.logging=false
    log.maxEntries=50
    misc.compress=
    misc.defaultPage=apex
    security.disableDefaultExclusionList=false
    security.maxEntries=2000
    db.username=apex_public_user
    Using JDBC driver: Oracle JDBC driver version: 11.2.0.3.0
    Jan 17, 2013 2:33:50 PM oracle.dbtools.rt.web.SCListener contextInitialized
    INFO: Oracle Application Express Listener initialized
    Application Express Listener version : 2.0.0.354.17.06
    Application Express Listener server info: Grizzly/1.9.49
    Jan 17, 2013 2:33:50 PM com.sun.grizzly.Controller logVersion
    INFO: GRIZZLY0001: Starting Grizzly Framework 1.9.49 - 1/17/13 2:33 PM
    Jan 17, 2013 2:33:50 PM oracle.dbtools.standalone.Standalone execute
    INFO: http://localhost:9999/apex started.
    http://localhost:9999/apex - gives blank page
    and
    http://localhost:9999/apex/listenerconfigure - gives 404 page not found
    Edited by: 980054 on Jan 17, 2013 1:09 AM

  • Build form and report on APEX RESTful service on another server

    Hi guys,
    I have been stuck with this for long time.
    I have this web service on server A ( an exposed report as web service )
    http://brown.maxapex.com/apex/apex_rest.getReport?app=112&page=8&reportid=REST
    - I exe this command on server A
    select utl_http.request('http://apex.oracle.com') from dual;
    and did not get error which indicates that the Network resources are available.
    I need to build a form and report based on that service on server B. But I could not. Can you help pls ??
    work space : fam
    user: test
    password: test
    Application 49141
    user: fateh
    password: fateh
    Regards,
    Fateh

    Hi guys,
    Pls, answer my questions. I am at the final stage of the game ..
    Regards,
    Fateh

  • How to test RESTful service?

    Hello Everyone!
    Working on APEX REST services, my query is in regard with the below link:
    http://docs.oracle.com/cd/E37097_01/doc/doc.42/e35128/restful_svc.htm#autoId6
    In the above link, heading '5.5.2 Retrieving Data Based on a Parameter (employees/{id})' -> points from 1. -to- .8 are covered.
    Stuck on point '9. Click Set Bind Variables.', I cannot find this link on that page under my Development environment Application Express 4.2.0.00.27.
    Kindly help to locate this link so that I can test my service?
    For more clarity, please click below image link
    http://www.oracle.com/webfolder/technetwork/tutorials/obe/cloud/dbservice/restfulws/images/t2_02.jpg
    The mouse cursor is placed at the end of the page on one of the two buttons 'Test' & 'Set Bind Variables', my development environment doesn't show these buttons. Anyone know why is this happening?
    - Krishna Vashistha

    Okay, I have got this sort out on my own.
    For the record, you must update you apex listener with new release apex_listener.2.0.5.287.04.27, which supports RESTful services. By updating you will see those two missing buttons 'Test' & 'Set Bind Variables', to test your newly created service.

  • RESTful Service Search Parameters

    Hello,
    I am using APEX 4.2.2 .. with Listener 2.0.3
    I want to expose  data in EMP table as RESTful Service with parameters:
    The source is:
    Source Type :SQL query .
    Format: JSON
    select * from emp where
    (:job IS NULL OR job = :job)
    and
    (:ename is null or ename = :ename)
    URI Template:
    employeesfeed/{job}/{ename}
    If I use this URL, it works fine...
    http://oraclesrv/real_estate/property/hr/employeesfeed/MANAGER/BLAKE
    and it gives:
    {"next":{"$ref":"http://oraclesrv/real_estate/property/hr/employeesfeed/MANAGER/BLAKE?page=1"},"items":[{"empno":7698,"ename":"BLAKE","job":"MANAGER","mgr":7839,"hiredate":"1981-04-30T20:00:00Z","sal":2850,"deptno":30}]}
    But, as you may notice from the Source logic, the "end user" should be able to retrieve all MANAGERS using this Link.
    http://oraclesrv/real_estate/property/hr/employeesfeed/MANAGER/null
    But, it gives:
    {"items":[]}
    So, How can I retrieve all Managers ?? ( using that Source ).
    Regards,

    The the four letters (n,u,l and l) at the end of your URL happen to be a string of length 4.
    Basically, you doing this comparison:
    'null' is null (which is false)
    If you want to keep that syntax, add
    or upper(:job) = 'NULL'
    MK

  • APEX Listener 2.0 - RESTful Services Failure with  404 - Not Found

    Versions used:
    * APEX Listener 2.0.0.354.17.05
    * Application Express 4.2.1.00.08
    * Oracle Database 11.2.0.1
    When testing the sample RESTful Service Module oracle.example.hr I always get 404 - Not Found page.
    I followed the documentation to install and configure APEX 4.2 and the Listener 2.0. Everything in my APEX installation works fine except RESTful Services.
    For example, when calling this RESTful Service:
    http://company.com:45678/apex/DEV/xxuapex/hr/empinfo/
    I get a 404 page.
    The corresponding entry in url-mapping.xml is:
    <pool base-path="/DEV" name="od01" workspace-id="xxuapex"/>
    where xxuapex is the name of the schema as well as the workspace where the RESTful Service is installed.
    Moreover, the corresponding od01.xml, od01_rt.xml and od01_al.xml in the conf directory seem correct.
    Any help is greatly appreciated.
    Thanks.
    Eddie Awad.

    Hi Eddie,
    +> try the other option base-url of the url-mapping+
    I did. No change. Still getting 404.When active it should transform the 404 page into a detailed 404 with a description of what the error is. Just to be sure, this is activated in the defaults.xml file of the APEX Listener as: *<entry key="log.logging">true</entry>*.
    You should then see a detailed 404 output in your browser of what's going wrong first of all.
    +> Could you post your url-mapping.xml file?+
    <?xml version="1.0" encoding="UTF-8"?>
    <pool-config xmlns="http://xmlns.oracle.com/apex/pool-config">
    <pool base-path="/DEV" name="od01" workspace-id="xxuapex"/>
    <pool base-path="/TEST" name="ot01" workspace-id="xxuapex"/>
    </pool-config>
    Despite using the url mapping script, it didn't map mine correctly and had to edit it manually. It was the use of "apex" that got it to work for me:
    *<pool base-path="/" name="apex" workspace-id="workspace-name-here" updated="2013-01-09T20:48:59.75Z"/>*
    Nick.

  • APEX post restful service inserts null value

    Oracle APEX 4.2.5
    Oracle Rest Data Service 2.0.7
    Apache Tomcat 7
    Oracle database 11.2.0.4
    Oracle APEX PUT web service inserts null value into column. This is either a bug or the documentation does not properly cover how to correctly set PUT restful services. 
    GET web services works fine. 
    I have granted the role of apex_rest_public_user to both apex_public_user and the schema owner. 
    The payload is a small xml document, but even a text document will yield the same result. 
    I am using the Oracle REST Data Service 2.0.5
    Web service code: 
    RESTful Service Module: software_details/
    URI Template: xml_parser
    Method: POST
    Source Type: PL/SQL
    MIME: Types Allowed: application/xml
    Requires Secure Access: NO
    Source :
    begin
    insert into clob_test (x)
    values (blob_to_clob(:body)); ## according to some online post,  :body is where APEX places any data being transferred through a web service. I have yet to find any official  ##documentation on it. 
    commit:
    end;
    ##Blob_to_clob function code
    CREATE OR REPLACE FUNCTION blob_to_clob (blob_in IN BLOB)
    RETURN CLOB
    AS
          v_clob    CLOB;
          v_varchar VARCHAR2(32767);
          v_start      PLS_INTEGER := 1;
          v_buffer  PLS_INTEGER := 32767;
    BEGIN
          DBMS_LOB.CREATETEMPORARY(v_clob, TRUE);
          FOR i IN 1..CEIL(DBMS_LOB.GETLENGTH(blob_in) / v_buffer)
          LOOP
             v_varchar := UTL_RAW.CAST_TO_VARCHAR2(DBMS_LOB.SUBSTR(blob_in, v_buffer, v_start));
                DBMS_LOB.WRITEAPPEND(v_clob, LENGTH(v_varchar), v_varchar);
               v_start := v_start + v_buffer;
          END LOOP;
        RETURN v_clob;
    END blob_to_clob;
    #Table code 
    create table clob_test(
    x clob));
    Thank you,

    I am experiencing the same issue.
    I implemented the 'chunked file loading' example from Kris Rice's blog at Kris' blog: August 2013 in y workspace at the Oracle hosted APEX site and everything works fine.
    However, I get a null value for 'data' when I implement the same example at my work site.
    Work Site config is
    Apache Tomcat 7
    Oracle REST Data Services version : 2.0.6.27.18.06
    Application Express 4.2.2.00.11
    Oracle RDBMS 11.2.0.3
    I am NOT using SSL at my work site. However this does not seem to affect a POST with form values.
    Varad.

  • Restful service and large parameters

    Hello, all!
    I need to create restful webservice in Apex 4.1 All is OK, but size of parameters in Apex is limited to 4KB.
    I need to pass parameters to the size of 100KB and more. How to get around this limitation?
    May be it's possible to upload files on RESTful page?
    Edited by: mmb666 on 30.08.2012 22:51

    mmb666 wrote:
    Hello, all!
    I need to create restful webservice in Apex 4.1 All is OK, but size of parameters in Apex is limited to 4KB.
    I need to pass parameters to the size of 100RB and more. How to get around this limitation?
    May be it's possible to upload files on RESTful page?What is "RB"? It's not a standard unit?

  • Restful Services and Apex

    Do I need to install apex listener in order to use the Restful Services.
    We are on apex 4.1 and use modplsql apex.
    Do I need to also install apex listener in order to use the restful services or would it be just enougt to patch 4.1 to 4.1.1 and I can continue to use apex 4.1.1 with modplsql.
    Thank you
    Kumar

    Hi Kumar,
    APEX Listener 1.1 (including your 1.1.4 installation) has a different implementation for RESTful webservices. You can access the configuration using APEX Listener's own configuration ("/listenerAdmin").
    The new APEX-integrated RESTful implementation is provided with the new APEX Listener 2, which is still in Early Adpoters phase. It comes with a patch for APEX 4.1 to make 4.1 capable of using it as well. See the installation guide for the current EA release for details.
    Since APEX 4.2 has been released now, I'd recommend to upgrade to this release instead of patching 4.1 if you don't have anything that would stop you from upgrading. And I expect APEX Listener 2 to be released soon as well, eventhough there hasn't been an official announcement yet.
    -Udo

  • How can I disable restful service only ?On Apex Listener

    Hi,all:
        For security reason,I want to disable restful data service in some of the apex listener server and enable application service only. How can I do that?

    Support give the solution:
    The way to disable restful services is NOT to configure AL and RT connection pools in ORDS/Rest Data Services.(APEX Listener).
    Remove or rename apex_rt.xml and apex_al.xml files available in the configuration directory ( conf ) used by those instances configured against ORDS / the APEX Listener.
    This way ORDS / the APEX Listener will not be able to route REST requests to the database and will return 404 to the end user

  • Getting "Origin is not allowed" When Trying to Invoke RESTful Service from Another Domain

    I am having problems trying to invoke my RESTful web service from a different domain. I'm well aware of the normal restrictions of cross-site / cross-domain scripting but in Oracle documentation it says that all origins are allowed by default when creating a RESTful service without using authentication.
    I have created a very simple service and am trying to invoke it using jQuery.Ajax calls from a different domain and I am getting XMLHttpRequest cannot load http://address_to_my_web_service. Origin http://calling_from_address is not allowed by Access-Control-Allow-Origin.
    I understand that using JSONP instead of JSON is actually the best practice around cross-site scripting but it appears as though APEX does not support JSONP because with JSONP, there are URI parameters added to the base request (callback).
    I am stuck and would greatly appreciate any help.
    I'm starting to wonder if this could be a bug because Oracle documentation says all origins should be allowed when using a service that does not require authentication. I also tried to force the origin to be allowed by typing it in and also using the wildcard '*' and it still did not work.
    Thanks,
    Mark Williamson
    EDIT: It is now working after adding a URI prefix to my web service module.

    The SSL handshake works differently to a browser as it is making the connections automatically.
    The browser asks every time if you want to trust an expired certificate, and it also recommends not to. Its impractical to manually check every service call to say do you trust the certificate so the functionality doesn't exist. I doubt any integration product does this. Therefore there isn't a option to ignore the certificate if it has expired.
    This makes sence as the certificate is untrustworthy. The whole idea around SSL is trusting the site you are communicating with, all parties need to be trusted. This stops hackers from replicating their site and intercepting data.
    If the administrator of the remote site is not willing to renew the certificate, are they really interested in SSL. I suggest they expose a non SSL service.
    cheers
    James

  • RESTful Service Module and Blob column

    Hi
    I created Restful as GET with some parameters. Everythink works without blob column. When I run restful handler in blob column i had "...binary data omitted...". Is some solution to catch file from APEX web service ?
    APEX 4.2.2 on Listener 2.1 or 2.2
    Regards

    Hi,
    You cannot use Blobs directly as fields in CMP EJB, since Blob is really an open cursor to the database, and it is not serializable.
    Here's a How-to on using Blobs
    http://otn.oracle.com/tech/java/oc4j/904/content_preview.html
    You can see the code for this at the end of the page
    http://otn.oracle.com/tech/java/oc4j/904/how_to/how-to-ejb-cmpblob.zip
    Hope this helps,
    Thanks,
    Neelesh
    OTN Team @ IDC

  • Web RESTFUL service and ODI

    Hi,
    I use ODI 10.1.3.4.0 and in a new project I have to invoke Web service(department) (Web RESTFUL service).
    I would like to know if it is possible via the command OdiInvokeWebService.
    Should the opposite occur, what is the best solution?
    Thank

    mmb666 wrote:
    Hello, all!
    I need to create restful webservice in Apex 4.1 All is OK, but size of parameters in Apex is limited to 4KB.
    I need to pass parameters to the size of 100RB and more. How to get around this limitation?
    May be it's possible to upload files on RESTful page?What is "RB"? It's not a standard unit?

Maybe you are looking for