ItemsDB.jcx Sample

This topic inludes the source code for the ItemsDB.jcx Sample.

Sample Location

This sample is located in the following directory in your WebLogic Workshop installation:

BEA_HOME/weblogic81/samples/workshop/SamplesApp/WebApp/handlingData/xmlBeans/

Sample Source Code


01 package handlingData.xmlBeans;
02 
03 import java.sql.SQLException;
04 import com.bea.control.DatabaseControl;
05 import com.bea.control.ControlExtension;
06 import org.openuri.bea.samples.workshop.xmlBeans.items.ItemsRowSetDocument;
07 
08 /**
09  * @jc:connection data-source-jndi-name="cgDataSource"
10  */
11 public interface ItemsDB extends ControlExtension, DatabaseControl
12 {
13     /** Disable default Java serialization */
14     public final static long serialVersionUID = 1L;
15 
16     /**
17      * @jc:sql 
18      *   statement::
19      *   SELECT ITEMNUMBER,ITEMNAME,QUANTITYAVAILABLE,PRICE FROM WEBLOGIC.ITEMS
20      *   ::
21      */
22     public ItemsRowSetDocument getAllItems()
23         throws SQLException;
24 }