Subject | Re: [firebird-support] Re: domains inside Stored Procedures |
---|---|
Author | Ann W. Harrison |
Post date | 2005-06-03T19:18:52Z |
Adam,
constrained (hint, the answer is yes)? OK, but what about intermediate
results... If the output parameter is not null, can you set it to null
within the procedure, or does that cause an error?
they're running, so the exact mechanism is tricky. Not that it can't be
resolved, but that it's non-trivial.
Regards,
Ann
>OK, I'm with you on input. But should the output parameters also be
>
> The same way you handle someone trying to put an integer into a
> varchar field or a string into a timestamp. If I define
>
> CREATE DOMAIN TBLID AS INTEGER check( value > 0 ) NOT NULL;
>
> And someone tries to use a parameter of -1, then it is an invalid
> typecast (or whatever the error is). It is as wrong (from a business
> rules perspective) as trying to insert 'Adam' into such a field.
> Obviously, just my personal opinion
constrained (hint, the answer is yes)? OK, but what about intermediate
results... If the output parameter is not null, can you set it to null
within the procedure, or does that cause an error?
>That sounds good, except that procedures can't be recompiled while
> And what happens to a procedure when the constraint on the
> domain of one of its parameters changes?
>
> I imagine it would have to recompile.
they're running, so the exact mechanism is tricky. Not that it can't be
resolved, but that it's non-trivial.
>I agree completely
>
> Thats fine. The work around is pretty simple. ... but I still think
> that in the long run this will be a very powerful feature.
>
Regards,
Ann