🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Thread View: borland.public.cppbuilder.database.ado
7 messages
7 total messages Started by Sinead Bunyan Thu, 23 Aug 2007 11:29
How to Convert TDataSet to TADO Recordset
#96
Author: Sinead Bunyan
Date: Thu, 23 Aug 2007 11:29
12 lines
1336 bytes
Hi,

I would like to be able to pass a TDataSet to the following function which
requires an ADO Recordset:

Rpt->Database->SetDataSource((Variant)ADOQuery1->Recordset,(Variant)3,(Variant)1);

Instead of passing an ADOQuery I would like to pass a TDataSet (i.e either a
BDE Query or Table).

Thanks in advance,
Sinead
Re: How to Convert TDataSet to TADO Recordset
#97
Author: Vassiliev V. V.
Date: Thu, 23 Aug 2007 14:25
28 lines
1900 bytes
You will have to creaet a wrapper, for example, using simple OLEDB provider. 
It is not an easy task.

//------------------------------------------
Regards,
Vassiliev V. V.
http://www.managed-vcl.com - using .Net objects in Delphi for Win32 +
ADO.Net
http://www.oledbdirect.com - The fastest way to access MS SQL Server,
MS Jet (Access) and Interbase (through OLEDB)


"Sinead Bunyan" <nospamSBUNYAN@DAIRYMASTER.COM> ???????/???????? ? ???????? 
?????????: news:46cd6ffd@newsgroups.borland.com...
> Hi,
>
> I would like to be able to pass a TDataSet to the following function which
> requires an ADO Recordset:
>
> Rpt->Database->SetDataSource((Variant)ADOQuery1->Recordset,(Variant)3,(Variant)1);
>
> Instead of passing an ADOQuery I would like to pass a TDataSet (i.e either 
> a
> BDE Query or Table).
>
> Thanks in advance,
> Sinead
> 
Re: How to Convert TDataSet to TADO Recordset
#98
Author: Sinead Bunyan
Date: Thu, 23 Aug 2007 16:25
46 lines
2340 bytes
Hi Vassiliev,

Thank you for your help on this, at least now I know that it is possible and 
can work from there.

Is there any possibility that you may be able to provide me with an example 
of such a wrapper?

Thanks again for your help.

Regards,
Sinead

"Vassiliev V. V." <support@oledbdirect.com> wrote in message 
news:46cd9901@newsgroups.borland.com...
> You will have to creaet a wrapper, for example, using simple OLEDB 
> provider. It is not an easy task.
>
> //------------------------------------------
> Regards,
> Vassiliev V. V.
> http://www.managed-vcl.com - using .Net objects in Delphi for Win32 +
> ADO.Net
> http://www.oledbdirect.com - The fastest way to access MS SQL Server,
> MS Jet (Access) and Interbase (through OLEDB)
>
>
> "Sinead Bunyan" <nospamSBUNYAN@DAIRYMASTER.COM> ???????/???????? ? 
> ???????? ?????????: news:46cd6ffd@newsgroups.borland.com...
>> Hi,
>>
>> I would like to be able to pass a TDataSet to the following function 
>> which
>> requires an ADO Recordset:
>>
>> Rpt->Database->SetDataSource((Variant)ADOQuery1->Recordset,(Variant)3,(Variant)1);
>>
>> Instead of passing an ADOQuery I would like to pass a TDataSet (i.e 
>> either a
>> BDE Query or Table).
>>
>> Thanks in advance,
>> Sinead
>>
>
> 
Re: How to Convert TDataSet to TADO Recordset
#99
Author: Clayton Arends
Date: Thu, 23 Aug 2007 16:35
10 lines
1501 bytes
> Thank you for your help on this, at least now I know that it is possible 
> and can work from there.

I believe the intent was to persuade you to not continue in this direction.

Perhaps you can explain a little about the types of 'Rpt' and 'Database' and 
what functionality you are after.  There might be other alternatives that 
you can pursue once a little more is known about your problem.

- Clayton
Re: How to Convert TDataSet to TADO Recordset
#100
Author: Sinead Bunyan
Date: Thu, 23 Aug 2007 17:02
38 lines
2843 bytes
Hi Clayton,

I am basically incorporating Crystal Reports 11 into an existing c++ 
project. Previously we had used a component from a company called Suprasoft, 
which allowed us to pass a TDataSet to report templates and using TTX files 
we could display our reports accordingly. In this way we did not have to 
specify the data location when designing the reports.

