Viewing 15 posts - 1,111 through 1,125 (of 6,036 total)
DesNorton (10/12/2016)
Sergiy (10/12/2016)
ALTER VIEW vSeedData
AS
SELECT RAND(CHECKSUM(NEWID())) Seed
GO
alter FUNCTION [GenerateRandomDateTime]
(
@MinimumDate DATETIME,
@MaximumDayDifference INT,
@MaximumSecondsFromMidnight INT
) RETURNS DATETIME
BEGIN
RETURN(SELECT TOP 1 DATEADD(DAY, Seed * ISNULL(@MaximumDayDifference, 365), @MinimumDate) + DATEADD(SECOND,...
October 12, 2016 at 11:59 pm
Alaster07 (10/12/2016)
CREATE VIEW...
October 12, 2016 at 7:00 pm
Alaster07 (10/12/2016)
October 12, 2016 at 3:28 pm
asita (10/12/2016)
I have a procedure that is scheduled to run on sql server and some adhoc code that I am executing,
both is kind of same logic but diferent purpose,...
October 12, 2016 at 3:22 pm
To do it all in one query you may use GROUP BY ... WITH ROLLUP.
In the row with GROUPING(Column1) = 1 you concatenate COUNT(*) , GETDATE() and whatever else you...
October 12, 2016 at 3:18 pm
Yuri55 (10/11/2016)
October 12, 2016 at 12:04 am
MickyD (9/15/2016)
I recently came across a dev database in our organization that had no clustered indexes and circa 100 million row.....:crazy:
In order to rectify I need some advice on...
October 11, 2016 at 9:47 pm
On Prod there must be some concurrent activity which is surely absent in DEV.
Did you check for blocking?
October 11, 2016 at 9:30 pm
You may add ROW_NUMBER to the recordset being inserted and add its values to MAX (ID ) of the table:
begin transaction
declare @MaxID bigint
select @MaxID + MAX(ID) From TargetTable (TABLOCKX)
INSERT INTO...
October 11, 2016 at 3:14 pm
Chrissy321 (10/10/2016)
Yes I do need to check if the job has reached its scheduled kickoff time.WHERE JobStartTime < CONVERT(TIME,GETDATE())
For a job scheduled to start on 23:59 this condition will never...
October 10, 2016 at 9:51 pm
valeryk2000 (10/7/2016)
October 10, 2016 at 4:25 pm
Chrissy321 (10/10/2016)
October 10, 2016 at 2:02 pm
vfn (10/9/2016)
error:Column PupilPersonalDetails.Forename is invalid in the select list because it is not contained in either an aggregate function or the GROUP BY Clause
helllpppp
That's right.
If you want to display...
October 9, 2016 at 6:57 pm
Matt Miller (#4) (10/5/2016)
Sergiy (10/5/2016)
Matt Miller (#4)
Don't forget to incorporate the "sliding window" into your production version of this. In other words - if you're trying to capture all...
October 6, 2016 at 2:21 am
drew.allen (10/5/2016)
How about just changing the declaration of @StartTime2 to SMALLDATETIME?Drew
How about not splitting date and time for StartDateTime?
😀
October 5, 2016 at 4:00 pm
Viewing 15 posts - 1,111 through 1,125 (of 6,036 total)