CFF KB - Carrz-Fox-Fire Promotions Knowledge Base
CFF KB is all about 1 thing: The Sharing of Knowledge and the Power we gain from it.Knowledge Base
- Breadrumbs:
Only one expression can be specified in the select list when the subquery is not introduced with EXISTS.
- Article ID:
215 - Date Created
Sunday, April 2, 2017 - This Article Has been Viewed
1582 times - Short Desc
Inner Select statements with two many expressions will cause an error. - Details
When creating an inner select statement inside of your existing select statement, you may sometimes add in two many columns, thus causing the following error to occur.Msg 116, Level 16, State 1, Line 1
Only one expression can be specified in the select list when the subquery is not introduced with EXISTS. - Recreate Issue
To recreate this issue:<%
Select (Select column1, column2 from table 1 where column1=table2.column1)as MyColumn, Table2.Column1, Table2.Column2
%>
In the above example, we see that there are two columns being called in the INNER Select statement. This will cause this error. - Resolve Issue
To Resolve this issue:<%
Select (Select column2 from table 1 where column1=table2.column1)as MyColumn, Table2.Column1, Table2.Column2
%>
In the above statement, we removed the column of which the Query us being called, and only leaving the Column, in this case. Column2, to be utilized in our page.
Share With Friends (Updated 6-8-2010)
Recent Articles
All Topics
- Coming Soon - Knowledge Exchange
Trending Articles
- Microsoft VBScript runtime error '800a0046' Permission denied FileSystemObject 24695
- Microsoft OLE DB Provider for SQL Server error '80040e57' String or binary data would be truncated. or The field is too small to accept the amount of data you attempted to add. Try inserting or pasting less data. 21297
- ADODB.Parameters error '800a0e7c' Parameter object is improperly defined 19545
- After Effects warning: Audio conforming failed for the following file .cfa. Perhaps due to disk space 17785
- The backup set holds a backup of a database other than the existing 16826