I am Using SQL SERVER 2008 R2 I just came across APPLY in SQL and loved how it solves query problems for so many cases, Many of the tables I was using 2 left join to get the result, I was able to ...
CROSS APPLY giving 'incorrect syntax' error on one SQL Server 2008 R2 database, with compat level = 100?
I'm copying a stored procedure from a test database to a production one. Both are on SQL 2008 R2 servers, but test has SP 2 installed and prod is still RTM. The same CREATE PROCEDURE code will run ...
I would like to run a query very similar to this on one of my production databases: -- Setup the table (Already there in my real scenario) create table dbo.MyTable(MyValue int, MyGroup varchar(5)) ...
I have a query that returns results like this: MyValue MyGroup _______________|_______________ 56 | I _______________|_______________ 12 | I ...
I have three relevent tables: Parts, PartGroup, and MarkupGroup. Parts is simple. PartID artificial primary key Part part number PartGroupID Foreign key sample data: 1 ...
I have a table like this VM1 SPLA - WINSVRSTD #P19-9999 QTY 1 VM2 SPLA - WINS ST #P29-9 9 QTY 2 : SPLA - WINSVRENTAAA #P39- 9 9 99 QTY 3:SPLA - WINS ST #P29-9 9 QTY 2 : SPLA - WINSVRENTAAA ...