[firebase-br] RES: Estudo de Caso - Como otimizar este update

Murilo Garcia Bento murilo em cprinformatica.com.br
Qua Ago 20 23:39:13 -03 2008


> "Kleber Caneva" <kdcc em terra.com.br> escreveu na 
> mensagem news:01e601c90303$5028b4c0$8603a8c0 em motocana.com...
> Otimizando ainda mais
> Tente assim:
>
> UPDATE TABELA1 T1
> SET T1.CAMPO1 = 'X'
> WHERE T1.CAMPO1 <> 'X'
>    and exists (select 1 from TABELA2 T2 where t1.PK_TABELA1 =
> t2.PK_TABELA1);

E se por um índice no campo T1.CAMPO1??? Não ajuda??? 






Mais detalhes sobre a lista de discussão lista