Could someone please explain to me why the following query is invalid? I'm running this query against an Oracle 10g database.
select count(test.*) from my_table test;
I get the following error: ORA-01747: invalid user.table.column, table.column, or column specification
however, the following two queries are valid.
select count(test.column) from my_table test;
select test.* from my_table test;
MySQLandSQL Serverdon't support this syntax too. - QuassnoiCREATE TABLE t_count (id INT NOT NULL); SELECT COUNT(t_count.*) FROM t_count;. You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near '*) FROM t_count' at line 1 - QuassnoiSELECT COUNT(test.*) FROM MY_TABLE testfails - "Incorrect syntax near '*'" on SQL Server 2005. - OMG Ponies