Page 1 of 1

Refreshing underlying data

Posted: Mon 15 Oct 2007 14:31
by ibdac2pro
Hi,

I have an application written in Delphi 7 with an Interbase 7 database.

The application runs in a multi-user environment and I was wondering what is the most efficient way to refresh my view of the data in order to reflect changes made by other users.

Many thanks,

Michael

Posted: Wed 17 Oct 2007 08:04
by Plash
Call the Refresh method of TIBCQuery to refresh the data. You can call this method when a user presses some button or selects an item from the program menu. You can also use TTimer component to call the Refresh method periodically.

Refreshing underlying data

Posted: Fri 19 Oct 2007 13:07
by ibdac2pro
Hi
Thank you for your quick response.
Unfortunately I have used Refresh several times to obtain the underlying data but the values from computed fields do not appear on the application.
I have even tried opening and closing the query, to no avail. The data from these computed fields does eventually appear if I move onto another record and back.
Additional information
I am using a masterdetail relationship with the computed data on the detail.
I have also tried IBCQuery1.params.

Many thanks

Michael

Posted: Mon 22 Oct 2007 11:04
by Plash
We could not reproduce the problem. Please specify, do you mean computed fields in the database table, or Delphi calculated fields?

Refreshing underlying data

Posted: Mon 22 Oct 2007 12:21
by ibdac2pro
Thanks for your prompt reply.

The computed fields are actually in the database.

For example :

TOTALK121 COMPUTED BY (oneofftotalK120+materialtotalK118+
fabcostsK117+lasercostK119),
COSTTOMAKE COMPUTED BY ((totalK121*100)/(100+Markup)),
MARKUPIN COMPUTED BY (totalK121-Costtomake)

Hope this helps.

Many thanks,

Michael

Posted: Tue 23 Oct 2007 08:12
by Plash
Please send to ibdac*crlab*com a complete small sample that demonstrates the problem, including script to create server objects.