View object query bind variable

I have a bind variable in my view object query and "Required" is unchecked for it. Due to this JUnits are failing with the Missing IN or OUT parameter error. If I set the bind variable as required, the JUnits run fine.
But this bind variable is also used in several view criterias where it is set as Optional. So if I set the bind variable in the view object query as Required, will it affect the view criterias as well?

check https://blogs.oracle.com/jdevotnharvest/entry/the_infamous_missing_in_or

Similar Messages

  • How to bind the value of textbox with View object's bind variable?

    Hi all,
    In my use case I need to pass the value of textbox in the jsf page to the View Object's bind variable.
    I should not hard code this in my backing bean. I need to configure in the Jdeveloper itself.
    I am using Jdeveloper 11.1.1.4.0 version. Kindly come up with your help.
    Thanks,
    Phani.

    Hi,
    You have to use Named Bind Variables(ExecuteWithParams)
    http://download.oracle.com/docs/cd/B31017_01/web.1013/b25947/web_search_bc004.htm
    http://www.cloudsolid.com/2008/10/using-named-bind-variables.html

  • View object with bind variables on jsf page

    I have jsf page with selectoncechoice field and the list is populated with view object query.
    I would like to change the page to include another text field before the selectonechoice and add where clasue to my view object to use this field value
    so i can limit the selectonechoice list and i want the list refreshed each time where clause field values changes on the page
    Thanks

    If you make the inputText field autoSubmit=true then your valueChangeListener for the field in the backing bean can invoke the "ExecuteWithParams" operation binding after finding it from the binding container.
    If you include my EL helper class from here:
    http://radio.weblogs.com/0118231/stories/2006/12/18/sourceForMyFavoriteElHelperClass.html
    Then your backing bean can do:
      // Find the operation binding by name using EL
      OperationBinding b = (OperationBinding)EL.get("#{bindings.ExecuteWithParams}");
      // execute the operation binding
      b.execute();

  • Dynamic view object loses bind variables after passivation

    I am creating a view object definition/view object programmatically in Jdev 11.1.1.2.0. The query requires a named bind parameter. All was working fine but now I am testing with app module pooling disabled and the bind variable is not being restored after passivation -- it's like the definition has disappeared or something.
    Here is my VO creation code:
    ViewObject vo = findViewObject("FinalistsWithEvalDataVO");
    if (vo != null){
    vo.remove();
    ViewDefImpl voDef = new ViewDefImpl("FinalistsWithEvalDataVODef");
         // I add a bunch of viewAttrs here...
    voDef.setQuery(fullQuery);
    voDef.setFullSql(true);
    voDef.setBindingStyle(SQLBuilder.BINDING_STYLE_ORACLE_NAME);
    voDef.resolveDefObject();
    voDef.registerDefObject();
    vo = createViewObject("FinalistsWithEvalDataVO", voDef);
    vo.defineNamedWhereClauseParam("Bind_SchlrAyId", null, new int[] {0});
    vo.setNamedWhereClauseParam("Bind_SchlrAyId", new Number(1)); //For testing
    vo.executeQuery();
    The query executes fine right there and then the VO seems to passivate fine. I even see the bind var in passivation:
    <exArgs count="1">
    <arg name="Bind_SchlrAyId" type="oracle.jbo.domain.Number">
    <![CDATA[1]]>
    </arg>
    </exArgs>
    But then when it reactivates prior to rendering the page, it invariably throws a missing parameter exception and this in the log:
    <ViewUsageHelper><createViewAttributeDefImpls> [7409] *** createViewAttributeDefImpls: oracle.jdbc.driver.OraclePreparedStatementWrapper@1af78e1
    <ViewUsageHelper><createViewAttributeDefImpls> [7410] Bind params for ViewObject: [FinalistsWithEvalDataVO]AwardViewingServiceAM.FinalistsWithEvalDataVO
    <ViewUsageHelper><createViewAttributeDefImpls> [7411] ViewUsageHelper.createViewAttributeDefImpls failed...
    <ViewUsageHelper><createViewAttributeDefImpls> [7412] java.sql.SQLException: Missing IN or OUT parameter at index:: 1
    I have worked on this for hours and can't see anything wrong. Like I said, it works fine when not forcing passivation...
    Any help would be appreciated.
    Thanks.
    -Ed

    @Jobinesh - Thanks for the suggestions. I have read all the documentation I can find. Everything works fine without passivation. Everything still breaks with passivation. I have given up on trying to get the bind variable to restore after passivation and am currently just building the query with all values embedded in the query rather than bind variables. This is bad practice but avoids the problem. However, now that I avoided that obstacle, I'm on to the next issue with passivation of this dynamic view object, which is that the current row primary key apparently cannot be reset after activation. I get the following error:
    <Key><parseBytes> [7244] Key(String, AttributeDef[]): Invalid Key String found. AttributeCount:1 does not match Key attributes
    <DCBindingContainer><reportException> [7254] oracle.jbo.InvalidParamException: JBO-25006: Value 00010000000A30303033383133343734 passed as parameter String to method Constructor:Key is invalid: {3}.
         at oracle.jbo.Key.parseBytes(Key.java:537)
         at oracle.jbo.Key.<init>(Key.java:179)
         at oracle.jbo.server.IteratorStateHolder.getCurrentRowKey(IteratorStateHolder.java:34)
         at oracle.jbo.server.ViewRowSetIteratorImpl.activateIteratorState(ViewRowSetIteratorImpl.java:3877)
    I've been trying various workarounds for over a day now with no luck. Very frustrating.
    Thanks for trying to help.
    -Ed

  • View object with bind variables in subqueries

    Hi,
    i create view object with this query:
    Select /*+ use_nl(p p2) */
    'F' tipo_persona,
    p.ID_PERSONA, p.TDOC, p.NDOC, p.DENO
    From SINT_PERSONA p,
    ( Select /*+ index(a SINT_PERSONA_IX2) */
    a.ID_PERSONA
    From SINT_PERSONA_DOCUMENTO a
    where ( NDOC = :p_cuit
    and :p_cuit is not null )
    ) p2
    Where p.id_persona = p2.id_persona
    AND (deno = upper(:p_deno) or
    :p_deno is null)
    AND (NDOC = :p_ndoc or
    :p_ndoc is null)
    and grado_confiab > 0
    My binding style is oracle named.
    Then I add the bind variables:
    p_cuit this is the only required
    p_ndoc
    p_deno
    but when i run the app module with p_cuit = 20123456780 i get this error:
    (oracle.jbo.SQLStmtException) JBO-27122: Error SQL durante la preparación de la sentencia. Sentencia: Select /*+ use_nl(p p2) */
    'F' tipo_persona,
    p.ID_PERSONA, p.TDOC, p.NDOC, p.DENO
    From SINT_PERSONA p,
    ( Select /*+ index(a SINT_PERSONA_IX2) */
    a.ID_PERSONA
    From SINT_PERSONA_DOCUMENTO a
    where ( NDOC = :p_cuit
    and :p_cuit is not null )
    ) p2
    Where p.id_persona = p2.id_persona
    AND (deno = upper(:p_deno) or
    :p_deno is null)
    AND (NDOC = :p_ndoc or
    :p_ndoc is null)
    and grado_confiab > 0
    ----- Nivel 1: Detalle 0 -----
    (java.sql.SQLException) Falta el parámetro IN o OUT en el índice:: 3
    How can i do this ?
    thanks.

    Thanks! that's right the bind variables when i use it on where clause must be required, so i change my sql to:
    Select /*+ use_nl(p p2) */
    'F' tipo_persona,
    p.ID_PERSONA, p.TDOC, p.NDOC, p.DENO
    From SINT_PERSONA p,
    ( Select /*+ index(a SINT_PERSONA_IX2) */
    a.ID_PERSONA
    From SINT_PERSONA_DOCUMENTO a
    where ( NDOC = :p_cuit
    and :p_cuit <> 0 )
    ) p2
    Where p.id_persona = p2.id_persona
    AND (deno = decode(:p_deno,'null',null,upper(:p_deno)) or
    :p_deno = 'null')
    AND (NDOC = decode(:p_ndoc,0,null,:p_ndoc) or
    :p_ndoc = 0)
    and grado_confiab > 0
    and my bind variables:
    p_ndoc required default value 0
    p_cuit required default value 0
    p_deno required default value null
    and works ok!
    thanks a lot !!!!

  • View link accessor for master view object with bind variables

    Is there a way to set bind variables for a view object to which a view link accessor is used to retrieve a view row from a detail view row in a master-detail relationship ?
    I understand that RowSet (or Row) returned by a view link accessor originates from an "internally created" view object instance.
    I am using 10.1.3.0.4 JDeveloper.

    Thanks! that's right the bind variables when i use it on where clause must be required, so i change my sql to:
    Select /*+ use_nl(p p2) */
    'F' tipo_persona,
    p.ID_PERSONA, p.TDOC, p.NDOC, p.DENO
    From SINT_PERSONA p,
    ( Select /*+ index(a SINT_PERSONA_IX2) */
    a.ID_PERSONA
    From SINT_PERSONA_DOCUMENTO a
    where ( NDOC = :p_cuit
    and :p_cuit <> 0 )
    ) p2
    Where p.id_persona = p2.id_persona
    AND (deno = decode(:p_deno,'null',null,upper(:p_deno)) or
    :p_deno = 'null')
    AND (NDOC = decode(:p_ndoc,0,null,:p_ndoc) or
    :p_ndoc = 0)
    and grado_confiab > 0
    and my bind variables:
    p_ndoc required default value 0
    p_cuit required default value 0
    p_deno required default value null
    and works ok!
    thanks a lot !!!!

  • How To change the ADF View Object  query where-clause at RunTime?

    I am trying to create a simple display page which will display user data (username, assoc_dist_id, assoc_agent_id, status , etc). The User data is stored in a database table and i am using an ADF Read Only table based on the View Object to display the data on the JSF page.
    However, i want to display only the users that a particular person accessing the page has the AUTH LEVEL to see. e.g. If the person accessing the page is an 'ApplicationAdministrator' then the page should display all users in the table, If its a 'DistributorAdministrator' then the page should display only users associated with that Distributor (i.e. assoc_dist_id = :p_Dist_id ) and If its an 'AgentAdministrator' , then the page should display only users associated with that Agent ( i.e. assoc_agent_id = :p_Agent_id).
    Currently my af:table component displays all the users in the table because the query for the view object is (select * from users) . However, i want to use the same viewobject and just set the where-clause at runtime with the appropriate parameter to restrict the dataset returned.
    Do anyone knows how to accomplish this ?

    David,
    See the custom method initializeDynamicVariableDefaults() in the SRViewObjectImpl.java class in the FrameworkExtentions project in the SRDemoSampleADFBC sample application. You can find out how to install the demo if you haven't already from the ADF Learning Center at:
    http://www.oracle.com/technology/products/adf/learnadf.html
    This class is a framework extension class for view objects that adds a neat, generic feature to be able to dynamic default the value of named bind variables. You can read more about what framework extension classes are and how to use them in Chapter 25, "Advanced Business Components Techniques" of the ADF Developer's Guide for Forms/4GL Developers, also available at the learning center above.
    It is an example of generic framework functionality that "kicks in" based on the presence of custom metadata properties on a named bind variable. See section 25.3.3 "Implementing Generic Functionality Driven by Custom Properties" in the dev guide for more details. Using this sample code, if you add a bind variable to a view object, and define a custom metadata property named "DynamicDefaultValue" on that bind variable, and set this custom metadata property to the value "CurrentUser", then that bind variable will have its value dynamically defaulted to the name of the authenticated user logged in. If instead you set this custom property to the value "UserRole", then the bind variable will be set to the comma-separated string containing the list of roles that the authenticated user is part of.
    Once you've created a framework extension class for view objects like this, you can have the view objects you create inherit this generic functionality.See section 25.1.4 "How to Base an ADF Component on a Framework Extension Class" in the dev guide for more info on this.
    By adapting a technique like this (or some idea similar that better suits your needs) you can have your view object query contain bind variables whose values automatically take on the defaults based on something in the user-session environment.

  • Functionality loss when 'Using Query Bind Variables in Advanced Search

    Regarding: 'Using Query Bind Variables in Quick or Advanced Search'
    The functionality to do the following is lost when I use bind variables in the Advanced Search:
    "Result matches all conditions"
    "Result matches any condition"
    "Case Sensitive?"
    Is there a way to Search with Detail groups but to keep the above functionality?

    Hi,
    Your application module impl java class extends the JHeadstart class JhsApplicationModuleImpl. THe latter declares a method:
    public void advancedSearch(String viewObjectUsage,java.util.ArrayList arguments,Boolean allConditionsMet).
    In your application module impl java override the advancedSearch method where you can include your own custom code before invoking the super method:
    super.advancedSearch(viewObjectUsage,arguments,allConditionsMet);
    The 'arguments' parameter is an arraylist of QueryCondition objects. You can set several properties for QueryCondition objects such as case-sensitity, operators etc.
    Regards,
    Ibrahim

  • Query Bind Variables problem

    I have a ViewObject with bindvariable GroupnameItemname.
    In JHeadstart AppDef this item is not bound to model, but included in Quick Search and Advanced Serach, as in "7.2.5. Using Query Bind Variables in Quick or Advanced Search"
    First I get an error saying GroupnameItemname*Var* is not found on ViewObject, so I changed the bindvariables to GroupnameItemnameVar
    Is something changed here? We are using JHeadstart 10.1.3.3.75 / JDeveloper 10.1.3.4.0
    After changing the bindvariablename I have another problem:
    I get an error in JhsApplicationModuleImpl.advancedSearch on these lines:
    boolean isBindParam = !viewCriterium.isAttributeBased();
    AttributeDef ad = isBindParam ? null : vo.findAttributeDef(attribute);
    The first line returns false for my bindvariable, so the second line raises an error like "JBO-25058: Definition <attr> of type Attribute not found in <VO>".
    In QueryCondition:
    public boolean isAttributeBased()
    return def!=null; //but def is not null here, it is an instance of DCVariableImpl
    This used to work in previous versions of JHeadstart...
    Please help,
    Greetings HJH

    In my MyApplicationModuleImpl (which extends JhsApplicationModuleImpl) I did override advancedSearch.
    Copied the code from JhsApplicationModuleImpl and changed a few lines:
    After
    sLog.debug("executing advancedSearch for " + viewObjectUsage);
    ViewObject vo = getViewObject(viewObjectUsage);
    I added:
    //clear bindParams:
    String[] attrNames =
    vo.getNamedWhereClauseParams().getAttributeNames();
    for (int i = 0; i < attrNames.length; i++) {
    vo.setNamedWhereClauseParam(attrNames\[i\], null);
    sLog.debug("bindParam leeggemaakt: " + attrNames\[i\]);
    And a bit later in the method I made a changed as follows:
    // boolean isBindParam = !viewCriterium.isAttributeBased();
    boolean isBindParam = viewCriterium.getName().endsWith("Var");
    A bit crude, but worked for me...
    Cheerio,
    HJH
    Edited by: HJHorst on Mar 19, 2009 1:56 PM (had to escape square brackets...)

  • Issue with View object query

    Hi,
    I have extended my controller to add an additional condition to the view object query where I appen an add condition.If there is any kind of exception the add condition keeps on appending without refreshing the query to the orginal one.I have to clear the cache to be able to fix it
    below is the peice of code.What should I do to be able to get the original query or refresh it because when i do a getQuery it keeps giving me the query with the earlier condition that I appended and again appends the new condition.
    strQuery = oaviewobjectimpl.getQuery();
    oaviewobjectimpl.setQuery(strQuery+" AND MtlCategoriesKfv.CONCATENATED_SEGMENTS = '"+strCategory+"'");
    RequisitionAMImpl requisitionamimpl1 = (RequisitionAMImpl)oapagecontext.getApplicationModule(oawebbean);
    OAViewObjectImpl oaviewobjectimpl = requisitionamimpl.getReqCategoryVO();
    String strQuery = oaviewobjectimpl.getQuery();
    oaviewobjectimpl.setQuery(strQuery+" AND MtlCategoriesKfv.CONCATENATED_SEGMENTS = '"+strCategory+"'");
    oaviewobjectimpl.setWhereClauseParams(null);
    oaviewobjectimpl.setWhereClauseParam(0, oapagecontext.getCurrentLanguage());
    if(oapagecontext.isLoggingEnabled(1))
    oapagecontext.writeDiagnostics(this, "oaviewobjectimpl.getQuery() "+oaviewobjectimpl.getQuery(), 1);
    oaviewobjectimpl.executeQuery();
    oaviewobjectimpl.last();
    if(oapagecontext.isLoggingEnabled(1))
    oapagecontext.writeDiagnostics(this, "oaviewobjectimpl.getFetchedRowCount() "+oaviewobjectimpl.getFetchedRowCount(), 1);
    ReqCategoryVORowImpl reqcategoryvorowimpl= (ReqCategoryVORowImpl)oaviewobjectimpl.first();
    Number categoryId = reqcategoryvorowimpl.getCategoryId();

    user610276 ,
    Y don't u make a custom VO, as you are doing set query, i expect ur changing entire query of seeded VO, better to use custom VO here and attach it to required beans progrmatically.
    --Mukul                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                               

  • Af:iterator and view accessors with bind variables

    I have a page with an af:iterator where I list up each row in a form layout. On each row there are 2 SelectOneChoice items where the current value is provided by the row. The 2 LOVs are Master-Detail-LOVs. The value of the first one restricts the values of the second one.
    Each LOV is represented by a LOV view object in a shared application module. The view object for the second LOV contains a view criteria with a selection on the column where the value is provided by the first LOV. The value for the restriction is passed via Bind Variable.
    <af:iterator id="i_images" value="#{bindings.Image.collectionModel}" var="row" rows="0" varStatus="vs">
    <af:selectOneChoice value="#{row.bindings.Master.inputValue}" label="#{bindings.Master.label}" id="soc_master" autoSubmit="true">
    <f:selectItems value="#{row.bindings.Master.items}"
    id="si3"/>
    </af:selectOneChoice>
    <af:selectOneChoice value="#{row.bindings.Detail.inputValue}" label="#{bindings.Detail.label}" id="soc2" partialTriggers="soc_master">
    <f:selectItems value="#{row.bindings.Detail.items}"
    id="si2"/>
    </af:selectOneChoice>
    The view accessor for both LOVs have the settings:
    Row Level Bind Values = true
    SharedInstance = false
    BTW: If I modify one the two view accessor the value for Row Level Bind Values disappear.
    The value for the bind variable on the view accessor is "Master" like the name of the column.
    On loading the page for the first time the LOVs and the values are properly resolved. The master LOV provides the list with all values and the Detail LOV is restricted corresponding the value of the Master LOV. Upon changing the value of the Master LOV the Detail LOV is reloaded, because of the partial trigger, but now the Detail LOV contains all the values as if now View Criteria has been provided.
    We implemented this scenario in an af:query and it worked fine. Are there any restrictions for View Accessors when using an af:iterator??
    Any help is appreciated.
    Thanks,
    Thomas
    P.S.: We're using JDeveloper 11.1.1.4.0
    Edited by: thomas.matzke on Apr 20, 2011 10:07 PM

    Hi Thomas,
    You may be hitting an error that is discussed in the following blog: http://andrejusb.blogspot.com/2011/03/adf-bc-dependent-lov-11g-ps2ps3-bug-and.html
    Hope this helps!
    Russell

  • Pass parameter from jsf to view object query

    Hi,
    i have requirement where user id is captured when user logs in in a session bean.How do I pass this parameter to bind variable in query?
    thanks,
    Mat

    Amit's second link : Setting bind variable for a view object
    should hold answers for you.
    Ypu can also visit : http://groundside.com/blog/DuncanMills.php?title=adf_executing_code_on_page_entry_1_servi&more=1&c=1&tb=1&pb=1
    The general idea is this :
    Get the username (you mentioned portal, so after portal authenticates the user is the username available in a session scoped managed bean ? You would need to access this somehow because your query needs it., preferrably by EL)
    create am AM method to set the bind parameter to the Vo and execute it. The method is automatically exposed to the DataControl.
    Create a method binding in your page def for the method. in the parameters for the method, use the EL to get the username, eg: #{sessionScope.frameworkBean.username} (you could also create a binding for executeWithParams, but I hav'nt done this in a while and dont remember the exact process )
    Now create an executable for the method binding you created. (the executable ensure that this method is called at pageload, and set you refresh condition appropriately)
    Go to the properties
    Edited by: Jeevan Joseph on Jan 13, 2011 2:44 PM

  • ADFBC SQLException, large query, bind variables

    Hi,
    I'm getting an SQLException while running a Query with a dynamically built WHERE clause using named bind variables.
    This is the following exception details.
    SQLException: SQLState(null) vendor code(17110)
    java.sql.SQLException: execution completed with warning
    at oracle.jdbc.driver.DatabaseError.newSqlException(DatabaseError.java:93)
    ... etc
    SQLWarning: reason(Warning: execution completed with warning) SQLstate(null) vendor code(17110)I've tried removing the View Object and all the related components on the page, and reinstating them all, but the same Exception keeps occurring.
    The view in the db has alot of records, approximately 126,000.
    The query does execute and rows are returned successfully, but I don't like to look of this exception.
    Any help on this would be appreciated!

    Hi John,
    Below is the stack trace.
    [684] SQLException: SQLState(null) vendor code(17110)
    [685] java.sql.SQLException: execution completed with warning
    [686]      at oracle.jdbc.driver.DatabaseError.newSqlException(DatabaseError.java:93)
    [687]      at oracle.jdbc.driver.DatabaseError.newSqlException(DatabaseError.java:111)
    [688]      at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:342)
    [689]      at oracle.jdbc.driver.T4CTTIoer.processError(T4CTTIoer.java:282)
    [690]      at oracle.jdbc.driver.T4C8Oall.receive(T4C8Oall.java:639)
    [691]      at oracle.jdbc.driver.T4CPreparedStatement.doOall8(T4CPreparedStatement.java:185)
    [692]      at oracle.jdbc.driver.T4CPreparedStatement.execute_for_rows(T4CPreparedStatement.java:633)
    [693]      at oracle.jdbc.driver.OracleStatement.execute_maybe_describe(OracleStatement.java:1048)
    [694]      at oracle.jdbc.driver.T4CPreparedStatement.execute_maybe_describe(T4CPreparedStatement.java:535)
    [695]      at oracle.jdbc.driver.OracleStatement.doExecuteWithTimeout(OracleStatement.java:1126)
    [696]      at oracle.jdbc.driver.OraclePreparedStatement.executeInternal(OraclePreparedStatement.java:3001)
    [697]      at oracle.jdbc.driver.OraclePreparedStatement.executeQuery(OraclePreparedStatement.java:3043)
    [698]      at oracle.jbo.server.ViewObjectImpl.getQueryHitCount(ViewObjectImpl.java:2273)
    [699]      at oracle.jbo.server.ViewObjectImpl.getQueryHitCount(ViewObjectImpl.java:2227)
    [700]      at oracle.jbo.server.QueryCollection.getEstimatedRowCount(QueryCollection.java:2560)
    [701]      at oracle.jbo.server.ViewRowSetImpl.getEstimatedRowCount(ViewRowSetImpl.java:1965)
    [702]      at oracle.jbo.server.ViewObjectImpl.getEstimatedRowCount(ViewObjectImpl.java:5987)
    [703]      at oracle.adf.model.bc4j.DCJboDataControl.getEstimatedRowCount(DCJboDataControl.java:965)
    [704]      at oracle.adf.model.binding.DCIteratorBinding.getEstimatedRowCount(DCIteratorBinding.java:2969)
    [705]      at oracle.jbo.uicli.binding.JUCtrlRangeBinding.getEstimatedRowCount(JUCtrlRangeBinding.java:115)
    [706]      at oracle.adfinternal.view.faces.model.binding.FacesCtrlRangeBinding$FacesModel.getRowCount(FacesCtrlRangeBinding.java:395)
    [707]      at oracle.adf.view.faces.component.UIXCollection.getRowCount(UIXCollection.java:271)
    [708]      at oracle.adf.view.faces.model.ModelUtils.findLastIndex(ModelUtils.java:117)
    [709]      at oracle.adf.view.faces.component.TableUtils.getLast(TableUtils.java:65)
    [710]      at oracle.adf.view.faces.component.TableUtils.getLast(TableUtils.java:39)
    [711]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.table.TableUtils.getVisibleRowCount(TableUtils.java:125)
    [712]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.table.RowData.<init>(RowData.java:22)
    [713]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.table.TableRenderingContext.<init>(TableRenderingContext.java:56)
    [714]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.TableRenderer.createRenderingContext(TableRenderer.java:375)
    [715]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.TableRenderer.encodeAll(TableRenderer.java:198)
    [716]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.DesktopTableRenderer.encodeAll(DesktopTableRenderer.java:80)
    [717]      at oracle.adfinternal.view.faces.renderkit.core.CoreRenderer.encodeEnd(CoreRenderer.java:169)
    [718]      at oracle.adf.view.faces.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:624)
    [719]      at oracle.adf.view.faces.component.UIXCollection.encodeEnd(UIXCollection.java:456)
    [720]      at oracle.adfinternal.view.faces.uinode.UIComponentUINode._renderComponent(UIComponentUINode.java:317)
    [721]      at oracle.adfinternal.view.faces.uinode.UIComponentUINode.render(UIComponentUINode.java:262)
    [722]      at oracle.adfinternal.view.faces.uinode.UIComponentUINode.render(UIComponentUINode.java:239)
    [723]      at oracle.adfinternal.view.faces.ui.composite.ContextPoppingUINode$ContextPoppingRenderer.render(ContextPoppingUINode.java:224)
    [724]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:346)
    [725]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:301)
    [726]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderChild(BaseRenderer.java:412)
    [727]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:330)
    [728]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:222)
    [729]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderContent(BaseRenderer.java:129)
    [730]      at oracle.adfinternal.view.faces.ui.BaseRenderer.render(BaseRenderer.java:81)
    [731]      at oracle.adfinternal.view.faces.ui.laf.base.xhtml.XhtmlLafRenderer.render(XhtmlLafRenderer.java:69)
    [732]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:346)
    [733]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:301)
    [734]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderChild(BaseRenderer.java:412)
    [735]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:330)
    [736]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:222)
    [737]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderContent(BaseRenderer.java:129)
    [738]      at oracle.adfinternal.view.faces.ui.BaseRenderer.render(BaseRenderer.java:81)
    [739]      at oracle.adfinternal.view.faces.ui.laf.base.xhtml.XhtmlLafRenderer.render(XhtmlLafRenderer.java:69)
    [740]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:346)
    [741]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:301)
    [742]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderChild(BaseRenderer.java:412)
    [743]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:330)
    [744]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:222)
    [745]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderContent(BaseRenderer.java:129)
    [746]      at oracle.adfinternal.view.faces.ui.laf.base.xhtml.BorderLayoutRenderer.renderIndexedChildren(BorderLayoutRenderer.java:42)
    [747]      at oracle.adfinternal.view.faces.ui.laf.base.xhtml.BorderLayoutRenderer.renderContent(BorderLayoutRenderer.java:71)
    [748]      at oracle.adfinternal.view.faces.ui.BaseRenderer.render(BaseRenderer.java:81)
    [749]      at oracle.adfinternal.view.faces.ui.laf.base.xhtml.XhtmlLafRenderer.render(XhtmlLafRenderer.java:69)
    [750]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:346)
    [751]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:301)
    [752]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderChild(BaseRenderer.java:412)
    [753]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:330)
    [754]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderIndexedChild(BaseRenderer.java:222)
    [755]      at oracle.adfinternal.view.faces.ui.BaseRenderer.renderContent(BaseRenderer.java:129)
    [756]      at oracle.adfinternal.view.faces.ui.BaseRenderer.render(BaseRenderer.java:81)
    [757]      at oracle.adfinternal.view.faces.ui.laf.base.xhtml.XhtmlLafRenderer.render(XhtmlLafRenderer.java:69)
    [758]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:346)
    [759]      at oracle.adfinternal.view.faces.ui.BaseUINode.render(BaseUINode.java:301)
    [760]      at oracle.adfinternal.view.faces.ui.composite.UINodeRenderer.renderWithNode(UINodeRenderer.java:90)
    [761]      at oracle.adfinternal.view.faces.ui.composite.UINodeRenderer.render(UINodeRenderer.java:36)
    [762]      at oracle.adfinternal.view.faces.ui.laf.oracle.desktop.PageLayoutRenderer.render(PageLayoutRenderer.java:76)
    [763]      at oracle.adfinternal.view.faces.uinode.UIXComponentUINode.renderInternal(UIXComponentUINode.java:177)
    [764]      at oracle.adfinternal.view.faces.uinode.UINodeRendererBase.encodeEnd(UINodeRendererBase.java:53)
    [765]      at oracle.adf.view.faces.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:624)
    [766]      at oracle.adfinternal.view.faces.renderkit.RenderUtils.encodeRecursive(RenderUtils.java:54)
    [767]      at oracle.adfinternal.view.faces.renderkit.core.CoreRenderer.encodeChild(CoreRenderer.java:242)
    [768]      at oracle.adfinternal.view.faces.renderkit.core.CoreRenderer.encodeAllChildren(CoreRenderer.java:265)
    [769]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.PanelPartialRootRenderer.renderContent(PanelPartialRootRenderer.java:65)
    [770]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.BodyRenderer.renderContent(BodyRenderer.java:117)
    [771]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.PanelPartialRootRenderer.encodeAll(PanelPartialRootRenderer.java:147)
    [772]      at oracle.adfinternal.view.faces.renderkit.core.xhtml.BodyRenderer.encodeAll(BodyRenderer.java:60)
    [773]      at oracle.adfinternal.view.faces.renderkit.core.CoreRenderer.encodeEnd(CoreRenderer.java:169)
    [774]      at oracle.adf.view.faces.component.UIXComponentBase.encodeEnd(UIXComponentBase.java:624)
    [775]      at javax.faces.webapp.UIComponentTag.encodeEnd(UIComponentTag.java:645)
    [776]      at javax.faces.webapp.UIComponentTag.doEndTag(UIComponentTag.java:568)
    [777]      at oracle.adf.view.faces.webapp.UIXComponentTag.doEndTag(UIXComponentTag.java:100)
    [778]      at _plus._gl._DynamicViews._jspService(_DynamicViews.java:1245)
    [779]      at com.orionserver.http.OrionHttpJspPage.service(OrionHttpJspPage.java:59)
    [780]      at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:462)
    [781]      at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:598)
    [782]      at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:522)
    [783]      at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
    [784]      at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:712)
    [785]      at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:369)
    [786]      at com.evermind.server.http.ServletRequestDispatcher.unprivileged_forward(ServletRequestDispatcher.java:286)
    [787]      at com.evermind.server.http.ServletRequestDispatcher.access$100(ServletRequestDispatcher.java:50)
    [788]      at com.evermind.server.http.ServletRequestDispatcher$2.oc4jRun(ServletRequestDispatcher.java:192)
    [789]      at oracle.oc4j.security.OC4JSecurity.doPrivileged(OC4JSecurity.java:283)
    [790]      at com.evermind.server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:197)
    [791]      at com.sun.faces.context.ExternalContextImpl.dispatch(ExternalContextImpl.java:346)
    [792]      at com.sun.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:152)
    [793]      at oracle.adfinternal.view.faces.application.ViewHandlerImpl.renderView(ViewHandlerImpl.java:157)
    [794]      at com.sun.faces.lifecycle.RenderResponsePhase.execute(RenderResponsePhase.java:107)
    [795]      at com.sun.faces.lifecycle.LifecycleImpl.phase(LifecycleImpl.java:245)
    [796]      at com.sun.faces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:137)
    [797]      at javax.faces.webapp.FacesServlet.service(FacesServlet.java:214)
    [798]      at com.evermind.server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:64)
    [799]      at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._invokeDoFilter(AdfFacesFilterImpl.java:228)
    [800]      at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl._doFilterImpl(AdfFacesFilterImpl.java:197)
    [801]      at oracle.adfinternal.view.faces.webapp.AdfFacesFilterImpl.doFilter(AdfFacesFilterImpl.java:123)
    [802]      at oracle.adf.view.faces.webapp.AdfFacesFilter.doFilter(AdfFacesFilter.java:103)
    [803]      at com.evermind.server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:15)
    [804]      at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:162)
    [805]      at com.evermind.server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:620)
    [806]      at com.evermind.server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:369)
    [807]      at com.evermind.server.http.HttpRequestHandler.doProcessRequest(HttpRequestHandler.java:865)
    [808]      at com.evermind.server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:447)
    [809]      at com.evermind.server.http.HttpRequestHandler.serveOneRequest(HttpRequestHandler.java:215)
    [810]      at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:117)
    [811]      at com.evermind.server.http.HttpRequestHandler.run(HttpRequestHandler.java:110)
    [812]      at oracle.oc4j.network.ServerSocketReadHandler$SafeRunnable.run(ServerSocketReadHandler.java:260)
    [813]      at oracle.oc4j.network.ServerSocketAcceptHandler.procClientSocket(ServerSocketAcceptHandler.java:239)
    [814]      at oracle.oc4j.network.ServerSocketAcceptHandler.access$700(ServerSocketAcceptHandler.java:34)
    [815]      at oracle.oc4j.network.ServerSocketAcceptHandler$AcceptHandlerHorse.run(ServerSocketAcceptHandler.java:880)
    [816]      at com.evermind.util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:303)
    [817]      at java.lang.Thread.run(Thread.java:595)
    [818] SQLWarning: reason(Warning: execution completed with warning) SQLstate(null) vendor code(17110)Thanks for the reply.

  • SetCurrentRowWithKeyValue - Does this execute View Object Query twice?

    Hi,
    I have a View Object for which on the prepare model of the page definition I am executing the setCurrentRowWithKeyValue action.
    In the log I see two queries being printed one with Bind Variable of the Key value that I have passed and right next to that I see one more query for the same view object that gets executed without any where clause.
    This causes the View Object to execute an open query which is causing performance issue.
    Any help/Insight on this problem is greatly appreciated.
    Thanks,
    Kumar K.

    Thanks for the response.
    Solution provided in the thread doesn't prevent the execution but it will not return any rows..But I am just curious to know that is there some thing different done while using setCurrentRowWithKeyValue?
    Why should it execute query twice once with Bind variable and next time without the bind variable?
    Kumar K.

  • How to not have your view objects query before the page comes up?

    Hello. I have a view object that is part of a LOV. This view object always gets queried on bringing up the page (I need it to happen on the LOV click) How can I have the VO not queried initially? I tried setting the Iterator to refresh never, but it still does it. Here's the log before the page comes up:
    [363] BindingContext.put( ContactsAMDataControl@irepair_DataBindings_cpx, oracle.jbo.uicli.binding.JUApplication )
    [364] Resolving VO:ContactsVVO1 for iterator binding:ContactsVVO1Iterator
    [365] Changing iterator range size from :1 to :25
    [366] ContactsVVO1 ViewRowSetImpl.execute caused params to be "un"changed
    [367] Column count: 13
    [368] ViewObject: ContactsVVO1 Created new QUERY statement
    [369] ContactsVVO1>#q computed SQLStmtBufLen: 663, actual=623, storing=653
    [370] select
    oc.JOB_TITLE,
    oc.PARTY_SITE_ID,
    RELATIONSHIP_ID ,
    hp.PARTY_NAME OBJECT_NAME, -- Contact
    OBJECT_ID ,
    hr.PARTY_ID ,
    oc.CONTACT_KEY,
    subject_id,
    hp.EMAIL_ADDRESS,
    hp.primary_phone_country_code,
    hp.primary_phone_area_code,
    hp.primary_phone_number
    from HZ_ORG_CONTACT_ROLES ocr,
    HZ_ORG_CONTACTS oc,
    HZ_PARTIES hp,
    HZ_RELATIONSHIPS hr
    where
    hp.party_id = hr.object_id
    and hr.RELATIONSHIP_ID=oc. PARTY_RELATIONSHIP_ID
    and oc.ORG_CONTACT_ID = ocr.ORG_CONTACT_ID(+)
    and relationship_code = 'CONTACT'
    order by OBJECT_NAME
    [371] Bind params for ViewObject: ContactsVVO1
    [372] DCUtil, returning:oracle.adf.model.binding.DCParameter, for ContactsAMDataControl
    [373] LOCALVIEW_USAGE_com_craneae_services_hz_vvo_ContactsVVO_ContactsVVO1 ViewRowSetImpl.execute caused params to be "un"changed
    [374] Column count: 13
    [375] ViewObject: LOCALVIEW_USAGE_com_craneae_services_hz_vvo_ContactsVVO_ContactsVVO1 Created new QUERY statement
    [376] LOCALVIEW_USAGE_com_craneae_services_hz_vvo_ContactsVVO_ContactsVVO1>#q computed SQLStmtBufLen: 663, actual=623, storing=653
    [377] select
    oc.JOB_TITLE,
    oc.PARTY_SITE_ID,
    RELATIONSHIP_ID ,
    hp.PARTY_NAME OBJECT_NAME, -- Contact
    OBJECT_ID ,
    hr.PARTY_ID ,
    oc.CONTACT_KEY,
    subject_id,
    hp.EMAIL_ADDRESS,
    hp.primary_phone_country_code,
    hp.primary_phone_area_code,
    hp.primary_phone_number
    from HZ_ORG_CONTACT_ROLES ocr,
    HZ_ORG_CONTACTS oc,
    HZ_PARTIES hp,
    HZ_RELATIONSHIPS hr
    where
    hp.party_id = hr.object_id
    and hr.RELATIONSHIP_ID=oc. PARTY_RELATIONSHIP_ID
    and oc.ORG_CONTACT_ID = ocr.ORG_CONTACT_ID(+)
    and relationship_code = 'CONTACT'
    order by OBJECT_NAME
    [378] Bind params for ViewObject: LOCALVIEW_USAGE_com_craneae_services_hz_vvo_ContactsVVO_ContactsVVO1
    Thanks!
    Edited by: user621288 on Jun 17, 2009 4:11 PM

    There are two ways:
    1. Uncheck "Query List Automatically" under List UI Hints in the view object overview xml.
    2. In the query add "where 1=:bnum and 1 is not null" and execute the query in the LaunchPopupEvent
        public void userIdId_launchPopupListener(LaunchPopupEvent launchPopupEvent) {
            DCIteratorBinding myListIter = (getItrtBindings("MyLovViewObj1Iterator"));
            ViewObject vo = myListIter.getViewObject();
            NavigatableRowIterator myItemList = myListIter.getNavigatableRowIterator();
            Row row = myItemList.first();
            Object[] val = row.getAttributeValues();
            ViewRowSetImpl vor = (ViewRowSetImpl)val[row.getAttributeCount() - 1];
            vor.setNamedWhereClauseParam("bnum", new BigDecimal(1));
            vor.executeQuery();
        }

Maybe you are looking for