Usa o *RETURNING*

2011/4/26 Marcone <marconepe...@gmail.com>

> Vê se assim resolve:
>
> select t1.*
> from Teste01 t1
> join (select id, max(datetime) datetime
>        from Teste01
>        group by id) t2
>  on t2.id = t1.id
>        and t2.datetime = t1.datetime;
> _______________________________________________
> pgbr-geral mailing list
> pgbr-geral@listas.postgresql.org.br
> https://listas.postgresql.org.br/cgi-bin/mailman/listinfo/pgbr-geral
>
_______________________________________________
pgbr-geral mailing list
pgbr-geral@listas.postgresql.org.br
https://listas.postgresql.org.br/cgi-bin/mailman/listinfo/pgbr-geral

Responder a