Viewing 15 posts - 3,256 through 3,270 (of 7,614 total)
Wouldn't you want to do that the other way? That is, find rows where the previous row matches the next row -- i.e. no column changed -- so you could...
July 20, 2018 at 7:54 am
Use MS's free tool "tablediff.exe" and let them do this work for you, and fully tested already! Unfortunately quirky to get working initially, but works well after that, and it's...
July 18, 2018 at 12:19 pm
I didn't have any data to test with, but I'm reasonably sure my sort order is correct. As I think you've since discovered, the rows get out of order outside...
July 18, 2018 at 10:44 am
;WITH cte_EarliestShowDates AS (
SELECT Show, MIN(Date) AS EarliestShowDate
FROM dbo.TableName
GROUP BY Show
)
SELECT TN.*
FROM dbo.TableName TN
INNER JOIN cte_EarliestShowDates CESD...
July 17, 2018 at 3:01 pm
July 17, 2018 at 12:54 pm
right now deletes the current and previous month, where the table holds 2.5 yrs of data. These tables currently do not have any keys, constraints o[r] indexes.
Cluster...
July 17, 2018 at 11:40 am
When you add the keyword, you're probably preventing the physical shrinking. If you really want to shrink, just shrink:
DBCC SHRINKFILE (N'prod1', 0)
I wouldn't use 0 personally...
July 17, 2018 at 11:35 am
set ansi_nulls off
I'm trying to find a way to avoid having to use isnull() or coalesce() everywhere in my script in order to avoid counterintuitive null comparison results...
July 17, 2018 at 11:31 am
July 17, 2018 at 8:18 am
I swear I posted this already (somewhere at least!, another SQL help site perhaps?), but I'll post it here too just in case:
SELECT EmployeeInformationID, COUNT(*)...
July 13, 2018 at 3:37 pm
Thanks for all of your input, folks.
@ScottPletcher , I'm able to somewhat understand your solution,...
July 12, 2018 at 12:53 pm
July 12, 2018 at 12:35 pm
Although not considered "standard", I prefer this approach because (1) the FETCH only has to be written once (can't count the number of times someone changes only one FETCH when...
July 12, 2018 at 11:00 am
Rather than repeatedly having to identity the post code, add an AFTER INSERT, UPDATE trigger that finds the post code and then store its byte location and length in a...
July 12, 2018 at 10:55 am
The way I read it, you could have letters on both the front and the back of the string. This CASE code handles that situation as well:
[code...
July 12, 2018 at 10:25 am
Viewing 15 posts - 3,256 through 3,270 (of 7,614 total)