URGENT!!: How to refresh in realtime a DBGrid with MyDAC ??

Discussion of open issues, suggestions and bugs regarding MyDAC (Data Access Components for MySQL) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
ghazaliove
Posts: 5
Joined: Mon 04 Feb 2008 20:32
Location: ALGERIA
Contact:

URGENT!!: How to refresh in realtime a DBGrid with MyDAC ??

Post by ghazaliove » Mon 04 Feb 2008 20:42

Hello,
When i try to insert new Record from the CLIENT application , but i can't see the new record in the DBGrid of the server application(where is stored the database?

How can i see the changes in the DBGrid of server application in realtime??

Thanks
:oops:

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

Post by Dimon » Tue 05 Feb 2008 13:51

You should call the TDataSet.Refresh method when you want to get up-to-date information. You can call it on a Timer event handler.

ghazaliove
Posts: 5
Joined: Mon 04 Feb 2008 20:32
Location: ALGERIA
Contact:

Thanks

Post by ghazaliove » Wed 06 Feb 2008 09:39

Thanks a lot
:oops:

FerCastro
Posts: 47
Joined: Mon 26 Jun 2006 17:32
Location: México City
Contact:

Post by FerCastro » Thu 21 Aug 2008 16:45

Dimon wrote:You should call the TDataSet.Refresh method when you want to get up-to-date information. You can call it on a Timer event handler.
Hello Dimon, and, what if i am using DataSource instead Dataset?

Best regards

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

Post by Dimon » Fri 22 Aug 2008 12:23

Use the following code:

Code: Select all

DataSource.DataSet.Refresh;
Also you can use the TCustomMyDataSet.Options.AutoRefresh and TCustomMyDataSet.Options.AutoRefreshInterval properties.

fadly.syam09
Posts: 2
Joined: Tue 28 Nov 2017 20:45

Re: URGENT!!: How to refresh in realtime a DBGrid with MyDAC ??

Post by fadly.syam09 » Tue 28 Nov 2017 20:52

I have the same Questions,..

but in my case, i'm using TMyConnection + TMyQuery only..
when the user has made a insert record in client side, how can i monitoring the change of the Database by realtime without using TTimer in my Delphi Form Application?.. is that any way in MyDac to do that, i realized that this is hard to make hapen but i do need this function in my Application.

thank you very much, i hope i can get the answer as soon as possible

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: URGENT!!: How to refresh in realtime a DBGrid with MyDAC ??

Post by ViktorV » Wed 29 Nov 2017 09:18

MySQL doesn't provide a capability to retrieve information about changes made in another query without request to the server. For quick retrieving of changes made by other quires, you can use the TCustomDADataSet.RefreshQuick method. Note, that usage of this method requires the table to have unique key fields and a TIMESTAMP field. See more details about this method in MyDAC help: https://www.devart.com/mydac/docs/devar ... olean).htm

fadly.syam09
Posts: 2
Joined: Tue 28 Nov 2017 20:45

Re: URGENT!!: How to refresh in realtime a DBGrid with MyDAC ??

Post by fadly.syam09 » Sat 30 Dec 2017 10:17

ViktorV wrote:MySQL doesn't provide a capability to retrieve information about changes made in another query without request to the server. For quick retrieving of changes made by other quires, you can use the TCustomDADataSet.RefreshQuick method. Note, that usage of this method requires the table to have unique key fields and a TIMESTAMP field. See more details about this method in MyDAC help: https://www.devart.com/mydac/docs/devar ... olean).htm
thank you very much

ViktorV
Devart Team
Posts: 3168
Joined: Wed 30 Jul 2014 07:16

Re: URGENT!!: How to refresh in realtime a DBGrid with MyDAC ??

Post by ViktorV » Tue 02 Jan 2018 09:28

Thank you for the interest in our products.
If you have any questions during using our products, please don't hesitate to contact us - and we will try to help you solve them.

Post Reply