Re: change null to 0 in SQL script

Поиск
Список
Период
Сортировка
От Karl Raven
Тема Re: change null to 0 in SQL script
Дата
Msg-id a17p72$bne$1@news.tht.net
обсуждение исходный текст
Ответ на change null to 0 in SQL script  ("Karl Raven" <lcaasia@pd.jaring.my>)
Список pgsql-sql
thanks
will try it..


"ThomasR" <trx@wtal.de> wrote in message news:3C360816.1080103@wtal.de...
> Karl Raven wrote:
>
> > I like to change a null value of a query to 0 in the SQL script. I know
how
> > to do it in MS-SQL server and MS-Access but those commands does not work
in
> > pg-sql.
> >
> > Anyone has any ideas?
> >
> > Thanks
> >
>
> I think the following should work:
>
> select coalesce( my_attrib, 0 ) from my_tab
>
> Thomas
>




В списке pgsql-sql по дате отправления:

Предыдущее
От: "Mir S Islam"
Дата:
Сообщение: who has lock on table/row
Следующее
От: Frank Bax
Дата:
Сообщение: Re: Resources