Are you trying to do this within a programming language?  I use similar
queries using PHP and have no problem.  Although I would write my query
like:

SELECT tbl_name FROM user_table WHERE user = 'guy';

And then use the result to run a select, update, insert, or whatever

-Dan

On Sun, 2003-07-13 at 13:01, Shawn McGinn wrote:
> I would like to select data from a table where the table name is located
> in another table, and I am using the following query:
> 
> select t1.* from (select tbl_name from user_table where user="guy") t1;
> 
> This should return the data from table 'tbl_name', but I only get
> results from the subquery (ie. the query as a whole returns 'tbl_name',
> not it's contents)  Where am I going wrong?
> 
> I am using version 4.1.0-alpha-standard.
> 
> Shawn
> 
> 
> -- 
> Shawn McGinn <[EMAIL PROTECTED]>
> UNB
> 


-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to