Viewing 15 posts - 4,861 through 4,875 (of 59,101 total)
SELECT DATEADD(DAY, -DATEDIFF(DAY, 0, [Order Date]) % 7, [Order Date]) AS [Week of],
COUNT(*) AS Count
FROM dbo.your_table_name
GROUP BY DATEADD(DAY, -DATEDIFF(DAY, 0, [Order Date]) % 7, [Order Date])
Welcome aboard! ...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 15, 2021 at 5:04 pm
I will always prefer someone that spends also time in participating in such discussions then someone that doesn't participate.
You mean like virtually everyone on StackOverflow where such discussions...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 15, 2021 at 4:13 pm
Could you post the CREATE TABLE statement for your date table? I'd like to try a couple of things.
--Jeff Moden
Change is inevitable... Change for the better is not.
August 15, 2021 at 3:47 pm
The easiest way is to have whatever image you want in your clipboard. Then, move your cursor to where you want you image to be and do a single click...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 15, 2021 at 8:00 am
That's nice. Again, please read and heed the first link in my signature line below for how to present some readily consumable data so that one of us can write...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 15, 2021 at 6:37 am
SELECT DATEADD(DAY, -DATEDIFF(DAY, 0, [Order Date]) % 7, [Order Date]) AS [Week of],
COUNT(*) AS Count
FROM dbo.your_table_name
GROUP BY DATEADD(DAY, -DATEDIFF(DAY, 0, [Order Date]) % 7,...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 14, 2021 at 7:14 pm
Welp, it seems worthwhile mentioning reputation points in an online forum, i.e. Stack Overflow, are a good way to enhance your resume.
They're also a good way to...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 14, 2021 at 7:09 pm
Not confusing for me. You have existing data and you have new data. He want's a way to compare the data that changed.
I do absolutely agree that he needs to...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 14, 2021 at 7:02 pm
small sample of data, and the output desired.
Row 2 is written as a delta to a new table since acctgrp and channel changed.
Output: Old:display yesterday's record New:display today's record
Just...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 14, 2021 at 1:12 am
My table as a PK(unique) of:
[InvoiceNbr] ASC, [Line] ASC, [SubLine] ASC, [InvoiceDate] ASC, [ShipDate] ASC
The process that creates the file to load to SQL does a FULL refresh of...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 13, 2021 at 3:29 pm
any examples of a compare script and output diff's?
Thanks.
There are many ways to display the "Diffs". Please provide and explicit example of what you'd like to see for your...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 13, 2021 at 1:40 pm
I'd prefer to split the file normally, with simple delimiter '|'.
After it's done we can manipulate the resulting data set to shuffle the items into proper slots, defined by...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 13, 2021 at 12:26 pm
I'm thinking the OP may have gotten an answer from somewhere else and so may no longer be interest in an answer from this thread and certainly not one where...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 13, 2021 at 4:06 am
Hi Jeff.
your tally table approach to parsing is the best i've seen. i have a real world problem; wondering if you have any thoughts.
i need to parse a large...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 13, 2021 at 3:18 am
Exceptionally busy next few days coming, but I did rebuild this morning, set a trace, and did check once to find 0.04% fragmentation - not the usual leap to...
--Jeff Moden
Change is inevitable... Change for the better is not.
August 11, 2021 at 5:24 pm
Viewing 15 posts - 4,861 through 4,875 (of 59,101 total)