Viewing 15 posts - 1,066 through 1,080 (of 7,608 total)
Thanks for the answer,
We already have views on top of our tables, so it would be easy to do. But that would serve no purpose. The main goal would...
January 5, 2022 at 2:31 pm
Going from 28 to 19 would reduce the storage required, so, as you've discovered, I think SQL would create a new column and copy the data over to it.
If you...
January 5, 2022 at 12:09 am
SELECT ca1.*
FROM dbo.Table1 t1
CROSS APPLY (
SELECT EmpNo, EmpName, DeptName, Location
UNION ALL
SELECT EmpNo, EmpName, DeptName, Location
...
January 4, 2022 at 4:00 pm
CONCAT is not a safe way to do this because different values could appear to be the same.
Do all the columns have to match? Or just some?
For now, I'll assume...
January 3, 2022 at 9:55 pm
There could be a lot of different reasons for latency. Did this just start recently? Here are some possible things; (1) should be done first, the others are in no...
January 3, 2022 at 4:53 pm
We need to see the DDL for Clicks2 and Clicks3 as well. Particularly if those tables are not clustered uniquely on ClickID, the MERGE join could be less efficient.
As Jeffrey...
December 28, 2021 at 9:23 pm
For efficiency, you should really just scan the table once to count all columns, as the code generated below does. I've added the view name as input so the code...
December 27, 2021 at 6:50 pm
My favorite lie is that NOLOCK improves performance.
Of course it must vs taking locks.
"and use snapshot isolation." MEGA-HUGE overhead. SI should...
December 22, 2021 at 8:53 pm
My favorite lie is that NOLOCK improves performance.
Of course it must vs taking locks.
"and use snapshot isolation." MEGA-HUGE overhead. SI should only be...
December 22, 2021 at 6:48 pm
My favorite lie is that NOLOCK improves performance.
Of course it must vs taking locks.
"and use snapshot isolation." MEGA-HUGE overhead. SI should only be used when...
December 22, 2021 at 5:14 pm
"Switching to alphanumeric" from what? Int, bigint? If so, have you used negative numbers yet? Typically the quick-and-dirty way to stretch values is to use the full range of negative numbers. ...
December 22, 2021 at 4:41 pm
And, in never changing historical data, this is read only. Use a read only connection, and use snapshot isolation.
You can't use a "read-only connection" in/for a proc that does...
December 22, 2021 at 4:39 pm
My favorite lie is that NOLOCK improves performance.
Of course it must vs taking locks.
"and use snapshot isolation." MEGA-HUGE overhead. SI should only be used when truly necessary.
You need to...
December 22, 2021 at 4:22 pm
Yes, agree that it would benefit in the read loads. But we should also consider the overhead of CI on write operations. So if the database...
December 22, 2021 at 3:54 pm
It really depends on whether you understand the consequences of NOLOCK. It can result in a 'dirty read' if there are uncomitted transactions in the database that...
December 22, 2021 at 3:49 pm
Viewing 15 posts - 1,066 through 1,080 (of 7,608 total)