This is a discussion on iterating over fetched tablenames ? within the MySQL forums, part of the Database Server Software category; --> Hello, I have a question: I fetch a list of tablenames from table `properties' and I would like to ...
| |||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
| ||||
| Hello, I have a question: I fetch a list of tablenames from table `properties' and I would like to execute a select query on the tablenames that are returned. My question is; is this possible in one querry ? For example [this doesn't work mysql> (SELECT tblname FROM properties) UNION (SELECT * from tblname.afield ORDER BY date DESC LIMIT 1); ERROR 1146 (42S02): Table 'properties.tblname' doesn't exist If someone could tell me if this is possible, or should I ? Use multiple querries ? etc... Thank you. hc. |