Subject | Re: [IBO] Problems with refresh |
---|---|
Author | Jason Wharton |
Post date | 2002-05-01T06:45:49Z |
If the record it is on at the time of insert sorts to the end part of the
dataset it will maintain that record's actual position in the dataset and
fetch records until it gets to it. By calling First you position the cursor
on the first record of the dataset and so refresh only has to fetch one
record in order to preserve the current record pointer upon refreshing the
dataset.
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com
dataset it will maintain that record's actual position in the dataset and
fetch records until it gets to it. By calling First you position the cursor
on the first record of the dataset and so refresh only has to fetch one
record in order to preserve the current record pointer upon refreshing the
dataset.
Jason Wharton
CPS - Mesa AZ
http://www.ibobjects.com
----- Original Message -----
From: "Helmut Steinberger" <hs@...>
To: <IBObjects@yahoogroups.com>
Sent: Tuesday, April 30, 2002 10:49 PM
Subject: [IBO] Problems with refresh
> Hello,
>
> I have a problem with refresh.
> Following situation:
>
> var
> query : tib_query;
>
> begin
> .......
> query.sql.txt := 'select * from table1';
> query.open;
> ......
> query.insert;
> query.fieldbyname('field1').asstring := 'xxx';
> ...
> query.post;
> query.refresh (true);
> .....
> end;
>
> By calling the refresh (true) the insert is comitted, but all records
> in the table are fetched after that.
>
> When I use query.first instead of query.open, then only one record is
> fetched wehn I call the refresh method.
>
> I don't understand that. Could anybody Explain?
>
> cu
> Helmut