You are here: Re: mysql select help « PHP SQL « IT news, forums, messages
Re: mysql select help

Posted by IchBin on 09/09/06 19:08

Mikro wrote:
> Hi!
>
> What wrong on this clause?
>
> SELECT * from summad SUM(sum1+sum2+sum3) AS summa HAVING summa > sumall
>
> Tx for help
>
>
Do not know your table layout but you can not have a 'SUM' after the
FROM clause and before the 'HAVING' clause. You use the 'SUM' in either
your 'SELECT' statement or the 'Having' clause. Also you can not have a
'HAVING' clause without a 'GROUP BY' clause.

Look here:
http://www.techonthenet.com/sql/having.php

--
Thanks in Advance...
IchBin, Pocono Lake, Pa, USA http://weconsultants.phpnet.us
'If there is one, Knowledge is the "Fountain of Youth"'
-William E. Taylor, Regular Guy (1952-)

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация