Forum Stats

  • 3,854,674 Users
  • 2,264,399 Discussions


how to Implement or achieve Odynaset::StartEdit() AddNewRecord() SetFieldValue() etc function which

3153620 Member Posts: 1
edited Jan 13, 2016 11:21AM in Oracle Call Interface (OCI)

Because Project need. I need to implement Odynaset::StartEdit() ,AddNewRecord() ,SetFieldValue()  ,update() etc function which are inOO4O with OCI  underlying functions,and bypass COM mechanism,Do not use COM mechanism.Our software need to hand large amounts of data in  a very short period of time.It needs Very high efficiency. but I  also like OO4O's  simple usage ,is easy to use  for most of us C++ I want to package OCI underlying functions like OO4O‘s Odynaset 's grammar.

I have read<< Oracle® Call Interface Programmer's Guide >>Related Sections. and ORACLE_HOME/OO4O/doc/oraclec.chm but I still do not know how to achieve/implement it.

I have done it with OCILIB  by Splice select SQL Statement to get a resultRecord.and Excute another  update SQL Conditional statements to  accomplish "SatrtEdit" and excute OCIBindString() ect to accomplish setfieldvalue()  and OCI_Excute、 OCI_Commit to accomplish ODynaset::update().and Excute one another Insert SQL statement to accomplish  Odynaset::AddNewRecord().     SetfieldValue method are all use OCI_BindXXX()。But,But I read ORACLE_HOME/OO4O/doc/oraclec.chm documnet.

in oraclec.chm  it indicates and explains that The ODynaset attempts to obtain a lock on the record from the Oracle database so that no other user can edit the record at the same time. and  OCI Programmer's Guide  also have OCIObjectLock() function explanation  ,if it like that,how can i achieve my OCIlikeOO4OWithoutCOM.ect Package???How can I accomplish my StartEdit()  AddNewRedord() .ect method???Internal,Does  StartEdit() method excute select***for update/update *****set****=**** SQL statement??? Does AddNewRecord() method excute Insert into******SQL statement???? Is there some  Demonstration Program???I have  also  installed Oracle_examples.exe 。 in there  ralated  folder ,i also searched key world "OCIObjectLock" in context search.and find nothing. It is how you deal with these problems???

This discussion has been closed.