Subject | RE: [Firebird-Architect] Domains and NOT NULL in PSQL |
---|---|
Author | Dmitry Yemanov |
Post date | 2006-07-13T06:01:37Z |
Adriano,
DECLARE V1 D;
DECLARE V2 D;
DECLARE V3 D;
V3 = V1 + V2;
If someone would change a domain to become VARCHAR, this PSQL code won't
parse (at least in DSQL) in Dialect 3. Perhaps a BLR parse will miss that
mismatch, but it would also mean that a *compatible* data change
(INT->VARCHAR) will cause runtime errors during execution. This is yet
another issue to be added to the BLR invalidation mechanism.
Also, I think there may be other cases (besides arrays) when BLR won't parse
after a type change. For example, a format (e.g. for some select statement
inside PSQL code) could become more than 32K in length after increasing
[VAR]CHAR size.
previous message.
Dmitry
> > What if the change to the domain means that the SP is not recompilable?CREATE DOMAIN D INT;
>
> AFAIK the only thing with may cause that is arrays.
> We don't allow arrays in PSQL and arrays could be used in domains.
> The rejection for domain arrays should be done at runtime.
DECLARE V1 D;
DECLARE V2 D;
DECLARE V3 D;
V3 = V1 + V2;
If someone would change a domain to become VARCHAR, this PSQL code won't
parse (at least in DSQL) in Dialect 3. Perhaps a BLR parse will miss that
mismatch, but it would also mean that a *compatible* data change
(INT->VARCHAR) will cause runtime errors during execution. This is yet
another issue to be added to the BLR invalidation mechanism.
Also, I think there may be other cases (besides arrays) when BLR won't parse
after a type change. For example, a format (e.g. for some select statement
inside PSQL code) could become more than 32K in length after increasing
[VAR]CHAR size.
> > Could this "invalidation" be used to allow for SP's to be droppedI think Sean refers to another invalidation which I've described in my
> > completely?
>
> ?
previous message.
Dmitry