Cast '' (blank) to null date

Поиск
Список
Период
Сортировка
От Mattis Jiderhamn
Тема Cast '' (blank) to null date
Дата
Msg-id 9j8udq$fmo$1@news.tht.net
обсуждение исходный текст
Ответы Re: Cast '' (blank) to null date
Список pgsql-sql
Hi there everyone.
I'm trying to create a trigger so that, if I try to insert blank, that is
'', into a date field it will be converted to null so that I don't get ERROR:  Bad date external representation ''

I believe my ploblem is that I don't know the type of blank (''), and
therefore do not know what to cast from.
It seems it is not unknown.
Any other suggestions?

Thanks, Mattias Jiderhamn mattias@expertsystem.se




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

Предыдущее
От: David Stanaway
Дата:
Сообщение: Re: example of [outer] join
Следующее
От: "Fons Rave"
Дата:
Сообщение: Records exactly the same.