Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Usenet -> c.d.o.misc -> Re: Use of ADO with MSDAORA provider

Re: Use of ADO with MSDAORA provider

From: Gregory Volkonsky <gregoryvo_at_hotmail.com>
Date: Tue, 23 Oct 2001 16:15:23 +0200
Message-ID: <3bd58a8c@nntp.kla-tencor.com>


Run-time error '3251':

Object or provider is not capable of performing requested operation.

It opens recordset in readonly mode.
If I open it for some XML file it makes me possible to update.

"Niall Litchfield" <n-litchfield_at_audit-commission.gov.uk> wrote in message news:3bd54f8c$0$237$ed9e5944_at_reading.news.pipex.net...
> What error message do you get?
>
>
> --
> Niall Litchfield
> Oracle DBA
> Audit Commission UK
> "Gregory Volkonsky" <gregoryvo_at_hotmail.com> wrote in message
> news:3bd52d1b$1_at_nntp.kla-tencor.com...
> > I have some problem with ADO using MSDAORA provider:
> > The following is algorithm of the problem:
> >
> > 1. Connect to Oracle with MSDAORA provider
> > 2. Select rows from any table into recordset
> > 3. Save recordset into file in XML format
> > 4. Open this file by another recordset.
> > 5. Open connection to the same DB
> > 6. Save data from file into DB back (previously this data was removed
from
> > DB)
> >
> > The following is code:
> > To save into XML file:
> > Dim cn As New ADODB.Connection
> >
> > Dim rst As New ADODB.Recordset
> >
> > cn.Open "Provider=MSDAORA;Data Source=OMER1", "GREG", "GREG"
> >
> > rst.Open "SELECT * FROM x", cn, adOpenDynamic, adLockOptimistic,
adCmdText
> >
> > 'For sake of illustration, save the Recordset to a diskette in XML
> > 'format.
> > rst.Save "c:\Stam\pubs.adtg", adPersistADTG
> > MsgBox "Save into file is done!"
> > rst.Close
> > cn.Close
> >
> >
> >
> >
> > To take the data from XML file back to DB:
> >
> > Dim cn As New ADODB.Connection
> > Dim rst As New ADODB.Recordset
> >
> > 'If there is no ActiveConnection, you can open with defaults.
> > rst.Open "c:\Stam\pubs.xml"
> >
> > 'Connect to the database, associate the Recordset with the connection,
> > 'then update the database table with the changed Recordset.
> > cn.Open "Provider=MSDAORA;Data Source=OMER1", "GREG", "GREG"
> > rst.ActiveConnection = cn
> >
> > rst.Update // HERE THE PROGRAM FAILS
> >
> > Please help
> >
> >
> >
>
>
Received on Tue Oct 23 2001 - 09:15:23 CDT

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US