Using SQL Transactions in a JSF page

Hi,
I have got a problem implementing SQL Transactions into a JSF page.
Here is my problem:
I have go an object named "database" which contains the connection and the necessary method to launch queries, connection,...
the database object is instantiated in the constructor of the page.
I will name as "the process", this :
database.connectTo(); //the instantiation of the connection
database.connection.setAutoCommit(false);
database.executeNonQuery("any insertion query");
database.executeNonQuery("any insertion query2");
database.executeNonQuery("any insertion query3");
database.executeNonQuery("COMMIT");
(As you can see, it's just a preliminary test, the rollback is not tested yet)
If I put the entire process in a single method, everything works fine.
If I split the queries and the commit query, the commit is not launched because the connection of my object "database" is null. I mean by "splitting", the launch of the 3 insertion queries is in a method (of a button for example) and the launch of the commit query is in another method (another button).
It appears that the attribute connection is set to null after the launch of the three queries...
Moreover, nothing is inserted in the database (this logical since the commit is not launched).
Has anyone a clue?

Your database transaction should not span two buttons. The two buttons will be called on separate requests -- that is, separate calls to the server -- and you'll have a database connection dangling out there, potentially locking other people out of certain tables/rows until the user clicks the right button.
Note also that there is a commit() method in the JDBC API.
You might want to spend some time studying some example applications.

Similar Messages

  • How to use Apache MyFaces components in JSF pages + Eclipse?

    I've managed to write my JSF web app. in Eclipse jee, and test it on JBoss 4.2 GA, within Eclipse, but how to import Apache MyFaces components into Eclipse JSF plug-in?
    If I can't import it nicely, how to use those components directly in JSF pages?

    The Tomahawk component library provides MyFaces components. Install it as you would any other component library.
    http://myfaces.apache.org/tomahawk/

  • Recovering data using SQL transaction logs

    Hi-If we have a backup of our HFM database (in SQL) as of 8am today, and we backup the transaction logs too, can we use them to restore the database in case of an issue. Example, the database gets corrupted or someone deletes the wrong data. Can we restore the backup and then use the transaction logs to recreate the activities since the backup? Would this work if some of those activities were data loads via FDQM?
    just checking if it makes sense to do these transaction log backups in SQL as it relates to HFM 9.2.1
    Thanks
    Wags

    If your company performs full backups at the close of business every Friday and differential backups every Monday through Thursday evening. You could include hourly backups of the transaction log during business hours. Assume a database failure at 11:05AM Wednesday. Under this strategy, you would use Friday's full backup and Tuesday's differential backup to restore the database to it's state at the close of business Tuesday. This resulted in a loss of two hours of data (9-11AM Wednesday). Using the transaction log backups, you could apply the 9AM and 10AM transaction log backups after the Tuesday differential backup to restore our database to it's state at 11AM Wednesday. Restoring all but five minutes of database activity.

  • How to use ocx with javascript in jsf page

    Hello,
    Please i create a jsf page which purpose is to scan.
    I used in a source of my jsf page an OCX with object tag like
    <OBJECT ID="Ranger"
    CLASSID="CLSID:1C5C9095-05A8-11D4-9AF9-00104B23E2B1">
    </OBJECT>
    i wrote my functions which use this ocx in javascript. Function that i call with clientlistener rear adf button
    but it doesn't work
    Could you please help me please VERY IMPORTANT

    This my html code:
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportNewState(newState,previousState)>  
    // Transport new state, fired every time the State changes on the control
    // input params , are the new state and the previous state
    //alert(newState);
    var RangerTransportStates = {TransportUnknownState: -1, TransportShutDown: 0, TransportStartingUp: 1,
                                  TransportChangeOptions: 2, TransportEnablingOptions: 3, TransportReadyToFeed: 4,
                                  TransportFeeding: 5, TransportExceptionInProgress:6, TransportShuttingDown: 7};
    if(newState == RangerTransportStates.TransportShutDown)
          document.getElementById('StartRanger').disabled = false;
          document.getElementById('EnableRanger').disabled = true;
          document.getElementById('StopFeeding').disabled = true;
          document.getElementById('StartFeeding').disabled = true;
          document.getElementById('ChangeOptions').disabled = true;
          document.getElementById('Shutdown').disabled = true;     
          document.getElementById('UserInstructions').innerHTML = "Press 'Startup Ranger' to initialize the Ranger control"
    if(newState == RangerTransportStates.TransportChangeOptions)
          document.getElementById('StartRanger').disabled = true;
          document.getElementById('StartFeeding').disabled = true;
          document.getElementById('EnableRanger').disabled = false;
          document.getElementById('Shutdown').disabled = false;
          document.getElementById('UserInstructions').innerHTML = "<b>Ranger Started</b> <br> Press 'Enable Ranger' to enable the current Ranger Options and prepare to start feeding"
    if(newState == RangerTransportStates.TransportReadyToFeed)
          document.getElementById('EnableRanger').disabled = true;
          document.getElementById('StopFeeding').disabled = true;
          document.getElementById('StartFeeding').disabled = false;
          document.getElementById('ChangeOptions').disabled = false;
          document.getElementById('Shutdown').disabled = false;
          document.getElementById('UserInstructions').innerHTML = "<b>Ready to feed </b><br> Press 'Start Feeding' to start Ranger Feeding checks from main hopper"
    if(newState == RangerTransportStates.TransportFeeding)
          document.getElementById('StartFeeding').disabled = true;
          document.getElementById('ChangeOptions').disabled = true;
          document.getElementById('Shutdown').disabled = true;
          document.getElementById('StopFeeding').disabled = false;     
          document.getElementById('UserInstructions').innerHTML = "<b>Feeding... </b><br> Press 'Stop Feeding' to stop Ranger from Feeding checks"
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportChangeOptionsState(previousState)>  
    //Fired when Ranger reaches the change option state, input params are previous state
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportReadyToFeedState(previousState)>  
    //Fired when ranger is ready to feed the next item
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportFeedingStopped(reason,itemsFed,itemsrequested)>  
    //Fired when feeding has stopped
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportItemInPocket(itemID)>  
    //Fired when the item has been fed into the pocket
    var RangerSides = {TransportFront: 0, TransportRear: 1};
    var RangerImageColorTypes = {ImageColorTypeBitonal:0, ImageColorTypeGrayscale: 1, ImageColorTypeColor: 2};
    // Note: SaveImageToFile() below is used to save gray scale images.  Please verify that 'NeedFrontImage2' and
    //       'NeedRearImage2' are set to 'true' in the GenericOptions.ini file.  If bitonal images are to be saved,
    //       please set 'NeedFrontImage1'/'NeedRearImage1' to 'true' before calling SaveImageToFile() for bitonal images.
    document.getElementById('MICR').innerHTML = 'MICR: ' + Ranger.GetMicrText(1);
    temp = Ranger.SaveImageToFile(RangerSides.TransportFront, RangerImageColorTypes.ImageColorTypeGrayscale, "C:\\test\\Testfront.jpg");
    temp = Ranger.SaveImageToFile(RangerSides.TransportRear, RangerImageColorTypes.ImageColorTypeGrayscale,"C:\\test\\Testback.jpg");
    //Here you could check to see if the images were saved, putting alternate
    //text in place of the image if they werent saved.
    document.getElementById('PIC').innerHTML = '<img height=200 width=400 src=' + '"Testfront.jpg">' + '<br>' + '<img height=200 width=400 src=' + '"Testback.jpg">';
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportNewItem()>  
    // Fired when a new item has entered the track
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportShutDownState(currentState,previousState)>  
    //Fired when the Ranger control has been shutdown
    getstatus();
    </SCRIPT> 
    <SCRIPT LANGUAGE=javascript FOR=Ranger EVENT=TransportSetItemOutput(itemID)>  
    //fired when the item is ready to have params set(pocketing decisions)
    getstatus();
    </SCRIPT> 
    <!-- End of Events ------------- -->
    <SCRIPT LANGUAGE="javascript">
    function getstatus()
         document.getElementById('Status').innerHTML = 'Status: ' + Ranger.GetTransportStateString();
    </SCRIPT>
    </head>
    <body>
    <OBJECT ID="Ranger"
    CLASSID="CLSID:1C5C9095-05A8-11D4-9AF9-00104B23E2B1">
    </OBJECT>
    <div id="container">
         <div id="banner" >
         </div>
         <div id="left">
              <h2>Ranger Control Buttons</h2>
              <br><div id="Status">Status:</div><br>
              <input class="controlbutton" id="StartRanger" type=button value="Startup Ranger" onclick="Ranger.Startup();">
              <input class="controlbutton" id="EnableRanger" disabled type=button value="Enable Ranger" onclick="Ranger.EnableOptions();">
              <input class="controlbutton" id="StartFeeding" disabled type=button value="Start Feeding" onclick="Ranger.StartFeeding(0,0);">
              <input class="controlbutton" id="StopFeeding" disabled type=button value="Stop Feeding" onclick="Ranger.StopFeeding();">
              <input class="controlbutton" id="ChangeOptions" disabled type=button value="Change Options" onclick="Ranger.PrepareToChangeOptions();">
              <input class="controlbutton" id="Shutdown" disabled type=button value="Shutdown Ranger" onclick="Ranger.Shutdown();">
         </div>
         <div id="content">
              <div id="UserInstructions">Press 'Startup Ranger' to initialize the Ranger control</div>
              <br>
              <div id="MICR"></div>
              <br>
              <div id="PIC"></div>
         </div>
         <div id="footer"><h1>Ranger Control</h1></div>
    </div>
    them jsf code:
    <f:view>
    <OBJECT ID="Ranger"
        CLASSID="CLSID:1C5C9095-05A8-11D4-9AF9-00104B23E2B1">
    </OBJECT>   
      <af:document id="d1" title="Fiche Bordereau">
        <af:messages id="m1"/>
        <af:form id="f1">
          <af:pageTemplate viewId="/tempCompens.jspx" id="pt1">
           <af:resource type="javascript">
            // Transport new state, fired every time the State changes on the control
            // input params , are the new state and the previous state
            //alert(newState);
            var RangerTransportStates = {TransportUnknownState: -1, TransportShutDown: 0, TransportStartingUp: 1,
                                  TransportChangeOptions: 2, TransportEnablingOptions: 3, TransportReadyToFeed: 4,
                                  TransportFeeding: 5, TransportExceptionInProgress:6, TransportShuttingDown: 7};
            ok =false;
            var i = 0;
            if(newState == RangerTransportStates.TransportShutDown)
                document.getElementById('btn_demarre').disabled = false;
                document.getElementById('btn_active').disabled = true;
                document.getElementById('btn_arretscan').disabled = true;
                document.getElementById('btn_scan').disabled = true;
                document.getElementById('btn_changetat').disabled = true;
                document.getElementById('btn_arret').disabled = true;
                document.getElementById('UserInstructions').value = "Appuyer sur Demarrer pour initiliser le scanner"
            if(newState == RangerTransportStates.TransportChangeOptions)
                document.getElementById('btn_demarre').disabled = true;
                document.getElementById('btn_scan').disabled = true;
                document.getElementById('btn_active').disabled = false;
                document.getElementById('btn_arret').disabled = false;
                document.getElementById('UserInstructions').value = "Demarrage... Appuyer sur Activer pour preparer le scanning "
                ok = false;
            if(newState == RangerTransportStates.TransportReadyToFeed)
                document.getElementById('btn_active').disabled = true;
                document.getElementById('btn_arretscan').disabled = true;
                document.getElementById('btn_scan').disabled = false;
                document.getElementById('btn_changetat').disabled = false;
                document.getElementById('btn_arret').disabled = false;
                document.getElementById('UserInstructions').value = "Pret a scanner.   Appuyer sur Scanner pour lancer le scanning"
                ok = true;
            if(newState == RangerTransportStates.TransportFeeding)
                document.getElementById('btn_scan').disabled = true;
                document.getElementById('btn_changetat').disabled = true;
                document.getElementById('btn_arret').disabled = true;
                document.getElementById('btn_arretscan').disabled = false;
                document.getElementById('UserInstructions').value = "Scanning...  Appuyer sur Arret scanning pour stopper le scanning"
            getstatus();
           </af:resource>
           <af:resource type="javascript">
            //Fired when the item has been fed into the pocket
                var RangerSides = {TransportFront: 0, TransportRear: 1};
                var RangerImageColorTypes = {ImageColorTypeBitonal:0, ImageColorTypeGrayscale: 1, ImageColorTypeColor: 2};
            //alert(Ranger.GetGenericOptionFileName());
                Ranger.SetGenericOption("OptionalDevice","NeedFrontImage1",true);
                Ranger.SetGenericOption("OptionalDevice","NeedRearImage1",true);
                document.getElementById('cmc7').value = 'CMC7= '+Ranger.GetMicrText(1);
                var cmc7 = trim(Ranger.GetMicrText(1));
                cmc7 = cmc7.replace(" ","_");
                cmc7 = cmc7.replace(" ","_");
            //cmc7 = cmc7.substring(0,15);
                cmc7R = cmc7+"_R.jpg";
            //alert(Ranger.GetImageAddress(RangerSides.TransportFront, RangerImageColorTypes.ImageColorTypeGrayscale))
                function trim(myString)
                    return myString.replace(/^\s+/g,'').replace(/\s+$/g,'')
                temp = Ranger.SaveImageToFile(RangerSides.TransportFront, RangerImageColorTypes.ImageColorTypeGrayscale, "C:\\Documents and Settings\\Koffi Ernest\\Mes documents\\NetBeansProjects\\Scan-project\\web\\"+cmc7R);
                window.onload = function()
                  document.getElementById("verso").src = monfichierV();
                function monfichierR()
                //  nomfichier = nomfichier+"_R.jpg";
                    var nomfichier = trim(Ranger.GetMicrText(1))+"_R.jpg";
                    return  nomfichier
                cmc7V = cmc7+"_V.jpg";
                temp = Ranger.SaveImageToFile(RangerSides.TransportRear, RangerImageColorTypes.ImageColorTypeGrayscale,"C:\\Documents and Settings\\Koffi Ernest\\Mes documents\\NetBeansProjects\\Scan-project\\web\\"+cmc7V);
                window.onload = function()
                    document.getElementById("verso").src = monfichierV();
                function monfichierV()
                    var nomfichierV = trim(Ranger.GetMicrText(1))+"_V.jpg";
                    return nomfichierV
                function getRImageUrl(img)
                    var imageSrc = trim(Ranger.GetMicrText(1))+"_R.jpg";
                    if(img.src != imageSrc)
                    // don't get stuck in an endless loop
                    img.src = imageSrc;
                function getVImageUrl(img)
                 var imageSrc = trim(Ranger.GetMicrText(1))+"_V.jpg";
                 if(img.src != imageSrc)
                 { // don't get stuck in an endless loop
                  img.src = imageSrc;
            document.getElementById('recto').source = cmc7R;
            document.getElementById('verso').source = cmc7V;
            getstatus();
           </af:resource>
            <af:resource type="javascript">
                 document.getElementById('status').value = Ranger.GetTransportStateString();
            </af:resource>
            <f:facet name="temp">
              <af:panelSplitter id="ps1" splitterPosition="329"
                                inlineStyle="width:709px;">
                <f:facet name="first">
                  <af:panelGroupLayout layout="scroll"
                                       xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
                                       id="pgl5">
                    <af:panelGroupLayout id="pgl1">
                      <af:outputText value="Saisie des informations du bordereau"
                                     id="ot1"
                                     inlineStyle="font-size:small; font-family:inherit; color:Gray; font-weight:bold;"/>
                    </af:panelGroupLayout>
                    <af:panelFormLayout id="pfl1">
                      <f:facet name="footer">
                        <af:panelGroupLayout id="pgl4" layout="horizontal">
                          <af:commandButton text="Annuler" id="cb4"/>
                          <af:spacer width="5" height="10" id="s14"/>
                          <af:commandButton text="Scanner" id="cb5"
                                            action="success"/>
                        </af:panelGroupLayout>
                      </f:facet>
                      <af:spacer width="10" height="30" id="s2"/>
                      <af:panelGroupLayout id="panelGroupLayout1"
                                           layout="horizontal" valign="middle">
                        <af:inputText label="N° de compte                   " id="it1"/>
                        <af:spacer width="10" height="10" id="s16"/>
                        <af:commandButton text="..." id="cb3"/>
                      </af:panelGroupLayout>
                      <af:spacer width="5" height="3" id="s12"/>
                      <af:panelGroupLayout id="pgl2" layout="horizontal"
                                           valign="middle">
                        <af:inputText label="Nom du client         " id="it3"/>
                      </af:panelGroupLayout>
                      <af:spacer width="5" height="3" id="s17"/>
                      <af:panelGroupLayout id="pgl11" layout="horizontal"
                                           valign="middle">
                        <af:inputText label="N° bordereau    " id="it4"/>
                        <af:spacer width="5" height="10" id="s11"/>
                        <af:commandButton text="New" id="cb1"/>
                        <af:spacer width="2" height="10" id="s13"/>
                        <af:commandButton text="Find" id="cb2"/>
                      </af:panelGroupLayout>
                      <af:spacer width="5" height="3" id="s18"/>
                      <af:panelGroupLayout id="pgl3">
                        <af:inputText label="Nbre de chèque" id="it2"/>
                        <af:spacer width="5" height="3" id="s19"/>
                        <af:inputDate label="Date d'operation                  " id="id1"/>
                      </af:panelGroupLayout>
                      <af:spacer width="1000" height="10" id="s1"/>
                    </af:panelFormLayout>
                  </af:panelGroupLayout>
                </f:facet>
                <f:facet name="second">
                  <af:panelGroupLayout layout="scroll"
                                       xmlns:af="http://xmlns.oracle.com/adf/faces/rich"
                                       id="pgl6">
                    <af:outputText value="Resultat scanning" id="ot2"
                                   inlineStyle="font-size:small; font-weight:bold; color:Gray;"/>
                    <af:panelTabbed id="pt2"
                                    inlineStyle="height:498px; width:680px;">
                      <af:showDetailItem text="Scanning" id="sdi1">
                        <af:panelSplitter id="ps2" splitterPosition="103"
                                          inlineStyle="width:433px; height:436px;">
                          <f:facet name="first">
                            <af:panelGroupLayout id="pgl7" layout="vertical">
                              <af:outputText value="Liste de contrôles" id="ot3"
                                             inlineStyle="font-weight:bold; color:Gray;"/>
                              <af:spacer width="10" height="10" id="s20"/>
                              <af:outputText id="status"/>
                              <af:spacer width="10" height="10" id="s8"/>
                              <af:commandButton text="Demarrer      "
                                                id="btn_demarre">
                                <af:clientListener type="click"
                                                   method="Ranger.Startup()"/>
                              </af:commandButton>
                              <af:spacer width="10" height="10" id="s7"/>
                              <af:commandButton text="Activer              "
                                                id="btn_active"
                                                disabled="true">
                                <af:clientListener method="Ranger.EnableOptions()"
                                                   type="click"/>
                              </af:commandButton>
                              <af:spacer width="10" height="10" id="s6"/>
                              <af:commandButton text="Scanner       "
                                                id="btn_scanne"
                                                disabled="true">
                                <af:clientListener method="Ranger.StartFeeding(0,0)"
                                                   type="click"/>
                              </af:commandButton>
                              <af:spacer width="10" height="10" id="s3"/>
                              <af:commandButton text="Arrêt Scan   "
                                                id="btn_arretscan"
                                                disabled="true">
                                <af:clientListener method="Ranger.StopFeeding()"
                                                   type="click"/>
                              </af:commandButton>
                              <af:spacer width="10" height="10" id="s4"/>
                              <af:commandButton text="Changer Etat"
                                                id="btn_changetat"
                                                disabled="true">
                                <af:clientListener method="Ranger.PrepareToChangeOptions()"
                                                   type="click"/>
                              </af:commandButton>
                              <af:spacer width="10" height="10" id="s5"/>
                              <af:commandButton text="Arrêter         "
                                                id="btn_arret"
                                                disabled="true">
                                <af:clientListener method="Ranger.Shutdown()"
                                                   type="click"/>
                              </af:commandButton>
                            </af:panelGroupLayout>
                          </f:facet>
    ....Edited by: nesta on 21 juil. 2010 07:07

  • Use commandLink to forward non-jsf page cause other commandLink invalidate

    Hi :
    I use commandLink to forward to non jsf page , after click the link , it worked , success to 1.jsp. Then I click another link , the other commandLink doesn't work.
    any one have the same problem ?
    JSF page:
    <h:commandLink action="#{MenuHandler.go}">
         <h:outputText value="process" />
         <f:param value="1.jsp" name="forward" />
    </h:commandLink>
    MenuHandler.java
      public static String go() {
                HttpServletRequest req = getRequest();
                String forward = req.getParameter("forward");
                getExternalContext().redirect(forward);
                FacesContext.getCurrentInstance().responseComplete();
                return "success";
      }ps:there is one <h:form/> in my jsf page and I use:
    jdk1.5.0
    jsf-1_1
    Tomcat-5.0.28

    to supplement:
    I found something strange:
    The JSF page I used is for menu purpose.
    So there is a <BASE target="mainFrame"> tag in my JSF page.
    If I mark it . Then other commandLink can work ~~
    Because the page is a menu page , so I can't mark the <BASE target="mainFrame">

  • Temparally remove rows from a ADF table by action event of a jsf page.

    Hello Developers,
    I needed to temporally remove rows of a ADF table when execute action event of corresponding page.
    So in this case my task can describe by following steps,
    (1). I created a ADF table using <af:table> on a jsf page.
    (2). The data populated using a VO.
    (3). Several radio buttons added to the page for temporally remove rows from the table.
    This means one radio button check, it responsible to temporally remove rows which contain empty cell values of a identified column.
    If I check another radio button it should temporally remove identified data included rows but above removed (empty cell included rows) rows should appear in this event
    My ultimate target is temporally remove rows of a table & re call again removed rows another event without again & again query from BC.
    Pleas advice me to archive this task very sealy?
    (Are there have a way to do this using EL or coding in Manage bean ?)
    Thanks in advance..!

    Hi,
    the DCIterator gives you an option to iterate over the fetched rows (the ones you see in the table). You can try call removeAndRetain() on these rows. This will not remove or delete rows but allows you to insert these rows back to the collection.
    JavaDocs:
    * Removes the row from the collection and then retain it for insertion
    * into another location.
    * <p>
    * This method differs from <code>{@link #remove()}</code> in that
    * it just removes the row from the collection. It does not
    * remove the underlying Entity row(s) or database row(s).
    * <p>
    * This method also differs from <code>{@link #removeFromCollection()}</code>
    * in that after the row is removed from the collection, it can be inserted
    * back into the collection at another location.
    void removeAndRetain();
    Frank

  • Problem in using MySQL in JSF Pages

    Hi,
    I am facing a problem regarding use of MySQL in JSF.
    I am using IBM RAD 6.0 for application developement.
    Previously creating a normal java application which is used of retrieval of the data from the database was working fine. by including j/connector jar file in java build path.
    But when same program is converted to web service and accessed through a JSF page using a managed bean it is not working. It throws classNotFoundException
    Please reply at your earliest.
    Thanks in advance.
    Regards,
    Amit
    code :-
    import java.sql.Connection;
    import java.sql.DriverManager;
    import java.sql.ResultSet;
    import java.sql.SQLException;
    import java.sql.Statement;
    public class BeanClass
         public String display()
              Connection conn = null;
              Statement stmt = null;
              ResultSet rs = null;
              String returnDate = "";
              try
                   Class.forName("com.mysql.jdbc.Driver").newInstance();
                   System.out.println("Sucess");
                   conn=DriverManager.getConnection("jdbc:mysql://localhost/switching","root","pspl");
                   System.out.println("Sucess******");
                   stmt = conn.createStatement();
                   System.out.println("Sucess^^^^^^^^^");
                   rs = stmt.executeQuery("SELECT * FROM log1 where senderId = '008' ");
                   System.out.println("Sucess#########");
                   while(rs.next())
                        System.out.println("Date : " + rs.getString("expDate"));
                        returnDate = rs.getString("expDate");
                   System.out.println("Final success");     
                   System.out.println("Sucess@@@@@@@@@@@@@@@@");
              }catch(ClassNotFoundException cnfe)
                   System.err.println("Drivers not found " + cnfe.toString());
                   cnfe.printStackTrace();
              catch(IllegalAccessException iae)
                   System.err.println("Access Exception");
              catch(InstantiationException ie)
                   System.err.println("Instatiation Exception");
              catch(SQLException se)
                   System.err.println("SQL EXCEPTION");
                   se.printStackTrace();
              System.out.println("Date is = " + returnDate);
              return returnDate;
    Errors are :-
    [5/3/06 10:47:33:358 IST] 00000061 SystemErr R java.lang.ClassNotFoundException: com.mysql.jdbc.Driver     at com.ibm.ws.classloader.CompoundClassLoader.findClass(CompoundClassLoader.java(Compiled Code))
         at com.ibm.ws.classloader.CompoundClassLoader.loadClass(CompoundClassLoader.java(Compiled Code))
         at java.lang.ClassLoader.loadClass(ClassLoader.java(Compiled Code))
         at java.lang.Class.forName1(Native Method)
         at java.lang.Class.forName(Class.java(Compiled Code))
         at packBean.BeanClass.display(BeanClass.java:29)
         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java(Compiled Code))
         at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java(Compiled Code))
         at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java(Compiled Code))
         at java.lang.reflect.Method.invoke(Method.java(Compiled Code))
         at com.ibm.ws.webservices.engine.dispatchers.java.JavaDispatcher.invokeMethod(JavaDispatcher.java:178)
         at com.ibm.ws.webservices.engine.dispatchers.java.JavaDispatcher.invokeOperation(JavaDispatcher.java:141)
         at com.ibm.ws.webservices.engine.dispatchers.SoapRPCProcessor.processRequestResponse(SoapRPCProcessor.java:423)
         at com.ibm.ws.webservices.engine.dispatchers.SoapRPCProcessor.processMessage(SoapRPCProcessor.java:388)
         at com.ibm.ws.webservices.engine.dispatchers.BasicDispatcher.processMessage(BasicDispatcher.java:134)
         at com.ibm.ws.webservices.engine.dispatchers.java.SessionDispatcher.invoke(SessionDispatcher.java:203)
         at com.ibm.ws.webservices.engine.PivotHandlerWrapper.invoke(PivotHandlerWrapper.java:225)
         at com.ibm.ws.webservices.engine.handlers.jaxrpc.JAXRPCHandler.invoke(JAXRPCHandler.java:151)
         at com.ibm.ws.webservices.engine.handlers.WrappedHandler.invoke(WrappedHandler.java:64)
         at com.ibm.ws.webservices.engine.PivotHandlerWrapper.invoke(PivotHandlerWrapper.java:225)
         at com.ibm.ws.webservices.engine.PivotHandlerWrapper.invoke(PivotHandlerWrapper.java:225)
         at com.ibm.ws.webservices.engine.WebServicesEngine.invoke(WebServicesEngine.java:279)
         at com.ibm.ws.webservices.engine.transport.http.WebServicesServlet.doPost(WebServicesServlet.java:717)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:763)
         at com.ibm.ws.webservices.engine.transport.http.WebServicesServletBase.service(WebServicesServletBase.java:341)
         at javax.servlet.http.HttpServlet.service(HttpServlet.java:856)
         at com.ibm.ws.webcontainer.servlet.ServletWrapper.service(ServletWrapper.java:1282)
         at com.ibm.ws.webcontainer.servlet.ServletWrapper.handleRequest(ServletWrapper.java:673)
         at com.ibm.ws.webcontainer.servlet.CacheServletWrapper.handleRequest(CacheServletWrapper.java:80)
         at com.ibm.ws.webcontainer.WebContainer.handleRequest(WebContainer.java:1802)
         at com.ibm.ws.webcontainer.channel.WCChannelLink.ready(WCChannelLink.java:84)
         at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleDiscrimination(HttpInboundLink.java:469)
         at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.handleNewInformation(HttpInboundLink.java:408)
         at com.ibm.ws.http.channel.inbound.impl.HttpInboundLink.ready(HttpInboundLink.java:286)
         at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.sendToDiscriminaters(NewConnectionInitialReadCallback.java:201)
         at com.ibm.ws.tcp.channel.impl.NewConnectionInitialReadCallback.complete(NewConnectionInitialReadCallback.java:103)
         at com.ibm.ws.tcp.channel.impl.WorkQueueManager.requestComplete(WorkQueueManager.java(Compiled Code))
         at com.ibm.ws.tcp.channel.impl.WorkQueueManager.attemptIO(WorkQueueManager.java(Compiled Code))
         at com.ibm.ws.tcp.channel.impl.WorkQueueManager.workerRun(WorkQueueManager.java(Compiled Code))
         at com.ibm.ws.tcp.channel.impl.WorkQueueManager$Worker.run(WorkQueueManager.java(Compiled Code))
         at com.ibm.ws.util.ThreadPool$Worker.run(ThreadPool.java(Compiled Code))

    You have to put myfaces jar on the web-inf/lib

  • Using workflow from jsf pages...

    We have built a simple JSF page on OC4J app server..
    We want to call our workflow program from this page.
    How should I use the CREATE PROCESS() AND START PROCESS() inside the JSF page?
    We are using 10.1.2. application server. And We SSO connection between
    OC4J 10 1. 3.2
    we deploy our java application to this OC4J..
    But we when we call workflow functions we get get_remote_user error.
    Can we call direct PL/SQL API over JDBC connection without using OWF Java API.
    Or we need (must) use Java aPI to supply this.
    Thanks...

    We see that we can call CREATE PROCESS() OR START PROCESS() inside the JSF page..
    But the problem are about notifications which needs authentication now
    How can we use notifications from java...
    Can we call direct PL/SQL API over JDBC connection without using OWF Java API.
    Or we need (must) use Java aPI to supply this.
    Thanks...

  • Using Business Components in JSF pages

    I have several questions about using BCs in JavaServer Faces pages. I'm new to the JSF-BC development world.
    Here's what I'm trying to accomplish: a salesperson gets a call from a customer requesting a quote. The salesperson selects the URL for my RFQ form and begins filling it out. If there is an existing customer record in the company's database, the salesperson wants to be able to load customer info into the form from the database, rather than typing it all in. Reasonable enough, and probably simply enough.
    But it's kickin' my butt. I've created the domain objects (including one for the customer database, call it "CU") and the model objects (a View Object that filters out all fields but those needed on the form, an Application Module with a View Object Instance). Initially I am routing from the main form window to a dialog window where I am hosting the customer selection components, intending to return to the main window with the selection. On the dialog window I've dropped the VO and configured it to be an ADF Navigation List (which gets implemented as an af:selectOneChoice component). So far so good. The navigation to and from is working fine. The selectOneChoice list is being populated with the first range of returned records. Here's where I'm stuck.
    First of all I can't figure out how to kick the iterator into sending additional records after it's first range. You can scroll down to the end of the list in the selectOneChoice component but nothing happens after that. I know I can set the iterator's range to 0 to get all of the records dumped in at once, but that takes way too long. Any ideas?
    Secondly, when a selection is made, how do I access the selected data? I have set up a ValueChangeListener method in my dialog's backing bean that gets the NewValue() from the event object, but that value turns out to be the index into the collection of selectItems. How do I get the value of the data that shows in the list? Is that the label of the selectItem? If so, how do I access it? What I really want is to get the entire row of data represented by the returned index, but I'm lost as to how to do that. Any help would be much appreciated.
    At some point I want to let the salesperson type in a partial customer name and then retrieve only records matching the query's where clause. I see where I can create a bind variable on the view object, but am not sure how to pass the partial name value from the main form to the dialog. Currently I use an EL expression in the Action attribute of an af:selectInputText component to navigate to the dialog and I don't think I can pass parameters with that. I guess I would have to switch to using a method binding to a backing bean, eh? But even if I can get the partial name value to the dialog, how do I bind that value to the bind variable of the VO? (the VO that is already bound to the af:selectOneChoice component in the dialog.)
    And I am totally open to alternative suggestions for how to accomplish the original intention of all of this. Thanks for any guidance.
    Johnny Lee

    Thanks, Shay. That has gotten me a few steps further along. I modified my VO by creating a bind variable and modified the SQL to use this variable in it's where clause. I generated Java for my AppMod (which I hadn't done before, preferring to keep things simple) and created a method to supply a value to my VO's new bind variable. I need a little more hand-holding, though, to wire an input text field & button (or af:selectInputText?) to both the AppMod's new method AND the data component that will display the query results.
    "...drag the exposed method as a button onto a JSF page." That's easy enough, but I haven't yet figured out from the examples how to associate the value of an input component with the parameter of the AppMod's new method. It's getting late, I'm starting to see cross-eyed so I will sleep on this and take another look in the morning. Thanks for your help.
    Johnny Lee

  • JSF page & Sqlserver DB - gave 'Use the sqljdbc4' class error !

    Hello,
    I created an JSF page with business components and data controls generated from a connected sqlserver database.
    The driver class used is 'sqljdbc4.jar' and works for all generaled VIEW LINKS by the AppModule.
    However, on running the created JSF page, I get the following error - although the 'sqljdbc4.jar class (NOT sqljdbc.jar) is used for the DB connection, and the only reference in the application.
    The error message is:
    Could not create pool connection. The DBMS driver exception was: Java Runtime Environment (JRE) version 1.6 is not supported by this driver. Use the sqljdbc4.jar class library, which provides support for JDBC 4.0.
    QUESTION: Does that mean that I need to locate another sqlserver driver that supports JRE version 1.6 - although I understood from the documentation that 'sqljdbc4.jar' should work with JRE version 1.6?
    see full message log below - when trying to deploy the JSF page:
    *** Using port 7101 ***
    C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\bin\startWebLogic.cmd
    [waiting for the server to complete its initialization...]
    JAVA Memory arguments: -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=128m -XX:MaxPermSize=512m
    WLS Start Mode=Development
    CLASSPATH=C:\Oracle\MIDDLE~1\patch_wls1032\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\Oracle\MIDDLE~1\patch_jdev1111\profiles\default\sys_manifest_classpath\weblogic_patch.jar;C:\Oracle\MIDDLE~1\JDK160~1.5-3\lib\tools.jar;C:\Oracle\MIDDLE~1\utils\config\10.3\config-launch.jar;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\weblogic_sp.jar;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\weblogic.jar;C:\Oracle\MIDDLE~1\modules\features\weblogic.server.modules_10.3.2.0.jar;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\webservices.jar;C:\Oracle\MIDDLE~1\modules\ORGAPA~1.0/lib/ant-all.jar;C:\Oracle\MIDDLE~1\modules\NETSFA~1.0_1/lib/ant-contrib.jar;C:\Oracle\Middleware\jdeveloper\webcenter\modules\oracle.portlet.server_11.1.1\oracle-portlet-api.jar;C:\Oracle\MIDDLE~1\ORACLE~1\modules\oracle.jrf_11.1.1\jrf.jar;C:\Oracle\MIDDLE~1\WLSERV~1.3\common\eval\pointbase\lib\pbclient57.jar;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\xqrl.jar;.;C:\Program Files\TIBCO;C:\Program Files\Java\jre6\lib\ext\QTJava.zip;C:\KEEP\A_SOA_ActiveVOS\SQLserverjdbc_Driver\sqljdbc_2.0\enu\sqljdbc.jar
    PATH=C:\Oracle\MIDDLE~1\patch_wls1032\profiles\default\native;C:\Oracle\MIDDLE~1\patch_jdev1111\profiles\default\native;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\native\win\32;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\bin;C:\Oracle\MIDDLE~1\modules\ORGAPA~1.0\bin;C:\Oracle\MIDDLE~1\JDK160~1.5-3\jre\bin;C:\Oracle\MIDDLE~1\JDK160~1.5-3\bin;C:\app\Administrator\product\11.1.0\db_4\bin;C:\app\Administrator\product\11.1.0\db_3\bin;C:\app\Administrator\product\11.1.0\db_1\bin;C:\Program Files\PHP\;C:\oraclexe\app\oracle\product\10.2.0\server\bin;C:\Windows\system32;C:\Windows;C:\Windows\System32\Wbem;C:\Windows\System32\Windows System Resource Manager\bin;C:\Windows\System32\WindowsPowerShell\v1.0\;C:\Program Files\Common Files\Roxio Shared\DLLShared\;C:\Program Files\Common Files\Roxio Shared\9.0\DLLShared\;C:\ANT\bin;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\;C:\Program Files\Microsoft SQL Server\100\DTS\Binn\;C:\Program Files\Microsoft SQL Server\100\Tools\Binn\VSShell\Common7\IDE\;C:\Program Files\Common Files\DivX Shared\;C:\Program Files\QuickTime\QTSystem\;C:\Program Files\Microsoft SQL Server\80\Tools\Binn\;C:\Program Files\Microsoft SQL Server\90\DTS\Binn\;C:\Program Files\Microsoft SQL Server\90\Tools\binn\;C:\Program Files\Microsoft SQL Server\90\Tools\Binn\VSShell\Common7\IDE;;C:\Oracle\MIDDLE~1\WLSERV~1.3\server\native\win\32\oci920_8
    * To start WebLogic Server, use a username and *
    * password assigned to an admin-level user. For *
    * server administration, use the WebLogic Server *
    * console at http:\\hostname:port\console *
    starting weblogic with Java version:
    java version "1.6.0_14"
    Java(TM) SE Runtime Environment (build 1.6.0_14-b08)
    Java HotSpot(TM) Client VM (build 14.0-b16, mixed mode)
    Starting WLS with line:
    C:\Oracle\MIDDLE~1\JDK160~1.5-3\bin\java -client -Xms256m -Xmx512m -XX:CompileThreshold=8000 -XX:PermSize=128m -XX:MaxPermSize=512m -Dweblogic.Name=DefaultServer -Djava.security.policy=C:\Oracle\MIDDLE~1\WLSERV~1.3\server\lib\weblogic.policy -Djavax.net.ssl.trustStore=C:\Oracle\Middleware\wlserver_10.3\server\lib\DemoTrust.jks -Dhttp.proxyHost=emeacache.uk.oracle.com -Dhttp.proxyPort=80 -Dhttp.nonProxyHosts=null -Dhttps.proxyHost=emeacache.uk.oracle.com -Dhttps.proxyPort=80 -Dhttps.nonProxyHosts=null -Dweblogic.nodemanager.ServiceEnabled=true -Xverify:none -da -Dplatform.home=C:\Oracle\MIDDLE~1\WLSERV~1.3 -Dwls.home=C:\Oracle\MIDDLE~1\WLSERV~1.3\server -Dweblogic.home=C:\Oracle\MIDDLE~1\WLSERV~1.3\server -Djps.app.credential.overwrite.allowed=true -Ddomain.home=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1 -Dcommon.components.home=C:\Oracle\MIDDLE~1\ORACLE~1 -Djrf.version=11.1.1 -Dorg.apache.commons.logging.Log=org.apache.commons.logging.impl.Jdk14Logger -Djrockit.optfile=C:\Oracle\MIDDLE~1\ORACLE~1\modules\oracle.jrf_11.1.1\jrocket_optfile.txt -Doracle.domain.config.dir=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1 -Doracle.server.config.dir=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1\servers\DefaultServer -Doracle.security.jps.config=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\fmwconfig\jps-config.xml -Djava.protocol.handler.pkgs=oracle.mds.net.protocol -Digf.arisidbeans.carmlloc=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1\carml -Digf.arisidstack.home=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\config\FMWCON~1\arisidprovider -Dweblogic.alternateTypesDirectory=\modules\oracle.ossoiap_11.1.1,\modules\oracle.oamprovider_11.1.1 -Dweblogic.jdbc.remoteEnabled=false -Dwsm.repository.path=C:\Users\ADMINI~1\AppData\Roaming\JDEVEL~1\SYSTEM~1.36\DEFAUL~1\oracle\store\gmds -DUSE_JAAS=false -Djps.policystore.hybrid.mode=false -Djps.combiner.optimize.lazyeval=true -Djps.combiner.optimize=true -Djps.auth=ACC -Doracle.core.ojdl.logging.usercontextprovider=oracle.core.ojdl.logging.impl.UserContextImpl -Doracle.wc.openusage.clustername=localhost -Doracle.wc.openusage.collectorport=31314 -Doracle.wc.openusage.timeout=30 -Doracle.wc.openusage.unicast=true -Doracle.wc.openusage.enabled=false -Doracle.webcenter.tagging.scopeTags=false -XX:+UseParallelGC -XX:+DisableExplicitGC -Dwc.oracle.home=C:\Oracle\Middleware\jdeveloper -Dweblogic.management.discover=true -Dwlw.iterativeDev= -Dwlw.testConsole= -Dwlw.logErrorsToConsole= -Dweblogic.ext.dirs=C:\Oracle\MIDDLE~1\patch_wls1032\profiles\default\sysext_manifest_classpath;C:\Oracle\MIDDLE~1\patch_jdev1111\profiles\default\sysext_manifest_classpath weblogic.Server
    <Apr 19, 2010 6:36:22 PM EDT> <Notice> <WebLogicServer> <BEA-000395> <Following extensions directory contents added to the end of the classpath:
    C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\lib\mbeantypes\csp-id-asserter.jar>
    <Apr 19, 2010 6:36:23 PM EDT> <Info> <WebLogicServer> <BEA-000377> <Starting WebLogic Server with Java HotSpot(TM) Client VM Version 14.0-b16 from Sun Microsystems Inc.>
    <Apr 19, 2010 6:36:24 PM EDT> <Info> <Management> <BEA-141107> <Version: WebLogic Server 10.3.2.0 Tue Oct 20 12:16:15 PDT 2009 1267925 >
    <Apr 19, 2010 6:36:27 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
    <Apr 19, 2010 6:36:27 PM EDT> <Info> <WorkManager> <BEA-002900> <Initializing self-tuning thread pool>
    <Apr 19, 2010 6:36:29 PM EDT> <Notice> <LoggingService> <BEA-320400> <The log file C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultServer.log will be rotated. Reopen the log file if tailing has stopped. This can happen on some platforms like Windows.>
    <Apr 19, 2010 6:36:29 PM EDT> <Notice> <LoggingService> <BEA-320401> <The log file has been rotated to C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultServer.log00003. Log messages will continue to be logged in C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultServer.log.>
    <Apr 19, 2010 6:36:29 PM EDT> <Notice> <Log Management> <BEA-170019> <The server log file C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultServer.log is opened. All server side log events will be written to this file.>
    <Apr 19, 2010 6:36:49 PM EDT> <Notice> <Security> <BEA-090082> <Security initializing using security realm myrealm.>
    <Apr 19, 2010 6:37:27 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STANDBY>
    <Apr 19, 2010 6:37:28 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to STARTING>
    <Apr 19, 2010 6:38:44 PM EDT> <Notice> <LoggingService> <BEA-320400> <The log file C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultDomain.log will be rotated. Reopen the log file if tailing has stopped. This can happen on some platforms like Windows.>
    <Apr 19, 2010 6:38:44 PM EDT> <Notice> <LoggingService> <BEA-320401> <The log file has been rotated to C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultDomain.log00003. Log messages will continue to be logged in C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\DefaultDomain\servers\DefaultServer\logs\DefaultDomain.log.>
    <Apr 19, 2010 6:38:44 PM EDT> <Notice> <Log Management> <BEA-170027> <The Server has established connection with the Domain level Diagnostic Service successfully.>
    <Apr 19, 2010 6:38:48 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to ADMIN>
    <Apr 19, 2010 6:38:48 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RESUMING>
    <Apr 19, 2010 6:38:48 PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default" is now listening on 10.254.255.241:7101 for protocols iiop, t3, ldap, snmp, http.>
    <Apr 19, 2010 6:38:48 PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[2]" is now listening on 127.0.0.1:7101 for protocols iiop, t3, ldap, snmp, http.>
    <Apr 19, 2010 6:38:48 PM EDT> <Notice> <Server> <BEA-002613> <Channel "Default[1]" is now listening on 0:0:0:0:0:0:0:1:7101 for protocols iiop, t3, ldap, snmp, http.>
    <Apr 19, 2010 6:38:48 PM EDT> <Notice> <WebLogicServer> <BEA-000331> <Started WebLogic Admin Server "DefaultServer" for domain "DefaultDomain" running in Development Mode>
    <Apr 19, 2010 6:38:48 PM EDT> <Warning> <Server> <BEA-002611> <Hostname "WINSERVR2008", maps to multiple IP addresses: 10.254.255.241, 0:0:0:0:0:0:0:1>
    <Apr 19, 2010 6:38:49 PM EDT> <Notice> <WebLogicServer> <BEA-000365> <Server state changed to RUNNING>
    <Apr 19, 2010 6:38:49 PM EDT> <Notice> <WebLogicServer> <BEA-000360> <Server started in RUNNING mode>
    IntegratedWebLogicServer startup time: 192201 ms.
    IntegratedWebLogicServer started.
    [Running application BraaineDBupdateV1 on Server Instance IntegratedWebLogicServer...]
    [06:39:24 PM] ---- Deployment started. ----
    [06:39:24 PM] Target platform is (Weblogic 10.3).
    [06:39:30 PM] Retrieving existing application information
    [06:39:33 PM] Running dependency analysis...
    [06:39:33 PM] Deploying 2 profiles...
    [06:39:37 PM] Wrote Web Application Module to C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\o.j2ee\drs\BraaineDBupdateV1\ViewControllerWebApp.war
    [06:39:39 PM] Wrote Enterprise Application Module to C:\Users\Administrator\AppData\Roaming\JDeveloper\system11.1.1.2.36.55.36\o.j2ee\drs\BraaineDBupdateV1
    [06:39:39 PM] Deploying Application...
    <Apr 19, 2010 6:39:43 PM EDT> <Warning> <J2EE> <BEA-160195> <The application version lifecycle event listener oracle.security.jps.wls.listeners.JpsAppVersionLifecycleListener is ignored because the application BraaineDBupdateV1 is not versioned.>
    <SQLServerConnection><<init>> Java Runtime Environment (JRE) version 1.6 is not supported by this driver. Use the sqljdbc4.jar class library, which provides support for JDBC 4.0.
    <Apr 19, 2010 6:39:45 PM EDT> <Warning> <JDBC> <BEA-001129> <Received exception while creating connection for pool "BraineDB": Java Runtime Environment (JRE) version 1.6 is not supported by this driver. Use the sqljdbc4.jar class library, which provides support for JDBC 4.0.>
    <Apr 19, 2010 6:39:47 PM EDT> <Error> <Deployer> <BEA-149265> <Failure occurred in the execution of deployment request with ID '1271716780677' for task '0'. Error is: 'weblogic.application.ModuleException: '
    weblogic.application.ModuleException:
         at weblogic.jdbc.module.JDBCModule.prepare(JDBCModule.java:290)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:391)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:59)
         Truncated. see log file for complete stacktrace
    Caused By: weblogic.common.ResourceException: weblogic.common.ResourceException: Could not create pool connection. The DBMS driver exception was: Java Runtime Environment (JRE) version 1.6 is not supported by this driver. Use the sqljdbc4.jar class library, which provides support for JDBC 4.0.
         at weblogic.jdbc.common.internal.ConnectionEnvFactory.createResource(ConnectionEnvFactory.java:256)
         at weblogic.common.resourcepool.ResourcePoolImpl.makeResources(ResourcePoolImpl.java:1180)
         at weblogic.common.resourcepool.ResourcePoolImpl.makeResources(ResourcePoolImpl.java:1104)
         at weblogic.common.resourcepool.ResourcePoolImpl.start(ResourcePoolImpl.java:244)
         at weblogic.jdbc.common.internal.ConnectionPool.doStart(ConnectionPool.java:1065)
         Truncated. see log file for complete stacktrace
    >
    <Apr 19, 2010 6:39:47 PM EDT> <Warning> <Deployer> <BEA-149004> <Failures were detected while initiating deploy task for application 'BraaineDBupdateV1'.>
    <Apr 19, 2010 6:39:47 PM EDT> <Warning> <Deployer> <BEA-149078> <Stack trace for message 149004
    weblogic.application.ModuleException:
         at weblogic.jdbc.module.JDBCModule.prepare(JDBCModule.java:290)
         at weblogic.application.internal.flow.ModuleListenerInvoker.prepare(ModuleListenerInvoker.java:199)
         at weblogic.application.internal.flow.DeploymentCallbackFlow$1.next(DeploymentCallbackFlow.java:391)
         at weblogic.application.utils.StateMachineDriver.nextState(StateMachineDriver.java:83)
         at weblogic.application.internal.flow.DeploymentCallbackFlow.prepare(DeploymentCallbackFlow.java:59)
         Truncated. see log file for complete stacktrace
    Caused By: weblogic.common.ResourceException: weblogic.common.ResourceException: Could not create pool connection. The DBMS driver exception was: Java Runtime Environment (JRE) version 1.6 is not supported by this driver. Use the sqljdbc4.jar class library, which provides support for JDBC 4.0.
         at weblogic.jdbc.common.internal.ConnectionEnvFactory.createResource(ConnectionEnvFactory.java:256)
         at weblogic.common.resourcepool.ResourcePoolImpl.makeResources(ResourcePoolImpl.java:1180)
         at weblogic.common.resourcepool.ResourcePoolImpl.makeResources(ResourcePoolImpl.java:1104)
         at weblogic.common.resourcepool.ResourcePoolImpl.start(ResourcePoolImpl.java:244)
         at weblogic.jdbc.common.internal.ConnectionPool.doStart(ConnectionPool.java:1065)
         Truncated. see log file for complete stacktrace
    >
    [06:39:47 PM] #### Deployment incomplete. ####
    [06:39:47 PM] Remote deployment failed (oracle.jdevimpl.deploy.common.Jsr88RemoteDeployer)
    #### Cannot run application BraaineDBupdateV1 due to error deploying to IntegratedWebLogicServer.
    [Application BraaineDBupdateV1 stopped and undeployed from Server Instance IntegratedWebLogicServer]

    No, you already have the needed driver in sqljdbc4.jar. The problem is that your classpath first points to sqljdbc.jar
    >
    ...;C:\KEEP\A_SOA_ActiveVOS\SQLserverjdbc_Driver\sqljdbc_2.0\enu\sqljdbc.jar
    >
    so this dirver is loaded instead of the sqljdbc4.jar.
    Remove the old jar from the class path and try again.
    Timo

  • How to Use another JSF page that I load by XMLHttpRequest?

    Hi everyone, I'm a newbie of JSF and curisous about how to load page content seperately by AJAX.
    I saw example of Java Blue Print. It's load some data to use in page. What I want is to load another JSF page when click a link or button, (Like include another page). And work with functions privoided by loaded JSF Page.
    My example is, In a main page. I request a JSF page and set it into a div layer.
    var requestURL = "/admin/customer/customer-list-body.faces";
    var content = postDataWithoutContent(requestURL);     divContent.innerHTML = content;     
    All JSF components are required under <f:view>, thus action of form is set as "action='"/admin/customer/customer-list-body.faces'"
    But my page is main.jsp. Each time I click command button in customer-list-body.faces, the url will change to customer-list-body.faces, I want to request and hold in main.jsp.
    What can I do then? Any advices?

    Hi,
    the list doesn't seem to be your problem. You need to track down the illegal argument exception. Once you have that sorted out, expose the method on the AM so it gets shown as a method binding. The return values then could be picked up in a managed bean to create the select Item list
    Frank

  • How to use j query in .jsf page which is designed using adfpagetemplate.

    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
    <af:document title="untitled7.jsf" id="d1">
    <af:form id="f1">
    <af:pageTemplate viewId="/oracle/templates/threeColumnTemplate.jspx" id="pt1">
    <f:facet name="center">
    <af:resource type="javascript"
    source="/lib/jquery/jquery-1.3.2.min.js"/>
    <af:resource type="javascript">
    function slideSwitch() {
    var $active = $('#slideshow IMG.active');
    if ( $active.length == 0 ) $active = $('#slideshow IMG:last');
    // use this to pull the images in the order they appear in the markup
    var $next = $active.next().length ? $active.next() : $('#slideshow img:first');
    $active.addClass('last-active');
    $next.css({opacity: 0.0})
    .addClass('active')
    .animate({opacity: 1.0}, 1000, function() {
    $active.removeClass('active last-active');
    $(function() {
    setInterval( "slideSwitch()", 15000 );
    </af:resource>
    <af:resource type="css">
    #slideshow IMG {
    position:absolute;
    top:0;
    left:0;
    z-index:8;
    opacity:0.0;
    #slideshow IMG.active {
    z-index:10;
    opacity:1.0;
    #slideshow IMG.last-active {
    z-index:9;
    </af:resource>
    <af:panelGroupLayout id="slideshow" layout="vertical">
    <!-- The use of groups avoids that each image gets surrounded by a div -->
    <af:group>
    <af:image source="/images/cristo1.jpg" id="i1" />
    <af:image source="/images/cristo2.jpg" id="i2"/>
    <af:image source="/images/ipanema1.jpg" id="i3"/>
    </af:group>
    </af:panelGroupLayout>
    </f:facet>
    <f:facet name="header"/>
    <f:facet name="end"/>
    <f:facet name="start"/>
    <f:facet name="branding"/>
    <f:facet name="copyright"/>
    <f:facet name="status"/>
    </af:pageTemplate>
    </af:form>
    </af:document>
    </f:view>
    Above content is my code written in jsf page....
    jquery working fine if i create page withoput pagetemplate...
    Any please guide me to use jquery in the jsf page(created with page template)...
    Thanks in advance
    Edited by: 991543 on May 7, 2013 11:05 PM

    Hi frank,
    thanks for your reply frank........still am facing the same issue even i tried wat you told.
    I have pasted the code below for your reference.....
    please let me knw wat is the wrong thing in below code if any thing wrong plz guide me to resolve because this is needed in our project, thanks in advance.
    <?xml version='1.0' encoding='UTF-8'?>
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
    <f:view xmlns:f="http://java.sun.com/jsf/core" xmlns:af="http://xmlns.oracle.com/adf/faces/rich">
    <af:document title="untitled7.jsf" id="d1">
    <af:form id="f1">
    <af:pageTemplate viewId="/oracle/templates/threeColumnTemplate.jspx" id="pt1">
    <f:facet name="center">
    <af:resource type="javascript"
    source="/lib/jquery/jquery-1.3.2.min.js"/>
    <af:resource type="javascript">
    function slideSwitch() {
    var $active = $('#pt1:slideshow IMG.active');
    if ( $active.length == 0 ) $active = $('#pt1:slideshow IMG:last');
    // use this to pull the images in the order they appear in the markup
    var $next = $active.next().length ? $active.next() : $('#pt1:slideshow img:first');
    $active.addClass('last-active');
    $next.css({opacity: 0.0})
    .addClass('active')
    .animate({opacity: 1.0}, 1000, function() {
    $active.removeClass('active last-active');
    $(function() {
    setInterval( "slideSwitch()", 1000 );
    </af:resource>
    <af:resource type="css">
    #pt1:slideshow IMG {
    position:absolute;
    top:0;
    left:0;
    z-index:8;
    opacity:0.0;
    #pt1:slideshow IMG.active {
    z-index:10;
    opacity:1.0;
    #pt1:slideshow IMG.last-active {
    z-index:9;
    </af:resource>
    <af:panelGroupLayout id="slideshow" layout="vertical">
    <!-- The use of groups avoids that each image gets surrounded by a div -->
    <af:group>
    <af:image source="/images/cristo1.jpg" id="i1" />
    <af:image source="/images/cristo2.jpg" id="i2"/>
    <af:image source="/images/ipanema1.jpg" id="i3"/>
    </af:group>
    </af:panelGroupLayout>
    </f:facet>
    <f:facet name="header"/>
    <f:facet name="end"/>
    <f:facet name="start"/>
    <f:facet name="branding"/>
    <f:facet name="copyright"/>
    <f:facet name="status"/>
    </af:pageTemplate>
    </af:form>
    </af:document>
    </f:view>
    Thanks & Regards
    Gowthaman Narayanan
    Edited by: 991543 on May 15, 2013 4:27 AM
    Edited by: 991543 on May 15, 2013 4:30 AM

  • Howto use comments in JSF pages

    Hi all,
    I play a little bit with JSF, at the moment. I wonder that I cannot find any information about how to comment out a part of a JSF page, that it is not rendered.
    If I use the html comment tags <!-- --> then this part is already rendered if I access the page.
    If I want to comment out an invalid part, the execution will fails :(.
    So is there a comment tag in JSF, which is not be rendered if a page is access?
    Thank in advance
    Marco

    I'm sure you must have found a way by now, but to anyone who also has this problem (like myself :D) you can do the following.. I'm using Facelets as XHTML pages, and I didn't find a way of allow the JSP style comments:
    <%--    --%>But if you add the below to your web.xml, you can allow Facelets to skip HTML comments:
    <context-param>
        <param-name>facelets.SKIP_COMMENTS</param-name>
        <param-value>true</param-value>
      </context-param>So with the above in your web.xml, the below:
    First line: #{person.id}
    <!-- Second Line: #{person.id} -->would generate, assuming the person bean's id property is 5:
    First line: 5

  • How to use HTML tags inside JSF pages

    I am creating a Menu using dataTable and outputLink in a JSF page.
    <div class="bodyarea">
    <div id="location">
    <ol>
    <h:dataTable value="#{menuItem.breadCrumb}" var="bread" >
    <h:column>
    <li>
    <h:outputLink id="crumbID" value="#{bread.menuLink}">
    <h:outputText id="crumpName" value="#{bread.menuLabel}" style="width: 165px;"/>
    </h:outputLink>
    <li>
    </h:column>
    </h:dataTable>
    </ol>
    </div>
    </div>
    I want to use <li> HTML tag as shown in code above before and after every <tr> tag formed, but when i run it and see view source, this is how it shows:
    NOTE: you can see it has thrown out of <table> tag itself.
    <div class="bodyarea">
    <div id="location">
    <ol>
    <li>
    </li>
    <table>
    <tbody>
    <tr>
    <td><a id="_id0:0:crumbID" href="/eApps/admin/loginPage.jsp?MenuItem=-1"><span id="_id0:0:crumpName" style="width: 165px;">Home</span></a></td>
    </tr>
    <tr>
    <td><a id="_id0:1:crumbID" href="/eApps/admin/loginPage.jsp?MenuItem=3~-1"><span id="_id0:1:crumpName" style="width: 165px;">HIM Admin</span></a></td>
    </tr>
    </tbody>
    </table>
    </ol>
    </div>
    </div>
    Can some one help me, how do i use HTML tags inside <h:dataTable>.
    Or is their any other way i should form my Menus, to fully utilize to HTML tags.
    Thanks
    Ravi

    Hello,
    You can embed the verbatim elements in your datatable, ie,
    <h:dataTable value="#{menuItem.breadCrumb}" var="bread" >
      <h:column>
        <f:verbatim><li></f:verbatim>
        <h:outputLink id="crumbID" value="#{bread.menuLink}">
          <h:outputText id="crumpName" value="#{bread.menuLabel}" style="width: 165px;"/>
        </h:outputLink>
        <f:verbatim></li></f:verbatim>
      </h:column>
    </h:dataTable>

  • Is it possible to use two diff forms in same jsp/jsf page?

    Hi all,
    My requirement is to submit the form based on selection of radio button.
    since half part needs to be jsp based which is not using any tags etc.
    But i am trying to use some jsf based component which requires to be inside <f:view><h:form> of
    <%@ taglib prefix="f" uri="http://java.sun.com/jsf/core" %>
    <%@ taglib prefix="h" uri="http://java.sun.com/jsf/html" %>
    i.e. some <c:comboBox>
    </h:form> </f:view>
    Now earlier i was submitting the form as
    <form action="/techstacks-v2_1/reportAction.do" method="post" name=doSearch id='doSearch'>
    But now i found, in order to use combo box component which is entirely jsf based i need to use <f:view><h:form> which is kind of taking over the previous form submission mechiansm.
    I am trying to keep them separate as two differnt forms.
    one entirely jsp based and other as jsf based.
    Now my question is can i use such way of doing so or is there any better way of implementing so.
    My friend suggested that i can pass the value of jsf based form in hidden form to a input box of form to be submitted finally instead of submitteing two diff forms.
    but in that case also i ahev to use two forms in a single jsp/jsf page.
    suggest me something which can really work out.
    thanks
    vijendra

    You can use as many forms as you want as long as you don't nest forms. The HTML spec probibits that.

Maybe you are looking for

  • HT1473 Please help!How to put two iTunes accounts on the same computer?

    I have an Ipod and my mum has an IPhone. The songs from my IPod are backed up on my computer and we would like to have different music, but both backed up on the same computer. How do i do this without erasing all the music etc that is already on my

  • Best way to transfer files from old Macbook Pro to new one?

    I just got a new Macbook Pro from Apple...YEEEEAAAHHHH!  So.... What's the best way to transfer files from old Macbook Pro to new one?  I know Migration assistant, but is there a recommended way?  I don't want to put do a system restore or transfer e

  • Problem in implementing code using snmp4j.jar

    Hi, I am using snmp4j.jar to create a class that will execute SNMP commands such as GET, GETNEXT and GETTABLE. The issue I am facing is extremely peculiar. When running the program for the first time, the output is seen correctly. However, in the sub

  • HFM security filter ?

    In HFM, I don't seem to have a way to achieve this: One user has write access to Entity A + all products The same user needs Read Only access to Entity B but a couple of the products only Because the security classes attached to Entity and Product(Cu

  • Bug: Multi-selecting fonts in Ps CS6

    When I select multiple fonts and try to change the font size from let's say 14pt to 24pt, it doesn't change them all to the same point size.  It says it did, but when you select the text individually and check the point size, they'll be arbitrary num