tech user wrote:
Add an alias for the subquery
select * from ( select ) my_alias where dd = 3;
Better, use a having clause and eliminate the subquery. Odds are it
will be more efficient in MySQL.
How to replace the original one with a having statement?
Thanks again.
hello,
I try to execute this sql in mysql shell,but got error as:
mysql select * from (select uin,count(*) as dd from active_users where
date = date_add(curdate(),interval -30 day) group by uin) where dd =3;
ERROR 1248 (42000): Every derived table must have its own alias
But I can execute
tech user wrote:
hello,
I try to execute this sql in mysql shell,but got error as:
mysql select * from (select uin,count(*) as dd from active_users where
date = date_add(curdate(),interval -30 day) group by uin) where dd =3;
ERROR 1248 (42000): Every derived table must have its own alias
Add an alias for the subquery
select * from ( select ) my_alias where dd = 3;
Better, use a having clause and eliminate the subquery. Odds are it
will be more efficient in MySQL.
How to replace the original one with a having statement?
Thanks again.
Get the name you
PROTECTED]
To: mysql@lists.mysql.com
Sent: Monday, October 24, 2005 11:43 PM
Subject: Help needed for SQL statement
Hi,
I have such a situation:
There is a table with gene_ids and clone_ids. Each gene only resides on a
single clone and each clone may contain multiple genes. How do would I
Hi,
I have such a situation:
There is a table with gene_ids and clone_ids. Each gene only resides on a
single clone and each clone may contain multiple genes. How do would I
find how many genes are on each and every clone?
Thanks in advance.
X.Chen
--
MySQL General Mailing List
For list
Thanks for everyone's help with the dat question now I would like to know if
someone could help me with another question.
I have a table called COUNTER and a field in the table called HITS in an SQL
statement I would like to update this field by adding 1 to it's current
value any ideas?
Thanks,