> -----Mensaje original-----
> De: pgsql-sql-owner(at)postgresql(dot)org
> [mailto:pgsql-sql-owner(at)postgresql(dot)org] En nombre de Scott Marlowe
>
> On Fri, Sep 12, 2008 at 12:50 PM, Hengky Lie
> <hengkyliwandouw(at)gmail(dot)com> wrote:
> > Dear Richard,
> >
>
> Put parens around the whole thing, like:
>
> (tbltransaksi.hargapokok * tbltransaksi.keluar)::numeric(2,0) AS modal
>
Consider that if you are NOT going to use the decimals you should really use
integer or bigint datatypes. The numeric type compute much slower than
integer datatypes.
Regards,
Fernando