I have a table (tbl_A) and a view (vw_B) -
This syntax works -
SELECT tbl_A.*
FROM tbl_A, vw_B WHERE tbl_A.ID = vw_B.ID
This syntax does not -
SELECT tbl_A.*
FROM tbl_A INNER JOIN vw_B ON tbl_A.ID = vw_B.ID
Any ideas ?
Thanks, Adrian
Thanks for the tip.
When I tried it I got the following error message
Column 'tbl.Quantity' is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY clause.
Any ideas ?
Thanks for your time, Adrian
I am converting some Access queries to be 'pass through' to a SQL Server backend. In Access there is a LAST function when running a GROUP BY query - is there an equivalent in SQL Server ?
eg table below has columns Type, Quantity & Date. I would like to group by Type, return the latest Date...
I am converting an Access system to have a SQL Server Backend. For performance reasons I want to convert queries to stored procedures & run them using pass through queries. In a pass through query I am using the syntax
EXEC sp_test (5)
which works fine. However I would like to pass a...
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.