PRB: Error 3622 Open SQL Server Table with Identity Column
- In the design environment, make sure that the data control is the selected item on your form. Then, go to the properties sheet, and set the Options property to 512.
- In the run-time environment, use the following line of code to set the Options property of a data control named data1:
data1.options = dbSeeChanges
You can modify the VisData sample to avoid the error. There are two placesthat you need to make the changes: where you open a recordset from the Database Window, and where you execute a SQL statement.
- In VISDATA.BAS, under the OpenTable() function, change: -to-
Set rsTmp=gdbCurrentDB.OpenRecordset(rName, dbOpenDynaset)
Set rsTmp=gdbCurrentDB.OpenRecordset(rName,dbOpenDynaset, dbSeeChanges)
- In VISDATA.BAS, under the OpenQuery() function, change: -to-
Set rsTmp = qdfTmp.OpenRecordset(dbOpenDynaset)
Set rsTmp = qdfTmp.OpenRecordset(dbOpenDynaset, dbSeeChanges)
- After Making Changes to VISDATA.BAS, recompile the VISDATA project and copy the compiled executable to the Visual Basic directory (which is \Program Files\Microsoft Visual Studio\Vb98 by default in Visual Basic 6.0)NOTE: There may be other areas of VisData code that would require changes based on which part of the VisData Tool you are using.
Create Table IColTest (Id_Col int Identity, Name VarChar(30) Null) Create Unique Index IIndex on IColTest(Id_Col)
Article ID: 190620 - Last Review: 06/22/2014 19:11:00 - Revision: 3.0
- kbbug kbdatabase kbDSupport kbprb KB190620