Atomicity Test Two
------------------

We select a customer with good credit.

select c_id from c_customer where c_credit = 'GC' and c_id < 20;

      C_ID
----------
         1
         2
         3
         4
         5
         6
         8
         9
        10
        11
        12

      C_ID
----------
        13
        14
        15
        16
        17
        18
        19

18 rows selected.
For this test, we have chosen a c_id of 12. Using the web interface,
we execute a newOrder transaction of item 00001MITEM00006 in quantity of 2. 
The order completes succesfully and the application server output shows:

org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.setEntityContext(Ljavax.ejb.EntityContext;)V(OrderCmp20EJB.java:472): found SequenceSesHome interface
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.setEntityContext(Ljavax.ejb.EntityContext;)V(OrderCmp20EJB.java:480): found CustomerEntHome interface
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.setEntityContext(Ljavax.ejb.EntityContext;)V(OrderCmp20EJB.java:488): found LargeOrderSesHome interface
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.setEntityContext(Ljavax.ejb .EntityContext;)V(OrderCmp20EJB.java:493): found ItemEntHomeLocal interface
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.setEntityContext(Ljavax.ejb.EntityContext;)V(OrderCmp20EJB.java:498): found OrderLineEntHomeLocal interface
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.ejbCreate(I[Lorg.spec.jappserver.orders.helper.ItemQuantity;)Ljava.lang.Integer;(OrderCmp20EJB.java:107): ejbCreate
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.ejbCreate(I[Lorg.spec.jappserver.orders.helper.ItemQuantity;)Ljava.lang.Integer;(OrderCmp20EJB.java:115): Atomicity Test (1,2,3): Order Id: 74252
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.ejbPostCreate(I[Lorg.spec.jappserver.orders.helper.ItemQuantity;)V(OrderCmp20EJB.java:149): Atomicity Test 3: OrderLineId: 1
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.getPriceWithDiscount(Ljava.lang.String;)D(OrderCmp20EJB.java:520): getPriceWithDiscount
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.getPercentDiscount(D)D(OrderCmp20EJB.java:592): getPercentDiscount
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.findCustomer()V(OrderCmp20EJB.java:540): findCustomer
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.checkCustomerCredit()V(OrderCmp20EJB.java:568): checkCustomerCredit
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.checkForLargeOrders([Lorg.spec.jappserver.orders.helper.ItemQuantity;)V(OrderCmp20EJB.java:622): checkForLargeOrders
org.spec.jappserver.orders.orderent.ejb.OrderEnt_nrczp2__WebLogic_CMP_RDBMS at org.spec.jappserver.orders.orderent.ejb.OrderCmp20EJB.ejbStore()V(OrderCmp20EJB.java:417): ejbStore

Order number is 74252 is verified via the o_orders and o_orderline tables.

select * from o_orders where o_id = 74252;

      O_ID     O_C_ID   O_OL_CNT O_DISCOUNT    O_TOTAL   O_STATUS O_ENTRY_D
---------- ---------- ---------- ---------- ---------- ---------- ---------
O_SHIP_DA
---------
     74252         12          1         .3      26.52          1 11-JAN-05

select * from o_orderline where ol_o_id =74252;

     OL_ID    OL_O_ID OL_I_ID             OL_QTY  OL_STATUS OL_SHIP_D
---------- ---------- --------------- ---------- ---------- ---------
         1      74252 00001MITEM00006          2

