Subject Re: [IBO] CachedUpdates and Refresh
Author Emerson - IBO - Firebird
Hi Helen,

Thank you for reply.

Let's go, step by step:

1) My IB_Query has the CachedUpdates property set to TRUE (because i
have a master-detail situation);

2) The value of SQLWhere statement : "WHERE status = 0";

3) When user done some operation I have the following statement:

query.Edit;
query.FieldByName('status').value := 1;
qryDETALHE.Post;
qryDETALHE.Refresh; (I use this refresh because I wanna that the
record disppears from my dataset. Your status value is 1 and according
my SQLWHERE, only records with status = 0 will be showed)

So, in this point I don't use ApplyUpdates or Commit the data to server.

After commit really works, but this don't solve my problem.

I need that the SQLWhere statement "works" in memory data.

Any suggestion are welcome.

Thanks again.

Emerson


Em 17/11/2010 23:28, Helen Borrie escreveu:
>
> At 08:53 AM 18/11/2010, you wrote:
> >Hello there!
> >
> >I have another question today.
> >
> >In my TIB_Query I have this SQLWhere statement: WHERE status = '0'.
> >
> >In response to some user action my program set the value of status to
> >'1' and execute Refresh method in TIB_Query.
> >
> >So, I hope that the record with status = '1' disappears of my dataset,
> >but this doesn't happens. The record still there, even after I refresh
> >the dataset.
> >
> >I imagine that it happens because I use CachedUpdates = TRUE in
> TIB_Query.
>
> I imagine that it happens because whatever you are doing to commit the
> transaction does not in fact commit the transaction and you are simply
> continuing to see the uncommitted contents of the cache. It would make
> sense to show the code steps that you are doing.
>
> Helen
>
>
> ------------------------------------------------------------------------
>
> Nenhum vírus encontrado nessa mensagem.
> Verificado por AVG - www.avgbrasil.com.br <http://www.avgbrasil.com.br>
> Versão: 10.0.1153 / Banco de dados de vírus: 424/3262 - Data de
> Lançamento: 11/17/10
>



[Non-text portions of this message have been removed]