Subject | Re: [firebird-support] foreign key strangeness |
---|---|
Author | Martijn Tonies |
Post date | 2003-11-24T15:58:52Z |
Hi Dmitry,
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird, MySQL & MS SQL
Server.
Upscene Productions
http://www.upscene.com
> > > Both ;-) And I tend to fix this in the next FB release.the
> >
> > Out of curiosity: exactly what part is the issue? And what part
> > is by design? :)
>
> By design, no checks are made to validate the datatype compatibility for
> both parther indices. And exactly this fact is the issue too ;-)is
> > Meaning: can't I create an FK from an Integer to a VARCHAR
> > containing integers?
>
> The standard says that both datatypes should be comparable. Since VARCHAR
> comparable with [almost[ everything, it seems you should be able to dothat.
> But I don't see much value in such FKs. And it definitely leads to somethis
> types of weird errors or even data corruptions. Hence I tend to disable
> possibilty.So Firebird will not follow the standard here?
With regards,
Martijn Tonies
Database Workbench - developer tool for InterBase, Firebird, MySQL & MS SQL
Server.
Upscene Productions
http://www.upscene.com