Re: Help with triggers/FrontBase (was: sequential numbering across more instances)
Re: Help with triggers/FrontBase (was: sequential numbering across more instances)
- Subject: Re: Help with triggers/FrontBase (was: sequential numbering across more instances)
- From: Ondřej Čada <email@hidden>
- Date: Wed, 20 Aug 2008 16:44:08 +0200
Well, thanks a lot, but this actually is not a problem at all, for the
table already exists and contains lots of non-NULL numbers.
The real problem is that the update trigger does not work (or, more
precisely, that I don't see what I am doing wrong and how to fix it) :(
SELECT MAX(column) FROM table
will return null when there are no values yet for that column. I
believe you need to do something like:
SELECT CASE WHEN MAX(column) IS NOT NULL THEN MAX(column) ELSE 0
END FROM table
Or simpler:
SELECT ISNULL(MAX(column), 0) FROM table
Best,
---
Ondra Čada
OCSoftware: email@hidden http://www.ocs.cz
private email@hidden http://www.ocs.cz/oc
_______________________________________________
Do not post admin requests to the list. They will be ignored.
Webobjects-dev mailing list (email@hidden)
Help/Unsubscribe/Update your Subscription:
This email sent to email@hidden