Skip to Main Content

Java Development Tools

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

BC4J FindByKey problem

383782Aug 5 2003 — edited Aug 5 2003
I have a uiXML page where the user is entering data into a form, based on a entity object. A new row is created and the row key is set as a paeg property. In my java class (called from an event handler) I am trying to locate the newly created (and committed) row based on that key. The error I am receiving is :

oracle.jbo.DMLException: JBO-26080: Error while selecting entity for Screening

java.sql.SQLException: ORA-01410: invalid ROWID

The handler on my uiXML page looks like this
 <event name="apply" >
 <bc4j:chaining>
 <bc4j:findRootAppModule name="ScreeningView1AppModule" >
    <bc4j:findViewObject name="ScreeningView1" >
        <bc4j:findRow name="CreateScreeningView1"  >

          <bc4j:setPageProperty name="key" >
            <bc4j:stringKey/>
          </bc4j:setPageProperty>

          <bc4j:setPageProperty name="screeningSite">
            <bc4j:parameter name="Site"/>
          </bc4j:setPageProperty>

          <bc4j:setAttribute name="Site"/>
          <bc4j:setAttribute name="Dob"/>
          <bc4j:setAttribute name="SjPositive"/>
          <bc4j:setAttribute name="SjSurvey"/>
          <bc4j:setAttribute name="Sj3Criteria"/>        
          <bc4j:setAttribute name="ConsentForm"/>        
          <bc4j:setAttribute name="ExcludedDiseases"/>                
          <bc4j:setAttribute name="ExcludedDisorders"/>                
          <bc4j:setAttribute name="SerumCreatinine"/>                        
          <bc4j:setAttribute name="HadCancer"/>                        
          <bc4j:setAttribute name="BirthControlOk"/>                        
          <bc4j:setAttribute name="OtherTrials"/>                        
          <bc4j:insertRow/>
          <bc4j:commit/>    
        </bc4j:findRow>
    </bc4j:findViewObject>
  </bc4j:findRootAppModule>
  <method class="jivrDemoPackage.Screening" method="createTxn"/> 
  </bc4j:chaining>
 </event>
and my java code in Screening.createTxn is
    ViewObject vo = ServletBindingUtils.getViewObject(context);  
    String pageKey = page.getProperty("key");
    Msg.println("Key page property " + pageKey);
    
    Key key = new Key(pageKey, vo.getAttributeDefs());   
    Row[] viewRows = vo.findByKey(key,1);
    Row viewRow = viewRows[0];
The value printed out for pageKey looks like this "0001000000063837353830380000000A000000F6D14CE6B9
" but straight after this, the error message given at the top of this posting is displayed. Any idea what I'm doing wrong ?

Thanks,
Brent
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Sep 2 2003
Added on Aug 5 2003
1 comment
354 views