VBcoders Browse New Submit Contact Sign In

No account? Register free

Forgot password?

RECORDSET COPYING USING ADO 2.5 STREAM OBJECT AND XML (MDAC 2.5 REQUIRED)

visual-basic-data-mining.net  (2 Submissions)   Databases/Data Access/DAO/ADO   Visual Basic 5.0   Intermediate   Wed 3rd February 2021

PROBLEM:
Creating a copy of a Recordset could mean using the Recordset.Clone method sometimes. However, this is not always appropriate because ADO’s Recordset.Clone method creates a Recordset which points to the same data as the original Recordset. This means that you really do not get a physically distinct copy of the original Recorsdet. Consequently, changes to the clone copy could modify the data in the original Recordset.
An alternative solution would be to use a loop to append each record to a new recordset. This, however could end up being an unwieldy solution with potential performance penalties.
SOLUTION:
ADO 2.5 comes with a Stream object that can be used to create physically distinct copies of Recordsets. The article below demonstrates the use of the ADO 2.5 Stream object in copying Recordsets and the difference between the Recordsets created by the Recordset.Clone method and ADO 2.5 Stream object.
Please see attached file.

Rate RECORDSET COPYING USING ADO 2.5 STREAM OBJECT AND XML (MDAC 2.5 REQUIRED) (8(8 Vote))

Download RECORDSET COPYING USING ADO 2.5 STREAM OBJECT AND XML (MDAC 2.5 REQUIRED)

RECORDSET COPYING USING ADO 2.5 STREAM OBJECT AND XML (MDAC 2.5 REQUIRED) Comments

No comments yet — be the first to post one!

Post a Comment

0/1000 characters