Shay Shmeltzer's Oracle Development Tools Tips

  • October 6, 2010

Passing Parameters to ADF Application through the URL

Shay Shmeltzer
Director of Product Management - Oracle

A common scenario, especially for people who are creating ADF applications that extend or integrate with other systems, is the need to call an ADF page and pass some parameters to it.

For example, suppose you are in Oracle E-Business Suite and you are looking at a department and you want to invoke an ADF page that will show you more details about this specific department.

To achieve this you can expose bounded taskflows with a URL and define parameters that the taskflow will accept on the URL line.

In the following demo I show how to create a taskflow that shows a filtered VO, and then how to call this taskflow using a URL and pass the parameter that controls the filtering.

Update - in some cases you don't need a full taskflow for this. Here is an entry that shows you a simpler approach if you just need to reference the parameter in the page itself.

Join the discussion

Comments ( 25 )
  • Jeff Wednesday, October 6, 2010
    Hi, Shay,
    I am trying to build URL to pass parameters to ADF appliecation. I asked you questions before regarding using WSDL from Peoplesoft in the web app. It is kind of working now. Thank you!
    I use 'get' method to retrieve data from Peoplesoft and need to put parameters in the URL so that user do not need to enter it. Actually they can not enter it. I watched this demo. it shows to use view object. But mine is from WSDL and I do not see operation of ExecuteWithparams and etc. How can I create task flow?
    Thank you,
  • shay.shmeltzer Thursday, October 7, 2010
    This should basically be similar in terms of setting the taskflow and parameter. Instead of using the pageFlowScope parameter. Then directly set the pageflowscope parameter as the parameter for the Webservice executable in the binding of the page - see here: http://blogs.oracle.com/shay/2009/07/java_class_data_control_and_ad.html
    No need for a method call before that.
  • guest Monday, October 18, 2010
    I created a view object to pass the parameter. The SheetId was passed to the page successfully. I use a WSDL for data control. I want to bind the 'Get' executable to the parameter. I tried:
    ${bindings.SheetId.currentRow.dataProvider} or ${bindings.SheetId.inputValue}
    It did not work. What I did wrong?
    Thank you,
  • shay.shmeltzer Monday, October 18, 2010
    Jeff - you should post this type of question on the JDeveloper OTN discussion forum where more people can help you, and you should probably explain in more details what you are trying to achieve and what you have done.
    Also - you should try and set breakpoints in your code to see what is in the ELs that you are using at the point when you call a Web service.
  • Saiful Monday, October 25, 2010
    Hi Shay,
    How I could pass the parameter from JDeveloper 10G (Run on OC4J) to JDeveloper11G (run on weblogic) since we try to run JDeveloper 10G on weblogic was not successful. Any idea?
  • shay.shmeltzer Tuesday, October 26, 2010
    Saitful - this should basically be the same thing in your ADF 10g application just have a goLink with the destination containing the full URL with parameters.
  • Subba Wednesday, December 8, 2010
    Hi Shay,
    This passing parameters through URL only work for bounded-taskflow with pages(.jspx) only. is it correct?
    But, typically ADF application home/dashboard page will be .jspx page which is in unbounded-task flow(adfc-config.xml). This home page will have a bounded task flow(which contains page fragments, .jsff) dragged as a region in it. And we can not pass parameters to unbounded task flows.
    So, if i have a ADF application with home page in adfc-config.xml, how can i pass parameters ?
    Please clarify
  • shay.shmeltzer Wednesday, December 8, 2010
    Subba, if you add a view to adfc-config.xml and click it - you'll see a parameters section in the property inspector.
    More here: http://download.oracle.com/docs/cd/E14571_01/web.1111/b31974/taskflows_parameters.htm#BACCEIAC
  • guest Thursday, August 25, 2011

    Is it possible to read a parameter from a post request instead of a get request

  • case de pariuri online Friday, November 18, 2011

    Thanks for that mate. It has been edited now.

  • karnakar Wednesday, January 11, 2012

    Hi Shay,

    this article is very useful.

    i have similar usecase.adf page url is called from the OAF page

    with some parameters like username and user group.

    but this url parameters are encrypted .how do we read those encrypted parameters know how to decrypt those parameters but where will be the code exactly? before passing ADF

  • Shay Wednesday, January 11, 2012

    Karnakar, I think this is more of a question to the OAF people to figure out how the information they pass can be decoded.

    One thing you might want to look into if you are trying to do a joint security implementation between EBS and ADF is the usage of the EBS Java SDK Kit JAAS adapter, or possibly using Oracle Access Manager to define single-sign-on between the apps.

  • Karnakar Wednesday, January 11, 2012

    Hi Shay,

    currently, we are not using OAM for SSO .URL parameters are passed to ADF with decrypted.i need to encrypt those parameters in my ADF page URL.

    where will be encryption code goes here ?

  • guest Monday, May 21, 2012

    Shay, how to do same thing when navigation is done by control-flow-rule from one page to 2nd page by af:commandLink in unbounded task flow.By using af:link its ok.

  • Shay Monday, May 21, 2012

    guest - in the af:commandLink you can add an af:setPropertyListener to set the value for the parameter in any specific scope you need.


  • guest Tuesday, May 22, 2012

    Shay,not working.I have page params in adfc-config frm yr example.



    From af:commandLink in setpropertyListener - From:#{1} & To:#{param.p1}

    giving error 'not writable property'.When To:#{viewScope.p2} ,no value is coming as I put outputtext to test.

  • guest Monday, October 21, 2013

    I followed all the steps but after deploying to weblogic server, Im getting Internal Server Error

  • Shay Monday, October 21, 2013

    guest - post your error and stack trace on the JDeveloper forum on OTN.

  • guest Wednesday, April 16, 2014

    Hallo Shay can i call URL with Task flow -run as dialog

  • Shay Wednesday, April 16, 2014

    guest -I'm not sure I understand your question.

    Why not just create a taskflow call in your flow? and pass parameters to that flow.

  • Kris Monday, July 28, 2014

    Hi Shay ,

    How can i pass the parameter on the sessionscope to the bind variable in the View Criteria , after click the button search

    I have the query panel on the view page that is based on my view criteria as below ,

    select * from table where idUser = :bind_idUser.

  • guest Wednesday, December 17, 2014

    Hi Shay,

    I was trying it but I am getting error as showing in below error trace -

    oracle.jbo.SQLStmtException: JBO-27122: SQL error during statement preparation. Statement: SELECT geog_territory.geog_territory_desc Territory,

    geog_region.geog_region_desc Region,

    geog_branch.geog_branch_desc Branch,

    geog_customer.geog_customer_desc Customer,

    NVL(geog_request_number.geog_quote_in, geog_request_number.geog_quote_num) Quote,

    NVL(geog_request_number.geog_start_date_i, geog_request_number.geog_start_date_c) Start_Date,

    NVL(geog_request_number.geog_dc_i, geog_request_number.geog_dc_c) Drilling_Curve_Days_per_well,

    NVL(geog_request_number.geog_num_rigs_i, geog_request_number.geog_num_rigs_c) Number_of_Rigs,

    NVL(geog_request_number.geog_pend_wells_i, geog_request_number.geog_exp_wells) Total_Pending_Wells,

    geog_q_upd_chkbox SSO

    FROM geog_request_number,





    WHERE 1 = 1

    AND geog_request_number.geog_territory_id = geog_territory.geog_territory_id

    AND geog_request_number.geog_branch_id = geog_branch.geog_branch_id

    AND geog_request_number.geog_customer_id = geog_customer.geog_customer_id

    AND geog_request_number.geog_region_id = geog_region.geog_region_id

    AND geog_request_number_id = :REQ_ID

    at oracle.jbo.server.BaseSQLBuilderImpl.processException(BaseSQLBuilderImpl.java:3721)

    at oracle.jbo.server.OracleSQLBuilderImpl.processException(OracleSQLBuilderImpl.java:4721)

    at oracle.jbo.server.QueryCollection.buildResultSet(QueryCollection.java:1379)

    at oracle.jbo.server.QueryCollection.executeQuery(QueryCollection.java:913)

    at oracle.jbo.server.ViewObjectImpl.executeQueryForCollection(ViewObjectImpl.java:7282)

    at oracle.jbo.server.ViewRowSetImpl.execute(ViewRowSetImpl.java:1227)

    at oracle.jbo.server.ViewRowSetImpl.executeQueryForMasters(ViewRowSetImpl.java:1413)

    at oracle.jbo.server.ViewRowSetImpl.executeQueryForMode(ViewRowSetImpl.java:1319)

    at oracle.jbo.server.ViewRowSetImpl.executeQuery(ViewRowSetImpl.java:1304)

    at oracle.jbo.server.ViewObjectImpl.executeQuery(ViewObjectImpl.java:7211)

    at oracle.adf.model.bc4j.DCJboDataControl.executeIteratorBindingWithParams(DCJboDataControl.java:2957)

    at oracle.jbo.uicli.binding.JUCtrlActionBinding.doIt(JUCtrlActionBinding.java:1532)

    at oracle.adf.model.binding.DCDataControl.invokeOperation(DCDataControl.java:2169)

    at oracle.jbo.uicli.binding.JUCtrlActionBinding.invoke(JUCtrlActionBinding.java:731)

    at oracle.adf.controller.v2.lifecycle.PageLifecycleImpl.executeEvent(PageLifecycleImpl.java:402)

    at oracle.adfinternal.view.faces.model.binding.FacesCtrlActionBinding._execute(FacesCtrlActionBinding.java:252)

    at oracle.adfinternal.view.faces.model.binding.FacesCtrlActionBinding.execute(FacesCtrlActionBinding.java:210)

    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)

    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)

    at java.lang.reflect.Method.invoke(Method.java:597)

    at com.sun.el.parser.AstValue.invoke(Unknown Source)

    at com.sun.el.MethodExpressionImpl.invoke(Unknown Source)

    at oracle.adf.controller.internal.util.ELInterfaceImpl.invokeMethod(ELInterfaceImpl.java:173)

    at oracle.adfinternal.controller.activity.MethodCallActivityLogic.execute(MethodCallActivityLogic.java:163)

    at oracle.adfinternal.controller.engine.ControlFlowEngine.executeActivity(ControlFlowEngine.java:1091)

    at oracle.adfinternal.controller.engine.ControlFlowEngine.doRouting(ControlFlowEngine.java:982)

    at oracle.adfinternal.controller.engine.ControlFlowEngine.doRouting(ControlFlowEngine.java:880)

    at oracle.adfinternal.controller.engine.ControlFlowEngine.invokeTaskFlow(ControlFlowEngine.java:249)

    at oracle.adfinternal.controller.application.RemoteTaskFlowCallRequestHandler.invokeTaskFlowByUrl(RemoteTaskFlowCallRequestHandler.java:97)

    at oracle.adfinternal.controller.application.RemoteTaskFlowCallRequestHandler.doCreateView(RemoteTaskFlowCallRequestHandler.java:63)

    at oracle.adfinternal.controller.application.BaseRequestHandlerImpl.createView(BaseRequestHandlerImpl.java:59)

    at org.apache.myfaces.trinidadinternal.application.InternalViewHandlingStrategy.createView(InternalViewHandlingStrategy.java:48)

    at com.sun.faces.application.view.MultiViewHandler.createView(MultiViewHandler.java:166)

    at javax.faces.application.ViewHandlerWrapper.createView(ViewHandlerWrapper.java:155)

    at org.apache.myfaces.trinidadinternal.application.ViewHandlerImpl.createView(ViewHandlerImpl.java:103)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._restoreView(LifecycleImpl.java:774)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl._executePhase(LifecycleImpl.java:349)

    at oracle.adfinternal.view.faces.lifecycle.LifecycleImpl.execute(LifecycleImpl.java:202)

    at javax.faces.webapp.FacesServlet.service(FacesServlet.java:508)

    at weblogic.servlet.internal.StubSecurityHelper$ServletServiceAction.run(StubSecurityHelper.java:227)

    at weblogic.servlet.internal.StubSecurityHelper.invokeServlet(StubSecurityHelper.java:125)

    at weblogic.servlet.internal.ServletStubImpl.execute(ServletStubImpl.java:300)

    at weblogic.servlet.internal.TailFilter.doFilter(TailFilter.java:26)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:173)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.adfinternal.view.faces.webapp.rich.RegistrationFilter.doFilter(RegistrationFilter.java:125)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)

    at oracle.adfinternal.view.faces.activedata.AdsFilter.doFilter(AdsFilter.java:60)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl$FilterListChain.doFilter(TrinidadFilterImpl.java:468)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl._doFilterImpl(TrinidadFilterImpl.java:293)

    at org.apache.myfaces.trinidadinternal.webapp.TrinidadFilterImpl.doFilter(TrinidadFilterImpl.java:199)

    at org.apache.myfaces.trinidad.webapp.TrinidadFilter.doFilter(TrinidadFilter.java:92)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.security.jps.ee.http.JpsAbsFilter$1.run(JpsAbsFilter.java:119)

    at java.security.AccessController.doPrivileged(Native Method)

    at oracle.security.jps.util.JpsSubject.doAsPrivileged(JpsSubject.java:315)

    at oracle.security.jps.ee.util.JpsPlatformUtil.runJaasMode(JpsPlatformUtil.java:442)

    at oracle.security.jps.ee.http.JpsAbsFilter.runJaasMode(JpsAbsFilter.java:103)

    at oracle.security.jps.ee.http.JpsAbsFilter.doFilter(JpsAbsFilter.java:171)

    at oracle.security.jps.ee.http.JpsFilter.doFilter(JpsFilter.java:71)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at oracle.dms.servlet.DMSServletFilter.doFilter(DMSServletFilter.java:139)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at weblogic.servlet.internal.RequestEventsFilter.doFilter(RequestEventsFilter.java:27)

    at weblogic.servlet.internal.FilterChainImpl.doFilter(FilterChainImpl.java:56)

    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.wrapRun(WebAppServletContext.java:3715)

    at weblogic.servlet.internal.WebAppServletContext$ServletInvocationAction.run(WebAppServletContext.java:3681)

    at weblogic.security.acl.internal.AuthenticatedSubject.doAs(AuthenticatedSubject.java:321)

    at weblogic.security.service.SecurityManager.runAs(SecurityManager.java:120)

    at weblogic.servlet.internal.WebAppServletContext.securedExecute(WebAppServletContext.java:2277)

    at weblogic.servlet.internal.WebAppServletContext.execute(WebAppServletContext.java:2183)

    at weblogic.servlet.internal.ServletRequestImpl.run(ServletRequestImpl.java:1454)

    at weblogic.work.ExecuteThread.execute(ExecuteThread.java:209)

    at weblogic.work.ExecuteThread.run(ExecuteThread.java:178)

    Caused by: java.sql.SQLException: Missing IN or OUT parameter at index:: 1

    Can you please advise where I am doing wrong.

  • Shay Wednesday, December 17, 2014

    guest - there is no way for me to help you without looking at your code. Try posting more details on the OTN ADF discussion forum.

    And try and set a breakpoint on the method binding to see what value is in the parameter.

  • Hitesh Sunday, February 1, 2015

    Pass Value across Application or Post to url


  • Pramod Gujjeti Thursday, August 18, 2016

    Hi Shay, from r12 (12.2.5) invoking external ADF page is by using ADFX Function. So how do you prepare a dynamic value for the parameter and invoke the ADF page by passing it from EBS.

Please enter your name.Please provide a valid email address.Please enter a comment.CAPTCHA challenge response provided was incorrect. Please try again.