Solved

BEST METHOD ??

Posted on 2000-02-25
8
120 Views
Last Modified: 2010-05-02
hi all..
The question is :~
Whenever i want to retrieve some values from the database i do this..
---------------------------------------
dim sql,recordset,connection
set connection = createobject("Adodb.connection")
set recordset = createobject("Adodb.recordset")
sql = "sqlstatement"
recordset.open sql,con
---------------------------------------
# same is the case with insert and update statements..

NOW I KNOW THAT THERE ARE VARIOUS METHODS FOR DOING THE SAME THING..
I WANT TO KNOW WHAT ARE THEY AND WHICH IS THE BEST METHOD considering the time factor....
PLEASE HELP ASAP
Some code would help me more..
Regards
Nitin

0
Comment
Question by:khacharn
  • 5
  • 3
8 Comments
 
LVL 4

Expert Comment

by:jkunal
ID: 2564109
For selecting the records what you are doing is the best method.

Well for inserting a new record you can use
recordset.addnew
(fields)
recordset.update
But this method is only recomended if you have a recordset already open,
otherwise its a waste of resources.

update also works with

recordset.update...........
0
 

Author Comment

by:khacharn
ID: 2599356
This question has a deletion request Pending
0
 
LVL 4

Expert Comment

by:jkunal
ID: 2599415
This question no longer is pending deletion
0
 
LVL 4

Accepted Solution

by:
jkunal earned 25 total points
ID: 2599416
Why did u do that?
0
Better Security Awareness With Threat Intelligence

See how one of the leading financial services organizations uses Recorded Future as part of a holistic threat intelligence program to promote security awareness and proactively and efficiently identify threats.

 

Author Comment

by:khacharn
ID: 2603388
Hi Kunal..Thanx for the answer
But i am sure that there are more solutions..which are moer faster in processing..
anyway the solutino you have provided is good enough..
Regards
Nitin
0
 
LVL 4

Expert Comment

by:jkunal
ID: 2603521
Nitin if there were any methods better than what were suggested you would have suerly got those as an answer or comments as EE site is full of very good and knowledgeable experts, eager to help you always.

;->
0
 

Author Comment

by:khacharn
ID: 2604967
kunal..are you an indian..I M
mail me at
khacharn@yahoo.com
we can be friends
Regards
Nitin
0
 
LVL 4

Expert Comment

by:jkunal
ID: 2610889
Sure Nitin
my id is jkunal@usa.net
0

Featured Post

How to improve team productivity

Quip adds documents, spreadsheets, and tasklists to your Slack experience
- Elevate ideas to Quip docs
- Share Quip docs in Slack
- Get notified of changes to your docs
- Available on iOS/Android/Desktop/Web
- Online/Offline

Join & Write a Comment

The debugging module of the VB 6 IDE can be accessed by way of the Debug menu item. That menu item can normally be found in the IDE's main menu line as shown in this picture.   There is also a companion Debug Toolbar that looks like the followin…
Since upgrading to Office 2013 or higher installing the Smart Indenter addin will fail. This article will explain how to install it so it will work regardless of the Office version installed.
Get people started with the process of using Access VBA to control Outlook using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Microsoft Outlook. Using automation, an Access applic…
This lesson covers basic error handling code in Microsoft Excel using VBA. This is the first lesson in a 3-part series that uses code to loop through an Excel spreadsheet in VBA and then fix errors, taking advantage of error handling code. This l…

708 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

Need Help in Real-Time?

Connect with top rated Experts

13 Experts available now in Live!

Get 1:1 Help Now