Viewing 15 posts - 61 through 75 (of 760 total)
This is a slightly long approach.....but this is one way you can do it :
;With CTE
As
(
Select 1 As Number Union Select 2Union Select 3 Union Select 4
),...
April 2, 2013 at 3:30 am
May be this is what you are looking for:
;With CTE
As
(
SELECT DISTINCT 'International' Campus,28 'Weeks-2013',0 'Weeks-2012',2 'Student-2013',0 'Student-2012',0 StudentPrevYrTotal
UNION
SELECT DISTINCT 'International' Campus,32 'Weeks-2013',0 'Weeks-2012',1 'Student-2013',0 'Student-2012',0 StudentPrevYrTotal
UNION
SELECT DISTINCT 'International'...
April 2, 2013 at 12:30 am
Jeff Moden (3/30/2013)
vinu512 (3/28/2013)
Declare @sql Varchar(MAX)
-- Set up some test data
Create table product(ProductId Int, ProductName Varchar(30),CategoryID...
April 1, 2013 at 1:11 am
This is how you can transform Mickey's query into a Dynamic Cross tab:
Declare @sql Varchar(MAX)
-- Set up some test data
Create table product(ProductId Int, ProductName Varchar(30),CategoryID Int)
Create table category(CategoryID...
March 28, 2013 at 3:59 am
mickyT (3/25/2013)
select ProductID, ProductName, CategoryID, CategoryName, pp1.ProductQuantity, pp1.ProductCost,...
March 26, 2013 at 3:02 am
Cab you please be more precise on the logic behind the ordering.....If you simply want to
move and earlier number to a later number
then there can be a no....
March 26, 2013 at 2:30 am
Good job with the DDL and the required output, we are only missing the sample data now.....take your time and make a dummy sample data set that looks like or...
March 7, 2013 at 11:11 pm
The option is wrong....it is not necessary to have an Order By clause if Top is specified in a query.....it should be other way round.....Order By can only be specified...
March 7, 2013 at 9:45 pm
Brad Marsh (3/7/2013)
March 7, 2013 at 9:04 pm
Let me get this right....from what i understood....a user may have umpteen no. of comments and the comments could all b different so you cant group using the comments column....
March 7, 2013 at 1:46 am
Brad Marsh (3/6/2013)
March 6, 2013 at 11:45 pm
Oh shoot!!!...so much for typing so much 😀
Lynn posted while I was typing....
March 6, 2013 at 10:03 pm
Hello,
Since you have 20 points, I assume that you are not new here have a relative idea about posting data on forums. If you don't then there is a...
March 6, 2013 at 10:01 pm
Thanks Jason and Grant.
I did have a look at Sql Server Internals and even placed an order for it with Amazon. 😉
Till then I downloaded the ebook of...
February 27, 2013 at 9:06 pm
GilaMonster (2/27/2013)
vinu512 (2/27/2013)
Something that helped you in learning about this when you started.......would be great.I learnt mostly by write query, run query, analyse exec plan.
I am pretty much...
February 27, 2013 at 2:00 am
Viewing 15 posts - 61 through 75 (of 760 total)