Viewing 15 posts - 1,741 through 1,755 (of 10,144 total)
hoseam (2/17/2016)
Can I get different columns like 'Today', 'Yesterday', 'A day before Yesterday', '3 days prior Today' and '4 days prior Today'?
SELECT
[Today] = MAX(CASE WHEN rn = 5 THEN...
February 17, 2016 at 4:08 am
hoseam (2/17/2016)
I'm struggling to write a code to get five previous working days. I'm trying to get 'Today', 'Yesterday', 'A day before Yesterday', '3 days prior Today' and '4 days...
February 17, 2016 at 3:32 am
The dual-rownumber method is also promising:
DROP TABLE #Sample
CREATE TABLE #Sample (pkLocalPatientLocalID VARCHAR(2),pkSpellLocalID VARCHAR(3),WardLocation VARCHAR(20),WardSequence INT,RoomName VARCHAR(20),Bed INT,BedSequence INT,StartDateTime DATETIME,FinishDateTime DATETIME,[WardSequence Required] INT)
INSERT INTO #Sample
(pkLocalPatientLocalID,pkSpellLocalID,WardLocation, WardSequence,RoomName, Bed, BedSequence, StartDateTime, FinishDateTime,...
February 16, 2016 at 10:09 am
SQLRNNR (2/16/2016)
jasona.work (2/16/2016)
GilaMonster (2/16/2016)
Cthulhu for president! Why vote for the lesser evil?
I'm leaning towards the Palpatine / Vader ticket myself...
Or if they don't make it, Bill and Opus...
(I refuse to...
February 16, 2016 at 10:08 am
Lynn Pettis (2/16/2016)
February 16, 2016 at 9:02 am
GilaMonster (2/16/2016)
Cthulhu for president! Why vote for the lesser evil?
Cthulhu's already president - of the "other" united states.
February 16, 2016 at 7:59 am
-- the DISTINCT appears to be redundant, there were the same number of rows either side of the distinct sort operator.
SELECT
o.sys_key, -- "o" is the alias for table...
February 16, 2016 at 7:02 am
nadersam (2/16/2016)
This is a big table and accessed by most functions in system.
Is there anyway to reduce the count...
February 16, 2016 at 5:56 am
Orlando Colamatteo (2/15/2016)
February 16, 2016 at 4:42 am
Jeff Moden (2/15/2016)
TomThomson (2/15/2016)
Jeff Moden (2/15/2016)
Sean Lange (2/15/2016)
Grant Fritchey (2/15/2016)
Hugo Kornelis (2/15/2016)
jasona.work (2/15/2016)
How do you feel if someone comes back and tells you that they tested...
February 16, 2016 at 1:28 am
jasona.work (2/15/2016)
How do you feel if someone comes back and tells you that they tested a solution you provided before they told their bosses it was...
February 15, 2016 at 7:45 am
SQL!$@w$0ME (2/12/2016)
Thanks, Please see the actual plan attached.
1. Can you amend the index as suggested earlier?
2. Can you run it with sensible parameters such that it returns a result set?
February 12, 2016 at 7:25 am
SQL!$@w$0ME (2/12/2016)
Tks. I've attached the sqlplan.
Add ActivityDescription as an INCLUDE column to index [IX_Activity_ActivityCodeId_DeletedAt_CaseId_ActivityDate], it's currently showing as 78% of the total cost of the query and masking everything else....
February 12, 2016 at 7:12 am
SQL!$@w$0ME (2/12/2016)
Tks. I've attached the sqlplan.
That's the estimated plan. Can you post the actual plan please?
February 12, 2016 at 6:41 am
SQL!$@w$0ME (2/12/2016)
-- Stored Procedure
CREATE procedure [dbo].[PeerReviewsGet]
as
begin
select Review_tab.ReviewId CustomerReferralId,
Review_tab.ActivityId ReviewActivityId,
ImeEventDetail.Id ImeEventDetailId,
activity.Id ActivityId,
caseinfo.casenum as CaseNumber,
convert(varchar, ImeEventDetail.ImeEventId) + ImeEventDetail.Extension...
February 12, 2016 at 5:47 am
Viewing 15 posts - 1,741 through 1,755 (of 10,144 total)