Viewing 15 posts - 3,301 through 3,315 (of 5,590 total)
keymoo - thanks for providing the excellent sample data, table definitions, and desired output. Without it, I think you'd still be waiting for a solution.
September 8, 2010 at 9:40 am
Chris Morris-439714 (9/8/2010)
WayneS (9/8/2010)
September 8, 2010 at 9:36 am
Here's my solution. I took a similar approach that Chris did to make a row for each unit, but how we did that is different (I'm using a tally table...
September 8, 2010 at 9:23 am
LutzM (9/8/2010)
call4ljw (9/8/2010)
Editted accordingly...Not really....
Sample data in a ready to use format and expected result, please.
Something like:
CREATE TABLE Book (BookID int....)
CREATE TABLE Borrow (BookID int, ...)
INSERT INTO Book --...
September 8, 2010 at 7:55 am
GilaMonster (9/8/2010)
WayneS (9/8/2010)
Would this affect the recovery time of the database? Would it affect it to this extent?
Shouldn't and no.
Recovery just needs the active portion of the log, the...
September 8, 2010 at 7:51 am
richard.kirby (9/7/2010)
Thanks John - I've never heard of 'Except' but I'll look it up.Cheers
Richard,
Here's an example, using your provided code:
--Top select
SELECT ClientID,ReferralNumber,AppointmentDate,ActualTime
--,Count(*)
FROM dbo.vwBRSAppointmentsNPD
WHERE SpecialtyReferredTo='ICNR'
AND AppointmentContactCancellationDateTime IS NULL
AND AppointmentDate between...
September 8, 2010 at 7:48 am
Grant Fritchey (9/8/2010)
WayneS (9/7/2010)
Steve Jones - Editor (9/7/2010)
WayneS (9/7/2010)
Looks like Lutz is having to pull teeth to get the OP to read how to help himself out.
Actually I picture Lutz...
September 8, 2010 at 7:37 am
vrkn82 (9/8/2010)
September 8, 2010 at 5:34 am
GilaMonster (9/8/2010)
As I said, poor IO performance (which you confirmed was the case) and log fragmentation are the main causes of long database recovery.
I'm speculating here... if the database was...
September 8, 2010 at 5:27 am
You're setting @Month = '20100801'
Then, in you're doing:
BASE.SERVICE_YR_MO BETWEEN CONVERT(CHAR(6),DATEADD(M,-24,CONVERT(datetime,@MONTH + '01',112)),112) AND @MONTH
AND
BASE.PAID_YR_MO BETWEEN CONVERT(CHAR(6),DATEADD(M,-15,CONVERT(datetime,@MONTH + '01',112)),112) AND @MONTH
Adding the string '01' to '20100801' gives you '2010080101', which is...
September 7, 2010 at 8:47 pm
This looks okay - as long as you're doing it in the font color property?
September 7, 2010 at 8:43 pm
Megistal (9/7/2010)
CREATE TABLE tab1 (
ID INT Identity(1,1)
, Col1 int
)
INSERT INTO tab1
SELECT Col1 FROM tab2
Does it guaranteed me that new rows inserted in...
September 7, 2010 at 5:33 pm
Steve Jones - Editor (9/7/2010)
WayneS (9/7/2010)
Looks like Lutz is having to pull teeth to get the OP to read how to help himself out.Actually I picture Lutz as Wayne's avatar.
The...
September 7, 2010 at 5:26 pm
jcrawf02 (9/7/2010)
LutzM (9/7/2010)
Steve Jones - Editor (9/7/2010)
WayneS (9/7/2010)
Looks like Lutz is having to pull teeth to get the OP to read how to help himself out.
Actually I picture Lutz as...
September 7, 2010 at 4:54 pm
Viewing 15 posts - 3,301 through 3,315 (of 5,590 total)