Insert performance question about OCL
Posted: Wed 15 Sep 2010 10:15
Hi, i am trying to use your ocl library to build a personalized library. Now, i meet a question, how can i imporve the insert speed.
my code structure is:
oracommand insertcmd;
insertcmd.setSQL(insertsql);
insertcmd.prepare();
for(...)
{
insertcmd["column1"]=1;
insertcmd["column2'].assign(string); //string length=512bytes
insertcmd.execute()
}
insertcmd.unprepare();
with this structure, i can only insert about 100 to 200 rows of data to db (from empty with increamental primary key and indexed column1). Can i improve the speed of insert to 1000/s?
Environment is Linux+Oracle 11g
I am looking forward to your reply.
my code structure is:
oracommand insertcmd;
insertcmd.setSQL(insertsql);
insertcmd.prepare();
for(...)
{
insertcmd["column1"]=1;
insertcmd["column2'].assign(string); //string length=512bytes
insertcmd.execute()
}
insertcmd.unprepare();
with this structure, i can only insert about 100 to 200 rows of data to db (from empty with increamental primary key and indexed column1). Can i improve the speed of insert to 1000/s?
Environment is Linux+Oracle 11g
I am looking forward to your reply.