Solved

Recordset is not Updatable

Posted on 1997-11-24
3
295 Views
Last Modified: 2013-11-26
Set mydb = Opendatabase("",false,false,"ODBC;DSN=MSSQLSRV;")
Set Data1.Recordset = mydb.OpenRecordset("test_table",dbOpenDynaset)
Now if I check Data1.Recordset.Updatable , it is false. Why ? mydb.Updatable is True. How can I create an updatable recordset on Data1 without setting the Data Control's Connect and Datasource property. I dont want the Data Control to open a connection of its own to the MS SQL Server 6.5 I have also tried Dim rs as Recordset but even rs turns out to be Updatable False.
0
Comment
Question by:sudhin031597
  • 2
3 Comments
 

Author Comment

by:sudhin031597
ID: 1442221
Edited text of question
0
 
LVL 9

Accepted Solution

by:
cymbolic earned 50 total points
ID: 1442222
If accessing SQL server, you should be using RDO from the Enterprise Edition.  Also, Table methods are not well received in an SQL server environment, because everybody else gets locked out, and that's a bad thing.  Finally, you need to step up to unbound controls, and manage the population and updating of resultsets in your own code.  And, you need to get to creating read only resultsets of limited scope (# rows), with update/insert using the execute method, rather than .edit/.update methods, because these as well make the SQL Server lock pages for a computer eternity, and that is also a bad thing!

I recommend you read "Hitchiker's Guide to Visual Basic & SQL (Server) from Microsoft Press, before you go much farther, or at least have it open as a reference.
0
 

Author Comment

by:sudhin031597
ID: 1442223
I teach RDO to my students ! I can open an updatable resultset
and any DAO recordset turns out to be read-only. I thought this
could be a well-known bug and somebody could tell me the latest
bug-free version.
0

Featured Post

Is Your Active Directory as Secure as You Think?

More than 75% of all records are compromised because of the loss or theft of a privileged credential. Experts have been exploring Active Directory infrastructure to identify key threats and establish best practices for keeping data safe. Attend this month’s webinar to learn more.

Question has a verified solution.

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

Suggested Solutions

Title # Comments Views Activity
ms access #TYPE! error on report when no data 4 64
Macro which automatically send Excel spreadsheet to Outlook problem 2 61
MsgBox 2 47
Passing a Text Box name to a Sub 6 74
Introduction I needed to skip over some file processing within a For...Next loop in some old production code and wished that VB (classic) had a statement that would drop down to the end of the current iteration, bypassing the statements that were c…
When trying to find the cause of a problem in VBA or VB6 it's often valuable to know what procedures were executed prior to the error. You can use the Call Stack for that but it is often inadequate because it may show procedures you aren't intereste…
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…
Get people started with the process of using Access VBA to control Excel using automation, Microsoft Access can control other applications. An example is the ability to programmatically talk to Excel. Using automation, an Access application can laun…

910 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

21 Experts available now in Live!

Get 1:1 Help Now