However (!), we now are faced with using Crystal Reports 11, which requires 
that data be passed to the reports as an ADO recordset. Because it is an 
existing project, all datasets are created and ideally we would like a way 
to work from the existing datasets - we do not want to change all TDataSet 
components to TADODataSets and also we do not want to have to generate these 
datasets twice (once to populate our TDataSet, and once to populate a 
TADODataSet). Hopefully this is making sense?

Any suggestions would be greatly appreciated - I have a very limited 
knowledge of ADO objects, sorry for my ignorance on this subject!

Thanks in advance,
Sinead


"Clayton Arends" <nospam_claytonarends@hotmail.com> wrote in message 
news:46cdb750$1@newsgroups.borland.com...
>> Thank you for your help on this, at least now I know that it is possible 
>> and can work from there.
>
> I believe the intent was to persuade you to not continue in this 
> direction.
>
> Perhaps you can explain a little about the types of 'Rpt' and 'Database' 
> and what functionality you are after.  There might be other alternatives 
> that you can pursue once a little more is known about your problem.
>
> - Clayton
>
> 
Re: How to Convert TDataSet to TADO Recordset
#101
Author: Vassiliev V. V.
Date: Thu, 23 Aug 2007 19:21
66 lines
3962 bytes
Intent was really to persuade you to not continue in this direction. Did 
Crystal Reports stopped support BDE? If not, you could connect to BDE tables 
directly, without datasets. Or connect to DBF/Paradox files with Jet OLEDB 
provider (there may be problems with update Paradox tables, but in read-only 
mode this may work).

If you still want to continue with creating recordset wrapper for TDataSet 
(in this case through special OLEDB provider), look at:

http://www.dataweb.de/en/support/articles/ospdelphi/ospdelphi.html

http://msdn2.microsoft.com/en-us/library/aa160399(office.11).aspx

However it could take much more time and efforts than you expect.

//------------------------------------------
Regards,
Vassiliev V. V.
http://www.managed-vcl.com - using .Net objects in Delphi for Win32 +
ADO.Net
http://www.oledbdirect.com - The fastest way to access MS SQL Server,
MS Jet (Access) and Interbase (through OLEDB)



"Sinead Bunyan" <nospamSBUNYAN@DAIRYMASTER.COM> ???????/???????? ? ???????? 
?????????: news:46cdbe15@newsgroups.borland.com...
> Hi Clayton,
>
> I am basically incorporating Crystal Reports 11 into an existing c++ 
> project. Previously we had used a component from a company called 
> Suprasoft, which allowed us to pass a TDataSet to report templates and 
> using TTX files we could display our reports accordingly. In this way we 
> did not have to specify the data location when designing the reports.
>
> However (!), we now are faced with using Crystal Reports 11, which 
> requires that data be passed to the reports as an ADO recordset. Because 
> it is an existing project, all datasets are created and ideally we would 
> like a way to work from the existing datasets - we do not want to change 
> all TDataSet components to TADODataSets and also we do not want to have to 
> generate these datasets twice (once to populate our TDataSet, and once to 
> populate a TADODataSet). Hopefully this is making sense?
>
> Any suggestions would be greatly appreciated - I have a very limited 
> knowledge of ADO objects, sorry for my ignorance on this subject!
>
> Thanks in advance,
> Sinead
>
>
> "Clayton Arends" <nospam_claytonarends@hotmail.com> wrote in message 
> news:46cdb750$1@newsgroups.borland.com...
>>> Thank you for your help on this, at least now I know that it is possible 
>>> and can work from there.
>>
>> I believe the intent was to persuade you to not continue in this 
>> direction.
>>
>> Perhaps you can explain a little about the types of 'Rpt' and 'Database' 
>> and what functionality you are after.  There might be other alternatives 
>> that you can pursue once a little more is known about your problem.
>>
>> - Clayton
>>
>>
> 
Re: How to Convert TDataSet to TADO Recordset
#104
Author: Harold Howe [TeamB]
Date: Mon, 27 Aug 2007 06:28
11 lines
1653 bytes
Sinead Bunyan wrote:

> However (!), we now are faced with using Crystal Reports 11, which 
> requires that data be passed to the reports as an ADO recordset.

TADODataSet allows you to populate it in code. It works like a 
TClientDataSet when you do this. Could you write a routine that blasts 
data from a TDataSet into a disconnected TADODataSet, and then pass the 
RecordSet property of the TADODataSet to crystal reports?

H^2
Thread Navigation

This is a paginated view of messages in the thread with full content displayed inline.

Messages are displayed in chronological order, with the original post highlighted in green.

Use pagination controls to navigate through all messages in large threads.

Back to All Threads