Viewing 15 posts - 2,971 through 2,985 (of 3,957 total)
As the OP indicated he already has this in a temp table, why not add a column (status) and do it with a quirky update?
CREATE TABLE #Temp
...
August 23, 2012 at 11:54 pm
Let's try a small test harness, shall we:
CREATE TABLE #Test
(ID int NOT NULL IDENTITY(1,1) Primary key,
TranID int NOT NULL,
OriginCode varchar(10) NOT NULL,
DestinationCode varchar(10) NOT NULL
...
August 23, 2012 at 11:11 pm
I think this is another way not yet suggested.
SELECT TranID,
(
SELECT OriginCode + ''
...
August 23, 2012 at 10:46 pm
Lynn Pettis (8/23/2012)
sandeep rawat (8/23/2012)
table deftable
(
price int,
typeofpen varchar (20)
)
query
-----
,WITH Temp AS
(MAX(price ) OVER(PARTITION BY typeofpen) AS price
FROM
table
)
SELECT SUM(mx) FROM temp
Curious, this doesn't even...
August 23, 2012 at 7:54 pm
dwain.c (8/22/2012)
Jeff Moden (8/22/2012)
dwain.c (8/21/2012)
If I rewrite this SP to use 1 or 0 CURSORs, will the SQL-verse acknowledge this reduction in my career CURSOR usage and lower my career...
August 22, 2012 at 11:53 pm
Jeff Moden (8/22/2012)
dwain.c (8/21/2012)
If I rewrite this SP to use 1 or 0 CURSORs, will the SQL-verse acknowledge this reduction in my career CURSOR usage and lower my career total...
August 22, 2012 at 8:36 pm
Jeff Moden (8/22/2012)
dwain.c (8/21/2012)
I have written some WHILE loops but they don't count.
Why not? If you're While loops process just one row at a time, they're just as bad...
August 22, 2012 at 8:34 pm
Can't tell if this is more efficient or not (it may not be according to the execution plan) because there's not enough records in the sample data, but you may...
August 22, 2012 at 7:38 pm
ChrisM@Work (8/22/2012)
Stefan Krzywicki (8/22/2012)
Brandie Tarvin (8/22/2012)
ChrisM@Work (8/22/2012)
Brandie Tarvin (8/22/2012)
August 22, 2012 at 6:46 pm
Grant Fritchey (8/22/2012)
GilaMonster (8/22/2012)
Grrr. Why do some people want to nitpick holes in things I say and do it in a way that sounds very much like a personal attack?
Same...
August 22, 2012 at 3:09 am
dwain.c (8/22/2012)
ChrisM@Work (8/22/2012)
dwain.c (8/22/2012)
ChrisM@Work (8/22/2012)
If this is the same individual as last timeHe who must not be named...
Between wizards and Jedi, this board is always interesting and fun... 🙂
Dwain,...
August 22, 2012 at 2:53 am
ChrisM@Work (8/22/2012)
dwain.c (8/22/2012)
ChrisM@Work (8/22/2012)
If this is the same individual as last timeHe who must not be named...
Between wizards and Jedi, this board is always interesting and fun... 🙂
Dwain, that...
August 22, 2012 at 2:26 am
ChrisM@Work (8/22/2012)
If this is the same individual as last time
He who must not be named...
Between wizards and Jedi, this board is always interesting and fun... 🙂
August 22, 2012 at 2:03 am
Use Jeff Moden's DelimitedSplit8K FUNCTION WHERE item = 2.
You can find that by searching on the FUNCTION's name.
August 22, 2012 at 1:12 am
I don't see the EStatus column defined in the Enroll table:
SELECT GETDATE() AS Runtime
,Enroll.Prog_Code AS PVCode
,COUNT(DISTINCT Enroll.Stud_ID) AS StatCount
,Enroll.Campus AS Campus
,'Current Entering Class' AS StatCategory
,'Today' AS StatPeriod
,'AppCycle' AS StatType
FROM Enroll
WHERE...
August 21, 2012 at 9:49 pm
Viewing 15 posts - 2,971 through 2,985 (of 3,957 total)