Problem Inserting Data using ASP

Results 1 to 2 of 2

Thread: Problem Inserting Data using ASP

  1. #1
    Dan Winters Guest

    Default Problem Inserting Data using ASP

    When I try to insert data from a form into my SQL database, I keep receiving an error message. The message states, "ADODB.Recordset error &#039;800a0e78&#039;: Operation is not allowed when the object is closed." The line that is causing the problem is "ps.Open insert, conn" where ps is my recordset object, insert is my SQL insert statement, and conn is my connection object. What am I doing wrong? <BR>

  2. #2
    Join Date
    Dec 1969

    Default Show code?

    *possibly* it is actually complaining that the connection is not opened????<BR><BR>Did you try the much simple way of simply doing<BR><BR>conn.Execute( insert )<BR><BR>???<BR><BR>You have ZERO need for a RecordSet when doing an INSERT (or UPDATE or DELETE). Hmmm...actually, maybe that is the problem? Ehhh...I don&#039;t think so. But try ADODB.Connection.Execute. It&#039;s the "right" way to do this, anyway.<BR><BR>

Posting Permissions

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