Difference between revisions of "SQL Error Messages"
From SQLZOO
| Line 16: | Line 16: | ||
</ul><ul> | </ul><ul> | ||
</ul><h2>SQL Server</h2><ul> | </ul><h2>SQL Server</h2><ul> | ||
| − | <li> | + | <li> [[Ambigous column name |Msg 1013, Ambiguous column name 'name'.]] |
| − | Msg 1013, | + | </li> |
| − | Ambiguous column name 'name'. | + | |
| − | + | ||
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li>[[Invalid Group function |Msg 147 An aggregate may not appear in the WHERE clause unless it is in a subquery contained in a HAVING clause or a select list, and the column being aggregated is an outer reference.]]</li> |
</ul><ul> | </ul><ul> | ||
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li>[[Table doesn't exist |Msg 208 Invalid object name 'noSuchTable']]</li> |
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li> [[Incorrect GROUP BY |IMsg 8120 Column 'xxx' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause. (SQL-42000)]]</li> |
| − | + | ||
| − | Column 'xxx' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause. (SQL-42000) | + | |
</ul><h2>Oracle</h2><ul> | </ul><h2>Oracle</h2><ul> | ||
| − | <li> | + | <li>[[Ambigous column name |ORA-00918: column ambiguously defined]]</li> |
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li>[[Invalid Group function |ORA-00934: group function is not allowed here]]</li> |
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li>[[No Group By Function |ORA-00937: not a single-group group function]]</li> |
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li>[[Table doesn't exist |ORA-00942: table or view does not exist]]</li> |
</ul><ul> | </ul><ul> | ||
| − | <li> | + | <li>[[Incorrect GROUP BY |ORA-00979: not a GROUP BY expression]]</li> |
</ul><h2>DB2</h2><ul> | </ul><h2>DB2</h2><ul> | ||
| − | <li> | + | <li>[[Ambigous column name |SQL0203N A reference to column "NAME" is ambiguous. SQLSTATE=42702]] |
| − | SQL0203N A reference to column "NAME" is ambiguous. SQLSTATE=42702 | + | </li> |
| − | + | ||
</ul><ul> | </ul><ul> | ||
<li><a href='err934/db2'>SQL0120N A WHERE clause, GROUP BY clause, SET clause, or SET transition-variable statement contains a column function. | <li><a href='err934/db2'>SQL0120N A WHERE clause, GROUP BY clause, SET clause, or SET transition-variable statement contains a column function. | ||
Revision as of 11:13, 19 July 2012
Contents |
Error Messages
Error messages, how they are caused and what can be done about them.
MySQL
SQL Server
Oracle
DB2
- <a href='err934/db2'>SQL0120N A WHERE clause, GROUP BY clause, SET clause, or SET transition-variable statement contains a column function. </a>
- <a href='err942/db2'>SQL0204N "GISQ.NOSUCHTABLE" is an undefined name</a>
- <a href='err979/db2'>SQL0119N An expression starting with "xxx" specified in a SELECT clause, HAVING clause, or ORDER BY clause is not specified in the GROUP BY clause or it is in a SELECT clause, HAVING clause, or ORDER BY clause with a column function and no GROUP BY clause is specified. SQLSTATE=42803</a>
Postgres
- <a href='err918/postgres'> Error 7 ERROR: Column reference "name" is ambiguous </a>
- <a href='err934/postgres'>ERROR: Aggregates not allowed in WHERE clause</a>
- <a href='err942/postgres'>ERROR: Relation "nosuchtable" does not exist</a>
- <a href='err979/postgres'>Error 7 ERROR: Attribute xxx.xxx must be GROUPed or used in an aggregate function</a>