TSimpleDataSet

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
deFreitas
Posts: 9
Joined: Mon 07 May 2012 17:14

TSimpleDataSet

Post by deFreitas » Wed 05 Feb 2014 20:24

Need an example of how to replace TSimpleDataSet with MyDAC components, please.
Mário de Freitas
São Paulo - BR

jkuiper2105
Posts: 20
Joined: Wed 18 Sep 2013 14:10

Re: TSimpleDataSet

Post by jkuiper2105 » Thu 06 Feb 2014 09:52

You can't.
TSimpledataset is a DBExpress component.

Why would you?

deFreitas
Posts: 9
Joined: Mon 07 May 2012 17:14

Re: TSimpleDataSet

Post by deFreitas » Thu 06 Feb 2014 18:59

Yes, I know it's a DBExpress component.
I also know that with him:
It has an internal connection;
Provides access to properties and events of the DataSet and internal SQLConnection;
TFields allows you to configure the internal DataSet;

But I want to change all this by MyDAC components. Therefore seeking an example to help me.
Regards.

deFreitas
Posts: 9
Joined: Mon 07 May 2012 17:14

Re: TSimpleDataSet

Post by deFreitas » Fri 07 Feb 2014 12:08

Hi, I managed to solve my doubt by searching, as follows:

The TSimpleDataSet is a "provider" of data, just as the TMyQuery. Based on an SQL sentence they will provide the data.

To replace the TSimpleDataSet by TMyQuery we copy the SQL statement from of the DataSet.CommandText TSimpleDataSet property and we put in the property SQL TMyQuery.

======
Consegui resolver a minha dúvida através de pesquisas.

O TSimpleDataSet é um “provedor” de dados, assim como o TMyQuery. Com base em uma sentença SQL eles vão fornecerão os dados.

Para substituir o TSimpleDataSet pelo TMyQuery, deve-se pegar a sentença SQL que está na propriedade DataSet.CommandText do TSimpleDataSet e colocá-la na propriedade SQL do TMyQuery.

Dimon
Devart Team
Posts: 2910
Joined: Mon 05 Mar 2007 16:32

Re: TSimpleDataSet

Post by Dimon » Fri 07 Feb 2014 13:24

It is good to see the this issue has been solved. Feel free to contact us if you have any further questions about MyDAC.

Post Reply