RE: Getting the database name of a given table?
Posted in 2010
Damn!
Mike beat me to it.
Now I really feel stoopid. Maybe now my IQ has dropped enough that I should apply for the role of WW Informix Sales?
> From: iiug@aubit.com
> To: informix-list@iiug.org
> Subject: Re: Getting the database name of a given table?
> Date: Fri, 19 Mar 2010 12:55:03 +0000
>
> Am I missing something ?
>
> Isn't it just :
> SELECT "db1" dbname, some_cols FROM DB1:atable UNION
> SELECT "db2", some_cols FROM DB2:atable UNION
> SELECT "db3", some_cols FROM DB3:atable
>
>
> On Friday 19 March 2010 11:40:05 David N. Heydon wrote:
> > Hi All.
> >
> > If I have a piece of SQL like:-
> >
> > SELECT some_cols FROM DB1:atable UNION
> > SELECT some_cols FROM DB2:atable UNION
> > SELECT some_cols FROM DB3:atable> >
> > How can I also return as a column the database the row matches so I can
> > differentiate between DB1, DB2 and DB3 in the above example?
> >
> > I've tried a few things but no success so far. Any inspiration appreciated!
> >
> > TIA.
> >
> > David
> > _______________________________________________
> > Informix-list mailing list
> > Informix-list@iiug.org
> > http://www.iiug.org/mailman/listinfo/informix-list
>
> --
> Mike Aubury
>
> http://www.aubit.com/
> Aubit Computing Ltd is registered in England and Wales, Number: 3112827
> Registered Address : Clayton House,59 Piccadilly,Manchester,M1 2AQ
>
>
>
> _______________________________________________
> Informix-list mailing list
> Informix-list@iiug.org
> http://www.iiug.org/mailman/listinfo/informix-list
_________________________________________________________________
Hotmail is redefining busy with tools for the New Busy. Get more from your inbox.
http://www.windowslive.com/campaign/thenewbusy?ocid=PID27925::T:WLMTAGL:ON:WL:en-US:WM_HMP:032010_2