Subject | Re: Read-Only Distribution and Views |
---|---|
Author | Svein Erling |
Post date | 2003-11-13T09:59:29Z |
--- In firebird-support@yahoogroups.com, Uwe Oeder <uweo@c...> wrote:
1st Select : SELECT <fieldlist> from TableA T1
where T1.FieldA = 'Voff'
2nd Select : SELECT <fieldlist> from TableA T2
where T2.FieldB = 'Mjau' AND EXISTS(
SELECT * from TableA T1 where T1.FieldA = 'Voff' AND T1.PK = T2.PK)
3rd Select : SELECT <fieldlist> from TableA T3
where T3.FieldC = 'Pip' AND EXISTS(SELECT * from TableA T2
where T2.FieldB = 'Mjau' AND T2.PK = T1.PK AND EXISTS(
SELECT * from TableA T1 where T1.FieldA = 'Voff' AND T1.PK = T2.PK))
then yes, it should be (theoretically) possible. Though there are
probably better ways to go about such a problem - like using the
searching possibilities with IBO (I do not know the other suites).
Set
> Does firebird have any support for memory objects(tabls,views,Well, if you mean
> cursors) ? If not. If I use subqueries with exist statements , could
> that simulate views ?
>
> View1
> |--> View2
> |--> View 3
>
> Would that be equal to :
>
> 1st Select : Select Condition1
> 2nd Select : Select Condition2 If Exists (Condition1)
> 3rd Select : Select Condition3 If Exists( Select Condition2 If
> Exists (Condition1) )
>
> Could this be a possible workaround ?
1st Select : SELECT <fieldlist> from TableA T1
where T1.FieldA = 'Voff'
2nd Select : SELECT <fieldlist> from TableA T2
where T2.FieldB = 'Mjau' AND EXISTS(
SELECT * from TableA T1 where T1.FieldA = 'Voff' AND T1.PK = T2.PK)
3rd Select : SELECT <fieldlist> from TableA T3
where T3.FieldC = 'Pip' AND EXISTS(SELECT * from TableA T2
where T2.FieldB = 'Mjau' AND T2.PK = T1.PK AND EXISTS(
SELECT * from TableA T1 where T1.FieldA = 'Voff' AND T1.PK = T2.PK))
then yes, it should be (theoretically) possible. Though there are
probably better ways to go about such a problem - like using the
searching possibilities with IBO (I do not know the other suites).
Set