What is the difference between a Dynaset and Snapshot and
how would you create one?

Answers were Sorted based on User's Feedback



What is the difference between a Dynaset and Snapshot and how would you create one?..

Answer / george

All Recordset objects are constructed using records (rows)
and fields (columns). There are five types of Recordset
objects:

Table-type Recordset ::
********************
representation in code of a base table that you can use to
add, change,or delete records from a single database table
(Microsoft Jet workspaces only).

Dynaset-type Recordset ::
**********************
the result of a query that can have updatable records. A
dynaset-type Recordset object is a dynamic set of records
that you can use to add, change, or delete records from an
underlying database table or tables.
A dynaset-type Recordset object can contain fields from one
or more tables in a database. This type corresponds to an
ODBC keyset cursor.

Snapshot-type Recordset ::
**********************
a static copy of a set of records that you can use to find
data or generate reports. A snapshot-type Recordset object
can contain fields from one or more tables in a database
but can't be updated. This type corresponds to an ODBC
static cursor.

Forward-only-type Recordset::
***************************
identical to a snapshot except that no cursor is provided.
You can only scroll forward through records. This improves
performance in situations where you only need to make a
single pass through a result set. This type corresponds to
an ODBC forward-only cursor.

Dynamic-type Recordset ::
**********************
a query result set from one or more base tables in which
you can add,change, or delete records from a row-returning
query. Further, records other users add, delete, or edit in
the base tables also appear in your Recordset. This type
corresponds to an ODBC dynamic cursor (ODBCDirect
workspaces only).

Is This Answer Correct ?    10 Yes 1 No

What is the difference between a Dynaset and Snapshot and how would you create one?..

Answer / suresh

A dynaset-type Recordset object is a dynamic set of records
that can contain fields from one or more tables or queries
in a database and may be updatable. In an ODBCDirect
database, a dynaset-type Recordset object corresponds to an
ODBC keyset cursor.
Remarks
A dynaset-type Recordset object is a type of Recordset
object you can use to manipulate data in an underlying
database table or tables.
It differs from a snapshot-type Recordset object because
the dynaset stores only the primary key for each record,
instead of actual data. As a result, a dynaset is updated
with changes made to the source data, while the snapshot is
not. Like the table-type Recordset object, a dynaset
retrieves the full record only when it's needed for editing
or display purposes.

A snapshot-type Recordset object is a static set of records
that you can use to examine data in an underlying table or
tables. In an ODBCDirect database, a snapshot-type
Recordset object corresponds to a static cursor.
Remarks
To create a snapshot-type Recordset object, use the
OpenRecordset method on an open database, on another
dynaset- or snapshot-type Recordset object, or on a
QueryDef object.

Is This Answer Correct ?    9 Yes 2 No

Post New Answer

More Visual Basic Interview Questions

How would you run your ActiveX Document Dll?

0 Answers  


What is visual basic used for?

0 Answers  


plzzzzzzz mail me some questions that r important to revise before an interviev wat r the possible question that mnc ask MY EMAIL ID shanty_pathak@yahoo.com

3 Answers   Wipro,


How to change the Mouse Pointer?

2 Answers  


What are the tools available for Debug in VB?

3 Answers  






What is difference between datagrid and flexgrid?

3 Answers   InfoWorld, TCS,


How many system controls are available ?

1 Answers  


Is there a way to break long lines in VB code?

0 Answers  


What is FireHouse Cursors?

0 Answers  


How would you create properties in ActiveX Control?

0 Answers  


What is the default property of datacontrol?

2 Answers   VSoft,


Difference between Linked Object and Embedded Object?

0 Answers  


Categories