Viewing 15 posts - 1 through 15 (of 161 total)
when I cast the values as VARBINARY(MAX) it works too.
TRUNCATE TABLE dbo.Image_Staging; TRUNCATE TABLE dbo.Images
INSERT INTO dbo.Images (imageid, imagestatus, imagemodified, imagebinary) VALUES (1, 1, GETDATE(), HASHBYTES('SHA2_512',...
November 11, 2024 at 9:30 am
Bad style of the query (I know, it is intended here, but you should never write it this way in real code).
Instead of
SELECT
c.CustomerName, COUNT(oh.OrderID)
...
November 6, 2024 at 12:17 pm
Nice solution.
Instead of combining LAG() and SUM() OVER you could have used just LAG - at least when it are just a fixed number of the last 4 entries. For...
September 30, 2024 at 4:11 pm
Producing a Year-2100-problem by setting 31.12.2099 as default valid_to date. Ensures the job for my great-grandkids or their AI.
September 21, 2024 at 12:34 pm
Sorry, but this script isn't really good in my opionion.
September 1, 2024 at 11:58 am
At a previous employer we used partition switching to do massive deletes.
when you already have partitions, you could simply do a
TRUNCATE TABLE dbo.big_stuff WITH (PARTITION(1 TO...
August 30, 2024 at 3:28 pm
I just wonder how this even could happen. Did all the companies not install the patches on the testing / dev environment before? And do they not have a cluster...
July 22, 2024 at 7:45 am
the problem is, that DATETIME is not an exact datatype (similar to float vs. decimal). DATETIME suppots only about 0.003 accuracy, so a DATETIME2 = '20240708 23:59:59.998' would be converted...
July 8, 2024 at 8:52 pm
The two statements in the chapter More details of JOINs are equal.
And both are wrong, since you need to put the SUM(o.Amount) > 1000 into the HAVING and not the...
July 8, 2024 at 8:20 am
Can't you use Redgate SQL Backup to do restores that are no longer possible with native SQL backups? I think, I did this some years ago with SQL 2005 to...
July 8, 2024 at 8:06 am
Still using SSMS 18.x since my second most important Addon (besides Redgate SQL Prompt) with the name SSMSBoost seems to be deprecated and there is no version that works with...
February 2, 2024 at 1:08 pm
With
SET ARITHABORT OFF; -- or ON, it doesn't matter
SET NUMERIC_ROUNDABORT OFF;
I will not get a warning (contrary to the explanation). But with NUMERIC_ROUNDABORT ON I will...
January 12, 2024 at 12:41 pm
Parthprajapati wrote:
Appreciate the feedback! While MIXED extents have limitations, they can still offer performance & storage benefits in specific cases like TEMPDB management. I'm open to further discussion & exploring...
January 10, 2024 at 4:08 pm
In my opinion this article was written by ChatGPT or another KI tool with no real knowlegde. Besides the errors mentioned by Uwe Ricken it is not more than a...
January 10, 2024 at 8:51 am
Regarding the fact, that people are fired but other companies can't find candidates:
Besides the skill mismatch problem it may be a quality problem too. The IT was booming the last...
January 5, 2024 at 11:33 am
Viewing 15 posts - 1 through 15 (of 161 total)