Hi All ,
I am using Oracle 11g DB.
My use case is -
I need to insert multiple records into a DB table using Java code.
I have a java collection (DTO Class with the fields corresponding to the columns of the DB table I need to insert the values into)
I need to pass this to a package pl/sql procedure and insert the values to the table.
I am very new to this. Looking for a sample code !
My Java DTO class :
public class TestDTO {
public String chain;
public String division;
public String subdivision;
public String department;
public String productclass;
public String category;
public String region;
public String district;
public String store;
}
Insert Script
Insert into TESTSTG(ROWID1,CHAIN,DIVISION,SUBDIVISION,DEPARTMENT,PRODUCTCLASS,CATEGORY,REGION,DISTRICT,STORE,SWAT,BOOSTING,
OHTYPE,PRIORITYORDER,SEASONALBUILD,STORESIZEPREF,USERDEFINEDVALUE,TARGETPERCENTAGE,MAX,MIN,BASEWEIGHING,CMFLTYPE,NMFLTYPE,CMLOCID,NMLOCID,
ATTRLEVELERROR,ROWLEVELERROR,DRIVERTYPE,DRIVERVALUE,REMOVEFLAG,STATUS) values
(?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?,?);
Thanks
Kiran