Re: dynamic column name

From: Jim Kennedy <kennedy-family_at_attbi.com>
Date: Fri, 10 May 2002 14:31:06 GMT
Message-ID: <KQQC8.6366$L76.110_at_rwcrnsc53>


You can
select * from (select column from columns where column like '%TEST') where ...
That might not be what you want.
Otherwise write sql to write sql.
Jim
"M Green" <machiel2000_at_spam.home.nl> wrote in message news:0cKC8.212635$oI.14514377_at_zwoll1.home.nl...
> Hi All,
>
> I've looked around for the answer to my question but couldn't find a
> straight answer.
>
> Question:
> Can I use the result of a query as the column name in another query?
>
> Something like:
> SELECT (SELECT column FROM columns WHERE column like '%TEST') FROM table
>
> Thanks very much!
> Mick Green
>
>
Received on Fri May 10 2002 - 16:31:06 CEST

Original text of this message