I'm writing a function for Perl module I'm writing that will allow you to do

$query = "SELECT".DBIallexcept($dbh,'fred','wilma')."FROM monkey";

If that will help. Let em know and I'll notify you when it's done.

Thanks

Dan


>> 
> As Victoria says, you can't. However I agree that this syntax 
> is useless in many real-world situations. You are not the 
> only one who finds this behaviour annoying. It's about time 
> someone made SQL a 21st century language...
> 
> 
> 
> "Miroslav I." wrote:
> > 
> > Hallo
> > 
> > suppose you have a table with great number of columns (20 
> or 30), and 
> > you would like to specify every one but two or tree columns in a 
> > SELECT statement.
> > 
> > Is there a way to specify only those two or tree columns 
> for omission 
> > (which would be the 'short' way to do the job) instead of 
> specifying 
> > every column that needed (which would be the 'long' way to do the 
> > job).
> > 
> > Example:
> > 
> > The 'TName' table header:
> > 
> > id | name | surname | dateOB | idSCHOOL | idCITY | idSTATE | sex | 
> > idParent1 | idParent2 | interests | weight | height | age | 
> auditDate 
> > | idAudittor |  ....
> > 
> > You need every field except the 'dateOB' and 'idSCHOOL'
> > 
> > Ordinary select wold be:
> > 
> > SELECT 
> > 
> id,name,surname,idCITY,idSTATE,sex,idParent1,idParent2,interests,weigh
> > t,height,age,auditDate,idAudittor, .... FROM TName
> > 
> > It is too long expression,
> > is there a way to specify only 'dateOB' and 'idSCHOOL' - the two 
> > column that are unwanted in the result set - in order to make the 
> > SELECT shorter? The SELECT should return every column but the 
> > specified ones.
> 
> -- 
> MySQL General Mailing List
> For list archives: http://lists.mysql.com/mysql
> To unsubscribe:    
> http://lists.mysql.com/mysql?> [EMAIL PROTECTED]
> 
> 

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

Reply via email to