How to insert a note with ADO in the middle of a table

Source: Internet
Author: User
Tags insert
ado| inserted "In the Lucky (<marquee> Mountain) of the masterpiece" mentioned: "
Here is an example of inserting a record in a table with ADO, please refer to
Set Conn = Server.CreateObject ("ADODB. Connection ")
Conn.Open "Dsn=data; Uid=sa "
Set RS =server.createobject ("ADODB.") Recordset ")
Rs. Open "Your_table", conn,1,3,2//* opens your table
Rs. AddNew//* Add a record
Rs. Fields.item ("Field1") =request.form ("Form_field1")
Rs. Fields.item ("Field2") =request.form ("Form_field2")
Rs. Fields.item ("field3") =request.form ("Form_field3")
...
Rs. Fields.item ("Fieldn") =request.form ("Dform_fieldn")
Rs. Update
Rs. Close
Set rs=nothing
Conn.close
Set conn=nothing
Response.Write ("record added!!!!")



Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.