Solved

When you want to insert, update, or delete a record from a database, which ADO object would you use to accomplish this?

Posted on 2007-03-31
3
2,485 Views
Last Modified: 2008-01-09
When you want to insert, update, or delete a record from a database, which ADO object would you use to accomplish this? (ADOCommand, ADORecordSet, ADODataReader or ADOUpdater)
      
0
Comment
Question by:mabtahi
3 Comments
 
LVL 24

Accepted Solution

by:
DBAduck - Ben Miller earned 125 total points
ID: 18830911
I would use the ADOCommand.  You really do not expect a result so this would allow you to just execute a command.
0
 
LVL 75

Expert Comment

by:Anthony Perkins
ID: 18831065
>>ADOCommand, ADORecordSet, ADODataReader or ADOUpdater<<
You seem to have mixed up ADO with ADO.NET, can you clarify which one you are asking about?
0
 
LVL 1

Expert Comment

by:cmwhite
ID: 18845412
.NET:
 For Select statements (Obviously a return expected) you would use OleDbDataReader, SqlDataReader
 For Update, Insert, Delete statements you would use OleDbCommand, SqlCommand

ADO:
For Select Statements you would use the database connection's execute method and use ADODB.recordset object to hold the returned data.
For update, insert, delete statements you would just use the db connection's execute method.

Hope this helps,

Chris
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

This article shows gives you an overview on SQL Server 2016 row level security. You will also get to know the usages of row-level-security and how it works
When it comes to protecting Oracle Database servers and systems, there are a ton of myths out there. Here are the most common.
Via a live example, show how to shrink a transaction log file down to a reasonable size.
With the power of JIRA, there's an unlimited number of ways you can customize it, use it and benefit from it. With that in mind, there's bound to be things that I wasn't able to cover in this course. With this summary we'll look at some places to go…

860 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question