[Greater-commits] r234 - trunk/GREAT-ER-DB/impl/postgresql
scm-commit@wald.intevation.org
scm-commit at wald.intevation.org
Wed Jun 22 12:01:31 CEST 2011
Author: aheinecke
Date: 2011-06-22 12:01:30 +0200 (Wed, 22 Jun 2011)
New Revision: 234
Modified:
trunk/GREAT-ER-DB/impl/postgresql/gdagreater_pg.pgc
Log:
Change case statements to insert with indicator because negative values
would cause errors otherwise.
Modified: trunk/GREAT-ER-DB/impl/postgresql/gdagreater_pg.pgc
===================================================================
--- trunk/GREAT-ER-DB/impl/postgresql/gdagreater_pg.pgc 2011-06-22 09:46:55 UTC (rev 233)
+++ trunk/GREAT-ER-DB/impl/postgresql/gdagreater_pg.pgc 2011-06-22 10:01:30 UTC (rev 234)
@@ -13281,13 +13281,13 @@
TEMP_SESS_SRC_ID,
REMARK)
VALUES (:h_sess_id_new,
- CASE WHEN :h_sess.catch_id = -1 THEN NULL ELSE :h_sess.catch_id END,
- CASE WHEN :h_sess.subst_id = -1 THEN NULL ELSE :h_sess.subst_id END,
- CASE WHEN :h_sess.env_id = -1 THEN NULL ELSE :h_sess.env_id END,
- CASE WHEN :h_sess.market_id = -1 THEN NULL ELSE :h_sess.market_id END,
- CASE WHEN :h_sess.mod_id = -1 THEN NULL ELSE :h_sess.mod_id END,
- CASE WHEN :h_sess.res_id = -1 THEN NULL ELSE :h_sess.res_id END,
- CASE WHEN :h_sess.sess_disch_id = -1 THEN NULL ELSE :h_sess.sess_disch_id END,
+ :h_sess.catch_id :h_sess.catch_id,
+ :h_sess.subst_id :h_sess.subst_id,
+ :h_sess.env_id :h_sess.env_id,
+ :h_sess.market_id :h_sess.market_id,
+ :h_sess.mod_id :h_sess.mod_id,
+ :h_sess.res_id :h_sess.res_id,
+ :h_sess.sess_disch_id :h_sess.sess_disch_id,
:h_sess.name,
:h_temp_user_id,
to_timestamp(:h_sess.cre_date, :h_fmt_date),
More information about the Greater-commits
mailing list