Inserting data

Results 1 to 2 of 2

Thread: Inserting data

  1. #1
    Join Date
    Dec 1969

    Default Inserting data

    I am trying to insert some data in to a table, and also want to retrieve the inserted data from the same table..<BR>Pl help me in coding...<BR><BR><BR><BR>Thx<BR>

  2. #2
    PrasannakumarNadella Guest

    Default RE: Inserting data

    Hi,<BR>Use the following code toi insert data into a table:<BR> dim Conn,Rs<BR>set Conn=server.createobject("adodb.connection")<BR>Co "dsn=xxx" ---&#062;&#039;your dsn name/connection string goes here<BR>Set Rs=server.createobject("adodb.recordset")<BR>Rs.op en "table",Conn,2,3 --&#062;enter ur table name 2 & 3 are constants to modify table .<BR>Rs.addnew<BR>Rs("fldname1")=request.form("fld 1")<BR>Rs("fldname2")=request.form("fld2")<BR>RS.u pdate<BR><BR>Rs.close <BR>set Rs=nothing<BR>Conn.close &#039;close the connection<BR>set Conn=nothing &#039;deallocate the memory which is occupied by Conn<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