firehose error (database)

Results 1 to 2 of 2

Thread: firehose error (database)

  1. #1
    Join Date
    Dec 1969

    Default firehose error (database)

    basically what i am trying to do is beginning a trans with multiple inserts in differnet table.. if all are successful then committrans<BR>I have a feeling my logice is not correct<BR>the following is my code and i am gettinga firehose error<BR>if i take out begintrans and committrans then it does what it is suppose to do.. but i am not sure in the real world if that is going work.. basically the concurrency issue.. I hope i am making sense.. following is the code:<BR><BR><BR>set transfer = objConnection.Execute(sqshopping)<BR> objConnection.BeginTrans()<BR> &#039;Insert Billing information<BR> set addbilling = objConnection.Execute(sqbilling)<BR> while not transfer.eof <BR> sqinsert = "insert into orders Values (&#039;" & orderid & "&#039;, &#039;" & transfer("sku") & "&#039;, " &_<BR> transfer("quantity") & ")"<BR> set trans = objConnection.Execute(sqinsert)<BR> transfer.MoveNext<BR> wend<BR> &#039;Insert Shipping information<BR> set shipping = objConnection.Execute(sqshipping)<BR> <BR> &#039;Delete shopping cart products & tempcardholderproducts<BR> set deletecart = objConnection.Execute(deleteshopping)<BR> set deletecard = objConnection.Execute(deletetemp) <BR> objConnection.CommitTrans()<BR><BR>notes:<BR>delet etemp, deleteshopping = is SQL delete statement<BR>sqshipping, sqinsert = is a SQL Insert statement<BR>sqshopping = is a SQL Select statement

  2. #2
    Join Date
    Dec 1969

    Default Only SELECT statements..

    .. return recordsets.<BR><BR>Only try to get a recordset object if you need to. So, instead of:<BR>set trans = objConnection.Execute(sqinsert)<BR><BR>Just do:<BR>objConnection.Execute sqinsert

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts