Subject Re: Detecting dependancies
Author Adam
--- In firebird-support@yahoogroups.com, Robert martin <rob@c...> wrote:
>
> Hi
>
> Thanks for the quick replies guys. The issue is that the procedure
does
> and drop and recreate of each field in the table (just because it is
> easier). The idea is that SP fields would not be modified at all.
>
>
> Rob Martin
> Software Engineer
>
> phone +64 03 377 0495
> fax +64 03 377 0496
> web www.chreos.com
>
> Wild Software Ltd

Rob,

I have never seen a situation where willy nilly DDL changes are
possible by the customer except by poor design decision. That does not
mean that there is no such case, but possibly if you tell us what you
are trying to do, we may be able to come up with a method where
constant DDL changes are not required.

Also FB limits the number of times you can alter an object before it
gives some errors and you need to backup / restore.

Adam


>
>
>
> Alexandre Benson Smith wrote:
>
> >Robert martin wrote:
> >
> >
> >
> >>Hi
> >>
> >>We have an issue where clients can add their own custom fields to our
> >>database (any data type). They can also edit these field types, say
> >>changing from 10 to 15 chars.
> >>
> >>We have a problem where the alteration process causes an error due
to a
> >>stored procedure (and probably a view) that is based on the
particular
> >>field exists. Is there a way to
> >>
> >>a) Detect a dependency and not alter the field.
> >>b) Easily disable a stored procedure and later re-enable.
> >>
> >>TIA
> >>Rob
> >>
> >>
> >>
> >>
> >>
> >To detect the dependecie is easy ! just look on rdb$dependencies table.
> >
> >To recreate the SP is a bit more complex.. since the SP cuold have
other
> >SP's that depend on it and so on.
> >
> >You could alter the Sp to an empty body, and then recreate it.
> >
> >But I think it is a bit dangerous, what about if the SP has a declared
> >variable as varchar(10) and then your costumer change the field to
> >varchar(15) ? how would you detect this kind of change ?
> >
> >see you !
> >
> >
> >
>
>
> [Non-text portions of this message have been removed]
>