Talk About Network

Google


Register and Login
Nick
Password
Register create new account Sign up is FREE and you can post replies, new topics, bookmark posts and more!
Recover lost password


Software > Commerce Server Dataware Housing > Inserting value...
Latest [ Topics | Posts ] Archive Post A New Topic Post a Reply
<< Topic < Post Post 1 of 1 Topic 142 of 184
Post > Topic >>

Inserting values into custom class error

by Alexander Yushchenko <sasha-yoush@[EMAIL PROTECTED] > Aug 16, 2005 at 07:35 PM

I use MSCS2002 + SP3 + FP1

     I have extended dw with a custom class Region_ZipCode (consisting 
of 2 fields) with the use of 'CreateSchemaObject.vbs' script from SDK:

CreateClassDef cn, "Region_ZipCode", "test_Source", "", True, 0, ""
CreateMemberDef cn, "Region_ZipCode", "Zip", "WSTR8",
   fGenerateColDef + fIsRequired + fPrimaryKey + fHasDefaultVal, "0", ""
CreateMemberDef cn, "Region_ZipCode", "Region_ID", "NUMBER",
   fGenerateColDef + fIsRequired, "", ""

     After that I try to execute the following code (written in c#):

ADODB.Connection adoConnection = new ADODB.ConnectionClass();
adoConnection.Open("Provider=commerce.dso.1;Data 
Source=mscop://InProcConnect/Server=my_server: 
Catalog=DWSchema:Database=my_database:FastLoad=True:Connection_Retry=10:Connection_Retry_Delay=30",

"my_user", "my_password", 0);
object nullObject = Type.Missing;
adoConnection.Execute("DELETE FROM Metro_ZipCode", out nullObject, 0);
adoConnection.Execute("INSERT INTO Region_ZipCode (Region_ID, Zip) 
VALUES (1, '99999')", out nullObject, 0);
adoConnection.Close();


     The first "Execute" command is successful.
     The second one throws the following exception: "Exception from 
HRESULT: 0xCA2D8038." And no more information.

     Please, advice.

-- 
Yours faithfully,
Alexander Yushchenko
 




 1 Posts in Topic:
Inserting values into custom class error
Alexander Yushchenko <  2005-08-16 19:35:26 

Post A Reply:
  Go here to Signup

AddThis Feed Button


About - Advertising - Contact - Frequently Asked Questions - Privacy Policy - Terms of Use - Signup

Contact
tan12V112 Sat Nov 22 16:34:27 CST 2008.