ViewObject's query...

Hi! I don't have error messages..
But it seems like the where clasue has no effect into bc4j uix page...
I see all the records in bc4j:table ..:- (
Is it possible to use query which makes permanent affects on bc4j?
Thx,
Viktor
ApplicationModule DeptAppModule = Configuration.createRootApplicationModule("PenCmpPackage.PenCmpAppModule","SomethingComesHere");
ViewObject vo = DeptAppModule.findViewObject("RdmsViewUsage");
vo.setWhereClause( " RdmEntityUsage.Shortname = :1" );
vo.setWhereClauseParam( 0, "AAA" );
vo.executeQuery( );
Page pp=new Page("RdmsViewUsage");
EventResult er=new EventResult(pp);
return er;

Bye the way... i found the answear...
The reason why i couldn't see the result in BC4J is:
when you call setWhereclause it runs on a different object. You must get exatly the same object what bc4j had created.
From bajacontext you can reach everything...
like appmodule.. and even so ViewObject..
Add a null event, which run before your page is rendered...
<event name="null">
  <bc4j:findRootAppModule name="PenCmpAppModule">
    <bc4j:findViewObject name="RdmsViewUsage">
    <method class="FrmFilters" method="handleRdms"/>
   </bc4j:findViewObject>
</bc4j:findRootAppModule>
</event>and create an event handler...
public static EventResult handleRdos(BajaContext context, Page page, PageEvent event)
   ViewObject vobj= ServletBindingUtils.getViewObject(context);
    HttpSession session = context.getServletRequest().getSession(false);
    String OrgId=(String)session.getAttribute("S_ORGID");
    vobj.setWhereClause("ORG_ID='"+OrgId+"'");
    vobj.executeQuery();
    return null;
  }I hope i could help...
Viktor

Similar Messages

  • Optimization of ViewObject's query updates

    Hello,
    I'd like to know wether calling the setWhereClause() / setWhereClauseParams() / setOrderByClause and other similar methods automatically mark a viewObject's query as "changed" (and cause the query to be re-executed on the next navigation event) or
    if they first check that the new clause / params are actually different from the current ones?
    This would allow me to know wether it's worth checking the parameters actual modification to avoid the query from being re-executed, or if I can just trust the underlying mechanisms to do the job.
    Thanks for any answer,
    Remi DEH

    Hello again,
    Actually, while debugging , I noticed there was a "queryChanged" flag in the view object (or was it in the underlying RowSet object?), although its behaviour is not as clear as its name would let think.
    There is also a isQueryChanged() method in ViewObjectImpl but in the doc it is described as "Internal: Applications shouldn't use this method" :).
    Therefore, I guess that I should perform the checks in my code rather than relying on the BC4J framework to do this kind of optimization, which is suitable for me. (I just wanted to be sure I wasn't going to re-implement something that's already done).
    Thanks for your answer.
    Remi DEH
    <BLOCKQUOTE><font size="1" face="Verdana, Arial">quote:</font><HR>Originally posted by JDev Team (Laura):
    Remi,
    I don't believe there is any type of 'change flag' set on the View Object. You can use the getWhereClause, getWhereClauseParams or getOrderByClause methods to retrieve and investigate the 'current' settings for the VO query.
    See the javadocs for the ViewObject Interface and ViewObjectImpl class for more information on those methods.
    <HR></BLOCKQUOTE>
    null

  • How to change datasource viewobject main query in .jsp

    Hi i have datasource DataSource viewobject="test"
    now in .jsp page i need to change it main query and after some things again back to default how i can doo it ?
    Thanks for tips!
    ID.
    Jdeveloper Studio Edition Version 11.1.1.6.0
    ADF Business Components
    11.1.1.61.92

    if you want to change where clause or modify the whole query look here
    Changing the WHERE clause or VO Query at runtime in Oracle ADF | Techartifact

  • Expert Mode ViewObject: default 'query by example' mechanism does not work

    In JDeveloper 11G 1.1.1
    I have created an Expert Mode view object(VO) which I'm trying to filter in an ADF Swing Panel
    The Panel contains a Swing Table created by dropping a VO data control on the panel as an ADF bound Swing Table.
    TEST
    Run the panel.
    Set the Query Mode on (from the Database menu)
    Enter a relevant view criterion
    Execute the Query
    TEST FAILS
    Table is refreshed but it still displays the entire VO collection (non-filtered).
    Repeating the same experiment with a default, entity object generated VO works as expected.
    Question
    Can the default 'query-by-example' mechanism as provided by the JUTestFrame and the JUNavigationBar be used with Expert Mode view Objects?
    If yes are there any tricks to making this work?

    Hello Frank;
    Additional TEST RESULTS
    In JDev11G
    The default 'query by example mechanism' does not work if you create a new View Object using the <Select data source...> option <Read-only access through SQL query>.
    However, IT DOES WORK if you create a new ViewObject selecting <Updatable access through entity objects> and in the Query step you select <Expert Mode>
    Could you please check and confirm.
    Thanks!
    Ioannis
    Edited by: imouts on Dec 5, 2008 1:38 PM

  • ViewObject LOV query is executing again and again..

    Hi Experts,
    Currently in my application VO has one LOV component
    DeparmentVO - countryID (LOV) pointing to the CountryVO
    Where CountryVO is a query based and it depends on the user session language "Select countryID, country from Counties where language=:language
    Now application works fine, however whenever the user launched the page the countryVO query is executed again and again and it is not cached. In the DeparmentVO view accessor the is there any way we can specify the CountryVO to be taken fro cache? Or is there any configuration that we need to do inorder to run the country query only once per session?
    Looking forward you advice on this.
    Thanks

    Hi Timo,
    Our jdev version is 11.1.2.1
    We have the page which shows the department table each record has the country LOV.
    After the login the user can view the page at that time the query is executed, after that he may visit some other page and then come back to the same page then again it is executed. The CountryVO list is based on the language so it needs to be load only once per session in my case to optimize the performance.
    Thanks

  • Viewobject  / preparedstatement

    JDeveloper 11.1.1.20.
    Is it possible, from within java-code in an Oracle ADF application, to retrieve data from a database table using a viewobject without interfering with the application?
    Altering the viewobjects where-clause and executing the viewobject's query must have no influence on the rest of the application. Hence the viewobject I get in the java-code must be totally isolated from any
    other use of that viewobject (GUI table and so on).
    Best regards
    Erik

    Hi,
    Unsure what you want exactly.
    If you only retrieve data, you never interfere with the application's database transaction either way.
    But if you want it to be totally isolated, you could retrieve a JDBC connect manually and execute a statement in that connection.
    This would be totally separate from the application module and thus the database transaction for the application module.
    -Anton

  • InputDate and Data parameter from query

    Hello,
    I'm expiriencing some problems with my Web project,
    I have Model and View.
    I created ViewObject from query with parameter:
    SELECT  r.room_id FROM rooms r WHERE (r.from_date>=:from_date);Parameter :from_date has type 'Date'.
    In ApplicationModule everythin works fine, but on jspx no (I've created ADF Parameter Form from ExecuteWithParameters operation)
    <af:inputDate value="#{bindings.from_date.inputValue}"
                                label="#{bindings.from_date.hints.label}"
                                required="#{bindings.from_date.hints.mandatory}"
                                shortDesc="#{bindings.from_date.hints.tooltip}"
                                binding="#{backing_request.inputDate1}"
                                id="inputDate1">
                    <f:validator binding="#{bindings.from_date.validator}"/>
                    <af:convertDateTime pattern="#{bindings.from_date.format}"/>
                  </af:inputDate>In JSPX parameter don't work, maybe it is still default?
    I tried using convertDateTime and modyfing DateFormat in View Object but without effect :(
    Could you please provide me some hint where I could look for my mistake?

    After few hours in fight I finally got working form. I don't know if I'm right, I suppose that it wasn't my bad but SQLDevelopers' ;)
    Originally I added new rows into table with SQLDeveloper, yesterday I created input form on JSPX page and add new row with Submit button, suddenly my 'ExecuteWithParameter' JSPX page has worked.
    Does SQLDeveloper could be the reason?

  • Sort GridControl modeled with parameterized query (bug?)

    I am using JDev 3.2.3. I created a ViewObject in expert mode which contained a parameterized query:
    select emp_name, salary
    from employees
    where
    dept_no = :1
    Then, through a few workarounds, I managed to create a BC4J data form containing a GridControl linked to the ViewObject.
    Cleared the associated empsRowSetInfo.queryOnOpen(false).
    Created a button with action event:
    empsRowSetInfo.setQueryConditionParams(new Object[] {
    deptId
    empsRowSetInfo.executeQuery();
    This all works fine.
    ***The problem***
    If you press on a header to re-sort the grid, a bad sql query error is thrown and details shows the following bad query:
    select * from (
    select emp_name, salary
    from employees
    where
    dept_no = :1)
    order by asc emp_name
    ORA-00904: invalid column name
    The GridControl headers appear to be getting their own copy of the ViewObject's query, then misinterpretting it. This works fine for non-parameterized queries since the column names are explicit. However :1 is not a column name but a place holder in my parameterized query.
    Shouldn't the headers be using the same mechanism to sort the grid as used to populate the grid model originally?
    Any suggestions for a workaround? Pressing a column header fatally breaks the form. Pressing the button again to re-execute the original query continues to throw the error!
    Thanks,

    This is clearly a bug.
    DAC is in 9.0.2 + replaced by JClient.
    It might be hard to get a fix for this problem.
    As far as a workaround.
    You can provide your own SortDelegate.
    Start with diagnosing the problem by extracting the SortDelegate class out of 'dacf-src.zip'.
    Change it into a mySortDelegate.java.
    Set the sortDelegate property on the gridControl. (use an instance of mySortDelegate).
    You should be able to step into your implementation and see what the problem is.
    Hopefully you will be able to fix the problem in your sortDelegate class.

  • ViewObject.setWhereClause() strangeness.

    I've had an interesting problem when using ViewObjects:
    A JSP page uses a ViewObject, and sets the where clause as follows:
    view.setWhereClause("Vendorid = :0");
    view.setWhereClauseParam(0,anId);
    view.executeQuery();
    The query executes just fine. A subsequent JSP page uses the same ViewObject, and sets the where clause as follows:
    view.setWhereClause("Id = :0");
    view.setWhereClauseParam(0,anId);
    view.executeQuery();
    The problem occurs on the second use of the ViewObject: the row is not found! Upon investigation (Using Diagnostic.properties) I discovered that remenants of the where clause from the first use of the ViewObject remain. The query that actually gets executed is as follows:
    [169] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, ...cut... FROM RICSCONTENT Ricscontent WHERE (Id = :0) AND Ricscontent.VENDORID = :1
    As you can see, the where clause includes the Vendorid. When executing the second query first, it works just fine.
    Am I doing something wrong, or is this a defect? Is there a work-around to this problem? Any help would be greatly appreciated.
    Thanks,
    David
    I've included the diagnostic log below:
    "C:\Program Files\Oracle\JDeveloper 3.1\java1.2\jre\bin\javaw.exe" -mx50m -classpath "O:\\_pages;O:\;C:\Program Files\Oracle\JDeveloper 3.1\lib\webtogo.jar;C:\Program Files\Oracle\JDeveloper 3.1\lib\xmlparser.jar;C:\Program Files\Oracle\JDeveloper 3.1\lib\jdev-rt.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jbcl2.0.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jdev-rt.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\connectionmanager.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jbohtml.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jbojdbcpatch.zip;C:\Program Files\Oracle\JDeveloper 3.1\jdbc\lib\oracle8.1.6\classes12.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jbomt.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jboorasql.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jboremote.zip;C:\Program Files\Oracle\JDeveloper 3.1\lib\jndi.jar;C:\Program Files\Oracle\JDeveloper 3.1\lib\xmlparserv2.jar;C:\Program Files\Oracle\JDeveloper 3.1\lib\ojsp.jar;C:\Program Files\Oracle\JDeveloper 3.1\lib\ojc.jar;C:\Program Files\Oracle\JDeveloper 3.1\jswdk-1.0.1\lib\servlet.jar;C:\Program Files\Oracle\JDeveloper 3.1\java1.2\jre\lib\rt.jar" oracle.jdeveloper.debugger.ServletMain \RICSJsp_html\RICSFindVendor.jsp "L:\htmlroot" "C:\Program Files\Oracle\JDeveloper 3.1\lib"
    log3: oracle.jsp.JspServlet: init
    log3: Loading from CLASSPATH com_luxurydomain_rics_dal_DalModule.properties
    log3: Diagnostics: Routing diagnostics to standard output (use -Djbo.debugoutput=silent to remove)
    [00] oracle.jbo(init) Diagnostic Properties: Timing:false Functions:true Linecount:true Threshold:6log3:
    [01] JboInitialContextFactory.getInitialContext(Hashtable) BC4JDeployPlatform: LOCALlog3:
    [02] PropertyManager.loadProperties(Hashtable) {{ begin Loading BC4J properties
    log3:
    [03] PropertyManager.loadProperties(Hashtable) -----------------------------------------------------------log3:
    [04] util.Properties,(Properties) BC4J Property DeployPlatform='LOCAL' -->(SessionImpl) from Client Environmentlog3:
    [05] util.Properties,(Properties) BC4J Property ConnectionMode='0' -->(SessionImpl) from System Defaultlog3:
    [06] util.Properties,(Properties) BC4J Property jbo.fetch.mode='AS.NEEDED' -->(MetaObjectManager) from System Defaultlog3:
    [07] util.Properties,(Properties) Skipping empty Property JBODynamicObjectsPackage from System Defaultlog3:
    [08] util.Properties,(Properties) BC4J Property MetaObjectContextFactory='oracle.jbo.server.xml.DefaultMomContextFactory' -->(MetaObjectManager) from /oracle/jbo/server/jboserver.properties resourcelog3:
    [09] util.Properties,(Properties) BC4J Property java.naming.factory.initial='oracle.jbo.common.JboInitialContextFactory' -->(MetaObjectManager) from Client Environmentlog3:
    [10] util.Properties,(Properties) BC4J Property MetaObjectContext='oracle.jbo.server.xm l.XMLContextImpl' -->(MetaObjectManager) from /oracle/jbo/server/jboserver.properties resourcelog3:
    [11] util.Properties,(Properties) BC4J Property IsLazyLoadingTrue='true' -->(MetaObjectManager) from /oracle/jbo/server/jboserver.properties resource
    log3:
    [12] util.Properties,(Properties) BC4J Property ActivateSharedDataHandle='false' -->(MetaObjectManager) from System Defaultlog3:
    [13] util.Properties,(Properties) Skipping empty Property HandleName from System Defaultlog3:
    [14] util.Properties,(Properties) Skipping empty Property Factory-Substitution-List from System Defaultlog3:
    [15] util.Properties,(Properties) Skipping empty Property jbo.project from System Defaultlog3:
    [16] util.Properties,(Properties) BC4J Property jbo.max.cursors='50' -->(MetaObjectManager) from System Defaultlog3:
    [17] util.Properties,(Properties) BC4J Property jbo.assoc.consistent='true' -->(MetaObjectManager) from System Defaultlog3:
    [18] util.Properties,(Properties) BC4J Property jbo.default.language='en' -->(MetaObjectManager) from System Defaultlog3:
    [19] util.Properties,(Properties) BC4J Property jbo.default.country='US' -->(MetaObjectManager) from System Defaultlog3:
    [20] util.Properties,(Properties) BC4J Property jbo.SQLBuilder='Oracle' -->(MetaObjectManager) from /oracle/jbo/server/jboserver.properties resourcelog3:
    [21] util.Properties,(Properties) BC4J Property jbo.jdbc.trace='false' -->(MetaObjectManager) from System Defaultlog3:
    [22] util.Properties,(Properties) BC4J Property jbo.debug.prefix='DBG' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [23] util.Properties,(Properties) BC4J Property jbo.debugoutput='console' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [24] util.Properties,(Properties) BC4J Property jbo.logging.show.timing='false' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [25] util.Properties,(Properties) BC4J Property jbo.logging.show.function='true' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [26] util.Properties,(Properties) BC4J Property jbo.logging.show.level='false' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [27] util.Properties,(Properties) BC4J Property jbo.logging.show.linecount='true' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [28] util.Properties,(Properties) BC4J Property jbo.logging.trace.threshold='6' -->(Diagnostic) from /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [29] util.Properties,(Properties) BC4J Property jbo.jdbc.driver.verbose='false' -->(Diagnostic) from System Default
    log3:
    log3: Diagnostics: Routing diagnostics to standard output (use -Djbo.debugoutput=silent to remove)
    [30] oracle.jbo(init) Diagnostic Properties: Timing:false Functions:true Linecount:true Threshold:6log3:
    [31] util.Properties,(String) WARNING: Unused property: LC='Calling Function' found in /oracle/jbo/common/Diagnostic.properties resourcelog3:
    [32] PropertyManager.loadProperties(Hashtable) {{ finished loading BC4J properties log3:
    [33] PropertyManager.loadProperties(Hashtable) -----------------------------------------------------------log3:
    [34] oracle.jbo(reportVMProperties) JavaVMVersion: 1.2.280 odvlog3:
    [35] oracle.jbo(reportVMProperties) JavaVMVendor: Oracle Corp.log3:
    [36] oracle.jbo(reportVMProperties) JavaVMName: OJVM VMlog3:
    [37] oracle.jbo(reportVMProperties) OperatingSystemName: Windows NTlog3:
    [38] oracle.jbo(reportVMProperties) OperatingSystemVersion: 5.0log3:
    [39] oracle.jbo(reportVMProperties) OperatingSystemUsername: dgreenlog3:
    [40] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/dal.xml file
    log3:
    [41] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/DalModule.xml file
    log3:
    [42] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicsannotationView.xml file
    log3:
    [43] oracle.jbo(<init>) ViewObject Impl's default fetch mode = 0log3:
    [44] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricsannotation.xml file
    log3:
    [45] oracle.jbo(getInterface) Reached getInterface
    log3:
    [46] oracle.jbo(getInterface) Oracle SQL Builder Version 3.0.0.0.0log3:
    [47] oracle.jbo(populateJboTypeMapEntries) OracleSQLBuilder: populating ORACLE TypeMap entrieslog3:
    [48] jbo.server(<clinit>) UtilMessageBundle (language base) being initialized
    log3:
    [49] Locale,.java(boolean) Stringmanager using default locale: 'null'log3:
    [50] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicscategoryView.xml file
    log3:
    [51] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricscategory.xml file
    log3:
    [52] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicscontentView.xml file
    log3:
    [53] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricscontent.xml file
    log3:
    [54] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicscontentcategoryView.xml file
    log3:
    [55] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricscontentcategory.xml file
    log3:
    [56] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicsratingView.xml file
    log3:
    [57] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricsrating.xml file
    log3:
    [58] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicsthemesView.xml file
    log3:
    [59] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricsthemes.xml file
    log3:
    [60] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicsurlView.xml file
    log3:
    [61] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricsurl.xml file
    log3:
    [62] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/RicsvendorView.xml file
    log3:
    [63] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/Ricsvendor.xml file
    log3:
    [64] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001386Link.xml file
    log3:
    [65] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001386Assoc.xml file
    log3:
    [66] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001383Link.xml file
    log3:
    [67] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001383Assoc.xml file
    log3:
    [68] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001368Link.xml file
    log3:
    [69] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001368Assoc.xml file
    log3:
    [70] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001370Link.xml file
    log3:
    [71] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001370Assoc.xml file
    log3:
    [72] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001371Link.xml file
    log3:
    [73] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001371Assoc.xml file
    log3:
    [74] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001390Link.xml file
    log3:
    [75] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001390Assoc.xml file
    log3:
    [76] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001391Link.xml file
    log3:
    [77] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001391Assoc.xml file
    log3:
    [78] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001379Link.xml file
    log3:
    [79] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001379Assoc.xml file
    log3:
    [80] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001374Link.xml file
    log3:
    [81] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001374Assoc.xml file
    log3:
    [82] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001375Link.xml file
    log3:
    [83] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001375Assoc.xml file
    log3:
    [84] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC001369Link.xml file
    log3:
    [85] oracle.jbo(boolean) Loading from /com/luxurydomain/rics/dal/SysC0013 69Assoc.xml file
    log3:
    [86] lang.String,(Session) Created root application module: 'com.luxurydomain.rics.dal.DalModule'log3:
    [87] lang.String,(Session) Locale is: 'en_US'
    log3:
    [88] oracle.jbo(create) Connected to Oracle JBO Server - Version: 3.1.6.81.0log3:
    [89] oracle.jbo(loadImpl) Using DatabaseTransactionFactory implementation oracle.jbo.server.DatabaseTransactionFactorylog3:
    [90] oracle.jbo(initTransaction) DBTransactionImpl Max Cursors is 50log3:
    [91] oracle.jbo(doRegisterDefaultDriver) OracleSQLBuilder: Registered Oracle JDBC driverlog3:
    [92] oracle.jbo(initTransaction) Trying connection/1: url='jdbc:oracle:thin:RICS/riCs236@localhost:1521:DEVELOP4'...log3:
    [93] oracle.jbo(initTransaction) Successfully logged in
    log3:
    [94] oracle.jbo(initTransaction) JDBCDriverVersion: 8.1.6.0.0
    log3:
    [95] oracle.jbo(initTransaction) DatabaseProductName: Oraclelog3:
    [96] oracle.jbo(initTransaction) DatabaseProductVersion: Oracle8i Enterprise Edition Release 8.1.6.0.0 - Production With the Partitioning option JServer Release 8.1.6.0.0 - Productionlog3:
    [97] oracle.jbo(getDefaultMode) EntityRowSetImpl's jbo.assoc.consistent = true (1)
    log3:
    [98] oracle.jbo(createColumnList) Column count: 12log3:
    [99] jbo.server(int) ViewObject: RicsvendorView Query Statement: log3:
    [100] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Ricsvendor.ID IS NOT NULL )log3:
    [101] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [102] afterRollback.oracle(TransactionEvent) RicsvendorView notify ROLLBACK ...
    log3:
    [103] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [104] oracle.jbo(createColumnList) Column count: 12log3:
    [105] jbo.server(int) ViewObject: RicsvendorView Query Statement: log3:
    [106] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Ricsvendor.ID IS NOT NULL )
    log3:
    [107] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [108] afterRollback.oracle(TransactionEvent) Ricscontent_SysC001369Assoc_RicscontentView notify ROLLBACK ... log3:
    [109] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...
    log3:
    [110] oracle.jbo(createColumnList) Column count: 17log3:
    [111] jbo.server(int) ViewObject: Ricscontent_SysC001369Assoc_RicscontentView Query Statement: log3:
    [112] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Ricscontent.VENDORID = :1)log3:
    [113] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [114] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [115] postChanges.oracle(TransactionEvent) Saving transaction changes...log3:
    [116] jbo.server(int) ViewObject: RicsvendorView Query Statement:
    log3:
    [117] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Id = :0)log3:
    log3: QUERY: SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Id = :0)
    [118] oracle.jbo(createColumnList) Column count: 12log3:
    [119] jbo.server(int) ViewObject: RicsvendorView Query Statement: log3:
    [120] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Id = :0)log3:
    [121] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [122] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [123] oracle.jbo(createColumnList) Column count: 17log3:
    [124] jbo.server(int) ViewObject: RicscontentView Query Statement: log3:
    [125] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Vendorid = :0 AND Contenttype = 'restaurant') AND Ricscontent.VENDORID = :1log3:
    [126] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [127] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [128] lang.Object[],(PreparedStatement) Binding param 2: 3log3:
    [129] oracle.jbo(createColumnList) Column count: 17log3:
    [130] jbo.server(int) ViewObject: RicscontentView Query Statement: log3:
    [131] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Vendorid = :0 AND Contenttype = 'hotel') AND Ricscontent.VENDORID = :1log3:
    [132] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [133] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [134] lang.Object[],(PreparedStatement) Binding param 2: 3log3:
    [135] afterRollback.oracle(TransactionEvent) RicsvendorView notify ROLLBACK ... log3:
    [136] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [137] oracle.jbo(createColumnList) Column count: 12log3:
    [138] jbo.server(int) ViewObject: RicsvendorView Query Statement: log3:
    [139] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Id = :0)log3:
    [140] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [141] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [142] afterRollback.oracle(TransactionEvent) Ricscontent_SysC001369Assoc_RicscontentView notify ROLLBACK ...
    log3:
    [143] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [144] oracle.jbo(createColumnList) Column count: 17log3:
    [145] jbo.server(int) ViewObject: Ricscontent_SysC001369Assoc_RicscontentView Query Statement: log3:
    [146] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Ricscontent.VENDORID = :1)log3:
    [147] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [148] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [149] afterRollback.oracle(TransactionEvent) RicscontentView notify ROLLBACK ... log3:
    [150] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [151] afterRollback.oracle(TransactionEvent) RicsvendorView notify ROLLBACK ...
    log3:
    [152] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [153] oracle.jbo(createColumnList) Column count: 12log3:
    [154] jbo.server(int) ViewObject: RicsvendorView Query Statement: log3:
    [155] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Id = :0)log3:
    [156] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [157] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [158] afterRollback.oracle(TransactionEvent) Ricscontent_SysC001369Assoc_RicscontentView notify ROLLBACK ... log3:
    [159] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [160] oracle.jbo(createColumnList) Column count: 17log3:
    [161] jbo.server(int) ViewObject: Ricscontent_SysC001369Assoc_RicscontentView Query Statement: log3:
    [162] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Ricscontent.VENDORID = :1)log3:
    [163] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [164] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [165] afterRollback.oracle(TransactionEvent) RicscontentView notify ROLLBACK ... log3:
    [166] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [167] postChanges.oracle(TransactionEvent) Saving transaction changes...log3:
    [168] jbo.server(int) ViewObject: RicscontentView Query Statement: log3:
    [169] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Id = :0) AND Ricscontent.VENDORID = :1log3:
    log3: QUERY: SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Id = :0) AND Ricscontent.VENDORID = :1
    [170] oracle.jbo(createColumnList) Column count: 17log3:
    [171] jbo.server(int) ViewObject: RicscontentView Query Statement:
    log3:
    [172] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Id = :0) AND Ricscontent.VENDORID = :1log3:
    [173] executeQuery.java(int) QueryCollection: Created new QUERY statement
    log3:
    [174] lang.Object[],(PreparedStatement) Binding param 1: 14log3:
    [175] lang.Object[],(PreparedStatement) Binding null for 2log3:
    [176] afterRollback.oracle(TransactionEvent) RicsvendorView notify ROLLBACK ... log3:
    [177] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [178] oracle.jbo(createColumnList) Column count: 12log3:
    [179] jbo.server(int) ViewObject: RicsvendorView Query Statement: log3:
    [180] jbo.server(int) SELECT Ricsvendor.ID, Ricsvendor.VENDORNAME, Ricsvendor.ADDRESS1, Ricsvendor.ADDRESS2, Ricsvendor.CITY, Ricsvendor.STATE, Ricsvendor.COUNTRY, Ricsvendor.ZIP, Ricsvendor.DESCRIPTION, Ricsvendor.KEYWORDS, Ricsvendor.NOTES FROM RICSVENDOR Ricsvendor WHERE (Id = :0)log3:
    [181] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [182] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [183] afterRollback.oracle(TransactionEvent) Ricscontent_SysC001369Assoc_RicscontentView notify ROLLBACK ... log3:
    [184] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    [185] oracle.jbo(createColumnList) Column count: 17log3:
    [186] jbo.server(int) ViewObject: Ricscontent_SysC001369Assoc_RicscontentView Query Statement: log3:
    [187] jbo.server(int) SELECT Ricscontent.ID, Ricscontent.PARENTID, Ricscontent.VENDORID, Ricscontent.CONTENTTYPE, Ricscontent.TITLE, Ricscontent.DESCRIPTION, Ricscontent.KEYWORDS, Ricscontent.PREVVERSION, Ricscontent.NEXTVERSION, Ricscontent.SUBMITTEDBY FROM RICSCONTENT Ricscontent WHERE (Ricscontent.VENDORID = :1)log3:
    [188] executeQuery.java(int) QueryCollection: Created new QUERY statementlog3:
    [189] lang.Object[],(PreparedStatement) Binding param 1: 3log3:
    [190] afterRollback.oracle(TransactionEvent) RicscontentView notify ROLLBACK ... log3:
    [191] oracle.jbo(clearQueryCollectionCache) Clear QueryCollection in cache...log3:
    log3: RicscontentView row with Id=14 not found!
    log3: java.lang.RuntimeException: RicscontentView row with Id=14 not found!
    void ricsjsp_html.RICSContent._jspService(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)log3:
    void oracle.jsp.runtime.HttpJsp.service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)log3:
    void oracle.jsp.app.JspApplication.dispatchRequest(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)log3:
    void oracle.jsp.JspServlet.doDispatch(oracle.jsp.app.JspRequestContext)
    log3:
    void oracle.jsp.JspServlet.service(javax.servlet.http.HttpServletRequest, javax.servlet.http.HttpServletResponse)log3:
    void javax.servlet.http.HttpServlet.service(javax.servlet.ServletRequest, javax.servlet.ServletResponse)log3:
    void oracle.lite.web.JupServlet.service(oracle.lite.web.JupRequest, oracle.lite.web.JupResponse)log3:
    void oracle.lite.web.MimeServletHandler.handle(oracle.lite.web.JupApplication, java.lang.String, int, oracle.lite.web.JupRequest, oracle.lite.web.JupResponse)log3:
    void oracle.lite.web.JupApplication.service(oracle.lite.web.JupRequest, oracle.lite.web.JupResponse)log3:
    void oracle.lite.web.JupAppHandler.handle(oracle.lite.web.JupRequest, oracle.lite.web.JupResponse)log3:
    void oracle.lite.web.HTTPServer.include(javax.servlet.ServletRequest, javax.servlet.ServletResponse)log3:
    void oracle.lite.web.HTTPServer.forward(javax.servlet.ServletRequest, javax.servlet.ServletResponse)log3:
    boolean oracle.lite.web.HTTPServer.handleRequest(oracle.lite.web.JupInputStream, java.io.OutputStream)log3:
    boolean oracle.lite.web.JupServer.handle(oracle.lite.web.JupInputStream, java.io.OutputStream)log3:
    void oracle.lite.web.JupHTTPListener$JupHTTP.run()log3:
    null

    I've discovered that if I call
    ApplicationModule.remove();
    at the end of every JSP page, and I prevent JSPApplicationRegistry.returnAppModuleInstance(); from being called, it works. Obviously this is not a longterm solution.
    null

  • Creating Lov based on dynamic viewobject

    Hi,
    I'm trying to create a lov page that is based on a viewobject whose query (and bindings) are set at runtime (like Steve Muench shows in one of his undocumented ADF samples).
    In the prepareModel() I do the following:
    -unbindRowsetIteratorFromDynamicQueryIteratorBinding(...)
    -changeDynamicViewObjectQuery(...)
    -recreateRangeBindingForDynamicQuery(...)
    -removeControlBinding(...)
    -addDynamicRangeBinding(...)
    So I remove the existing binding, change the query of the viewobejct and recreate the bindings.
    I have got most of the code running except for 2 issues:
    1. The first time I call my Lov I get the a stacktrace (included at the end of this post). If I close the window and click the Lov button again it is working fine.
    2. After I have selected a value in my Lov the value is set in my calling screen. If I commit the new value is commited to the database, but the value in the screen is set back to the original value! If I then refresh the iterator by clicking a tableheader the correct values are shown.
    I do not know if these two issues are related but if someone could give me a hint in which direction I have to look for a solution for one of the problems, I would be very glad.
    I'm using JHeadstart 10.1.2.2 (32) and generating JSP's.
    Here is the stacktrace I am getting:
    javax.servlet.jsp.JspException: An error occurred while evaluating custom action attribute "value" with value "${bindings.OpmerkingenLookupIterator.rangeStart}": An error occurred while getting property "rangeStart" from an instance of class oracle.jbo.uicli.binding.JUIteratorBinding (java.lang.NullPointerException)
         at org.apache.taglibs.standard.lang.jstl.Evaluator.evaluate(Evaluator.java:146)
         at org.apache.taglibs.standard.lang.jstl.Evaluator.evaluate(Evaluator.java:166)
         at org.apache.taglibs.standard.lang.support.ExpressionEvaluatorManager.evaluate(ExpressionEvaluatorManager.java:112)
         at org.apache.taglibs.standard.tag.el.core.ExpressionUtil.evalNotNull(ExpressionUtil.java:85)
         at org.apache.taglibs.standard.tag.el.core.SetTag.evaluateExpressions(SetTag.java:147)
         at org.apache.taglibs.standard.tag.el.core.SetTag.doStartTag(SetTag.java:95)
         at web2d_inf._page._referentie._LovOpmerkingenLookup._jspService(_LovOpmerkingenLookup.java:131)
         [SRC:/WEB-INF/page/referentie/LovOpmerkingenLookup.jsp:28]
         at com.orionserver[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:349)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:765)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:220)
         at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
         at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:274)
         at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
         at org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:320)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
         at oracle.jheadstart.controller.strutsadf.JhsRequestProcessor.process(JhsRequestProcessor.java:385)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         at oracle.jheadstart.controller.strutsadf.JhsActionServlet.process(JhsActionServlet.java:130)
         at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
         at oracle.jheadstart.controller.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:176)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:16)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:239)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:600)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:270)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
         at java.lang.Thread.run(Thread.java:534)

    Pascal,
    This sounds like a JDeveloper/ADF issue that is not related to JHeadstart. To simplify the test case, you could create a simple drag-and-drop ADF application without JHeadstart and see if the same problem occurs there. Can you please log a TAR at MetaLink ( http://metalink.oracle.com/ ), or ask this question at the JDeveloper forum at http://otn.oracle.com/discussionforums/jdev.html ?
    Thanks.
    Sandra Muller
    JHeadstart Team
    Oracle Consulting

  • Dynamic domain uses the same ViewObject for different parameters.

    Hi all.
    My version:
    JDeveloper 10.1.3.2
    JHeadstart 10.1.3.1
    When I in the same group different fields use DynamicDomain,as below:
    DynamicDomain with ViewObject(ex:CodeView and parameters set :1),Query Bind Parameters set "a001".
    Then create another DynamicDomain with the same ViewObject, but Query Bind Parameters set "a002".
    Result, all value of the field is Parameters set 'a002'.
    can give me any help?
    Thanks.
    Joy

    Joy,
    The queried data collection is held at the level of the View Object usage. So, while you can reuse the same ViewObject, you need to create two separate View Object usages in the application module, one for each domain.
    Steven Davelaar,
    JHeadstart Team.

  • ViewObjects/PreparedStatements - ensuring validity

    Hi all,
    I'm wondering if there is a better way to ensure validity of a ViewObject's query other then setting the parameters in AppModule.prepareSession(oracle.jbo.Session){
    ViewObject vo = getMyView();
    vo.setWhereClauseParam(0,"%");
    } I'm tempted to overide executeQuery() to force parameters to % when they are not yet set...
    ROUGHLY
    public void executeQuery(){
    Object[] oParams = getWhereClauseParams();
    for(int i=0,length=oParams.length;i < length;i++)
    if( null == oParams[i] ) setWhereClauseParam(i,"%");
    super.executeQuery();
    }... but I figure there must be a better way of doing this.
    Note: I'd like to implement this at the ViewObject level rather then in the AM so that any AM can use the view (or views based on the MyBaseViewObject) w/o having to worry about setting the parameter(s) - worst case it would catch all...
    Any thoughts?

    Thanks 408279! Very much appreciated. That's exactly what I need. Gotta love those articles by Steve...
    Brenden:
    Thank you for your post too. What I was trying to do was default any view object (in a base class). Check out Steve's article, it's a very clean solution. Also w/ just a few more lines you can pull out the assigment
    Object[] defaultValuesForBindVars = new Object[]{ new Number(10),"NEW YORK"};"and set defaultValuesForBindVars in a method of your BaseViewObject ( setDefaultParams() for example ). Call it from your constructor and you've just ensured that any child class can easily specify defaults for view parameters.
    About the code formatting
    use [ code ] your code [ / code ] (no spaces)
    Note: Always preview your post before submitting it when using square bracket markup for bold [ b ], italic [ i ] or [ code ]; the handler for this on OTN forums is buggy and it sometimes doesn't take all the markup (making your post look like cr*p). I'm not sure why they haven't fixed this yet.
    Thanks again for all the help everyone. Very much appreciated!

  • Error when dynamically creating and binding view object

    Hi,
    I'm using JDeveloper 10.1.2.1.0 (1913) to create a JSP - Struts - ADF BC application.
    I'm trying to create a lov page that is based on a viewobject whose query (and bindings) are set at runtime (like Steve Muench shows in one of his undocumented ADF samples).
    In the prepareModel() I do the following:
    -unbindRowsetIteratorFromDynamicQueryIteratorBinding(...)
    -changeDynamicViewObjectQuery(...)
    -recreateRangeBindingForDynamicQuery(...)
    -removeControlBinding(...)
    -addDynamicRangeBinding(...)
    So I remove the existing binding, change the query of the viewobejct and recreate the bindings.
    I have got most of the code running except for 1 issue:
    1. The first time I call my Lov I get the a stacktrace (included at the end of this post). If I close the window and click the Lov button again it is working fine.
    Can someone help me out with this one???
    Here is the stacktrace I am getting:
    javax.servlet.jsp.JspException: An error occurred while evaluating custom action attribute "value" with value "${bindings.OpmerkingenLookupIterator.rangeStart}": An error occurred while getting property "rangeStart" from an instance of class oracle.jbo.uicli.binding.JUIteratorBinding (java.lang.NullPointerException)
         at org.apache.taglibs.standard.lang.jstl.Evaluator.evaluate(Evaluator.java:146)
         at org.apache.taglibs.standard.lang.jstl.Evaluator.evaluate(Evaluator.java:166)
         at org.apache.taglibs.standard.lang.support.ExpressionEvaluatorManager.evaluate(ExpressionEvaluatorManager.java:112)
         at org.apache.taglibs.standard.tag.el.core.ExpressionUtil.evalNotNull(ExpressionUtil.java:85)
         at org.apache.taglibs.standard.tag.el.core.SetTag.evaluateExpressions(SetTag.java:147)
         at org.apache.taglibs.standard.tag.el.core.SetTag.doStartTag(SetTag.java:95)
         at web2d_inf._page._referentie._LovOpmerkingenLookup._jspService(_LovOpmerkingenLookup.java:131)
         [SRC:/WEB-INF/page/referentie/LovOpmerkingenLookup.jsp:28]
         at com.orionserver[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].http.OrionHttpJspPage.service(OrionHttpJspPage.java:56)
         at oracle.jsp.runtimev2.JspPageTable.service(JspPageTable.java:349)
         at oracle.jsp.runtimev2.JspServlet.internalService(JspServlet.java:509)
         at oracle.jsp.runtimev2.JspServlet.service(JspServlet.java:413)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:765)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forward(ServletRequestDispatcher.java:220)
         at org.apache.struts.action.RequestProcessor.doForward(RequestProcessor.java:1069)
         at org.apache.struts.tiles.TilesRequestProcessor.doForward(TilesRequestProcessor.java:274)
         at org.apache.struts.action.RequestProcessor.processForwardConfig(RequestProcessor.java:455)
         at org.apache.struts.tiles.TilesRequestProcessor.processForwardConfig(TilesRequestProcessor.java:320)
         at org.apache.struts.action.RequestProcessor.process(RequestProcessor.java:279)
         at oracle.jheadstart.controller.strutsadf.JhsRequestProcessor.process(JhsRequestProcessor.java:385)
         at org.apache.struts.action.ActionServlet.process(ActionServlet.java:1482)
         at oracle.jheadstart.controller.strutsadf.JhsActionServlet.process(JhsActionServlet.java:130)
         at org.apache.struts.action.ActionServlet.doGet(ActionServlet.java:507)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:740)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:853)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ResourceFilterChain.doFilter(ResourceFilterChain.java:65)
         at oracle.jheadstart.controller.CharacterEncodingFilter.doFilter(CharacterEncodingFilter.java:176)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.EvermindFilterChain.doFilter(EvermindFilterChain.java:16)
         at oracle.adf.model.servlet.ADFBindingFilter.doFilter(ADFBindingFilter.java:239)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.invoke(ServletRequestDispatcher.java:600)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.ServletRequestDispatcher.forwardInternal(ServletRequestDispatcher.java:317)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.processRequest(HttpRequestHandler.java:790)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:270)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].server.http.HttpRequestHandler.run(HttpRequestHandler.java:112)
         at com.evermind[Oracle Application Server Containers for J2EE 10g (9.0.4.0.0)].util.ReleasableResourcePooledExecutor$MyWorker.run(ReleasableResourcePooledExecutor.java:186)
         at java.lang.Thread.run(Thread.java:534)

    Here is some more info:
    I can reproduce the problem using the code Steve Muench supplies in his undocumented ADF samples.
    If you add the following line to the jsp in the example code(browseResultsOfDynamicVO.jsp):
    <c:set var="rangeStart" scope="request" value="${bindings.DynamicViewObjectIterator.rangeStart}"/>You will get the behaviour I am facing.
    The first time in your session you enter a valid query and submit it you get a stacktrace. By refreshing the page it works.
    It looks like that when recreating the bindings at runtime something more is fone that isn't done at design time. So the first time the statement fails but once the bindings have been recreated at runtime it suddenly works....
    The main question is: what is it that is done at runtime and is missing at design time?

  • A few ADF BC state passivation/activation problems

    Our development team has encountered and researched a few ADF BC passivation/activation related bugs that are very annoying. Some of them have been fixed in the new JDeveloper 11gR1 (11.1.1.1.0) but other ones are still active in the last production release. As we consider some of these bugs as very important we decided to report them in this forum:
    *1) New (modified) values of read-only SQL-derived or transient attributes are not activated if they have been modified in ViewObject's cache and the corresponding changes have not been posted to DB yet*
    The attribute values are included into the passivated state but the activation process does not try to activate a modified value if the method <tt>ViewRowImpl.isAttributeUpdateable(int)</tt> returns <tt>false</tt> for the corresponding row attribute. There are many business cases when some ViewObject attributes have to be modified despite the fact they are read-only (or conditionally read-only depending on the values of another attributes).
    *2) Transient values (values of SQL-derived or transient attributes) that have been modified in ViewObject's cache to <tt>null</tt> are not cleared on state activation*
    This is true even for updateable attributes. The problem exists because the passivation process does not write into the passivated state anything about attributes having <tt>null</tt> values. As a consequence the activation process does not try to modify values of the corresponding attributes during the activation and they keep the value fetched from the ViewObject's query.
    *3) State activation process does not restore ViewCriteria row names*
    As a result the query components (<af:query>, <af:quickQuery> and table filters) do not work correctly after state passivation/activation because they do not clear eventual previously applied filter condition as they do that by searching ViewCriteria rows having particular names. In this way the new condition is appended instead of overriding eventual previous one.

    Hi Maxa,
    I am the thread owner. Sorry for the delay, but my forum account was destroyed during the transition to the new Oracle's SSO, so I had to create a new account and I have missed your posting.
    The table filter problem was resolved in the new JDev 11.1.1.2. The bug number is "Bug 8650239 - FILTERING CRITERIA ARE APPENDED WHEN AM POOLING IS DISABLED".
    If you have to use previous JDev 11g version then the you have to patch the class oracle.jbo.ViewCriteria in the archives adfm.jar and oracle.adf.model_11.1.1.ear as follows (look at the bold lines):
    {font:Courier}
    public void passivate(XMLDocument doc, XMLElement node) {
    ViewCriteriaRow r = (ViewCriteriaRow)row;
    for(int j = 0; j < r.getAttributeCount(); j++) {
    if(rowNode == null) {
    rowNode = doc.createElement("Row");
    ((XMLElement)rowNode).setAttribute("uc", r.isUpperColumns() ? "1" : "0");
    ((XMLElement)rowNode).setAttribute("cj", (new StringBuilder()).append("").append(r.getConjunction()).toString());
    *((XMLElement)rowNode).setAttribute("n", r.getName() == null ? "" : r.getName());*
    public void activate(XMLElement node) {
    for(Node rowNode = node.getFirstChild(); rowNode != null;) {
    ViewCriteriaRow vcr = createViewCriteriaRow();
    s = ((XMLElement)rowNode).getAttribute("uc");
    if(s != null && s.length() > 0)
    vcr.setUpperColumns(Integer.valueOf(s).intValue() == 1);
    s = ((XMLElement)rowNode).getAttribute("cj");
    if(s != null && s.length() > 0)
    vcr.setConjunction(Integer.valueOf(s).intValue());
    String name = ((XMLElement)rowNode).getAttribute("n");
    if(name != null && name.length() > 0)
    vcr.setName(name);
    {font}
    You have to decompile the class, add the bold lines, compile the class and repack it into the specified archives. I am affraid it is not quite legal to patch Oracle's classes but I do not have other solution.

  • How to generate complex reports with JHeadStart?

    I have data from a DataSourceSet process in the infoTable (I use BC4J 9.0.3.10.7, JHeadStart 9.0.3.58, Oracle MVC R.Candidate 2.0, UIX 2.1.9).I need to generate a report with this data in a UIX Table. Actually, I show the data as retrieved from the ViewObject(Whole query in a table). One of the columns has Numbers and I add them at the bottom row with a GetTotalsRow process.
    Now I need to have subtotals in the same table as if I do a GROUP BY but without modifying the query (I have to do this using data stored in infoTable). I also have to add complex calculations for each row.
    Any idea?
    PD: I'm thinking in reading data from infoTable and in a custom process create DataObjectList with all details.
    is it a good approach?
    is there something better?

    Ariel,
    I think I already answered this question on the internal mailing list. Is this correct?
    If you are an Oracle employee, please use the internal mailing list.
    Thanks,
    Steven Davelaar.
    JHeadstart team.

Maybe you are looking for