Viewing 15 posts - 1,486 through 1,500 (of 6,036 total)
MadAdmin (4/19/2016)
Select businessentityid from person.person where rtrim(lastname) like 'Smith%' --108 Reads What is happening here?
Select businessentityid from person.person where rtrim(lastname) like @var --4 Reads What is happening here?
last name is...
_____________
Code for TallyGenerator
April 20, 2016 at 4:11 pm
Chris-475469 (4/19/2016)
I'm not new to being a DBA, just new to my current role and have been given this process to look at.
The INSERT statements are the biggest offenders...
_____________
Code for TallyGenerator
April 19, 2016 at 9:39 pm
Simple EAV structure will be way more effective than dynamic schema or XML.
With appropriate indexing searching for a value in EAV structure will be much faster than in XML.
And more...
_____________
Code for TallyGenerator
April 19, 2016 at 6:13 pm
Jeff Moden (4/18/2016)
_____________
Code for TallyGenerator
April 19, 2016 at 12:00 am
INSERT INTO #temp1
SELECT S.samplepartnercode, S.samplePartnerIncId, S.samplePartnerSqlId,
S.clientSampleCode, S.internalSampleCode,PST.sampleStatusName,
ST.studyCode, A.activityCode,
SAFV.txtValue, SMT.sampleTypeName,S.sampleDescription, C.clientName
from SamplesPartners as S
....
INTO #temp2
FROM SamplesPartners S
INNER JOIN #temp1 ActTemp
???
Just to keep the system...
_____________
Code for TallyGenerator
April 18, 2016 at 5:31 pm
You must create a clustered index with definitions matching your purging criteria.
If during purging you delete all the records with DateInserted less than 90 days ago, then that must be...
_____________
Code for TallyGenerator
April 18, 2016 at 5:22 pm
ScottPletcher (4/18/2016)
I'm not a developer, I'm a DBA, and I understand the data types involved.
That's it.
This condition can allow you, or me, or somebody with the same level of...
_____________
Code for TallyGenerator
April 18, 2016 at 4:25 pm
Sean Lange (4/15/2016)
Well then apparently you think myself and many others are constantly speaking nothing but BS???
Only if you say so.
You forgot to mention scalar functions and multi-statement table...
_____________
Code for TallyGenerator
April 18, 2016 at 4:10 pm
Well, performance of the query seems to be irrelevant, as it's built incorrectly.
declare @Assignee as varchar(25); set @Assignee = 'Smith, John'
select ...
from ...
left join v_R_User vru on vru.Distinguished_Name0 =...
_____________
Code for TallyGenerator
April 17, 2016 at 7:05 pm
First thing to start with - look at the execution plans taken in both environments.
It will show you what's so different there.
_____________
Code for TallyGenerator
April 14, 2016 at 11:42 pm
nhansen pcc (4/11/2016)
Have you identified the corruption? has the server team looked at the drives or SAN?
Both our internal SAN team, and the vendor have looked at it, and...
_____________
Code for TallyGenerator
April 14, 2016 at 7:36 pm
And you can safely remove left join
dbo.Table3 t3 on t1.Code3 = t3.Code3 and
t3.Code4 = 1
left-joined table is not gonna affect COUNT(*) in any way.
_____________
Code for TallyGenerator
April 14, 2016 at 6:21 pm
You need to have a look into your indexing and how it correlates with the query.
It seems like the indexes on the tables involved are so irrelevant to the parameters...
_____________
Code for TallyGenerator
April 14, 2016 at 6:19 pm
Hugo Kornelis (4/14/2016)
A database with a high number of heaps is with a 99.999% likelihood simply designed badly.
Amen.
_____________
Code for TallyGenerator
April 14, 2016 at 4:11 pm
TheSQLGuru (4/14/2016)
_____________
Code for TallyGenerator
April 14, 2016 at 4:06 pm
Viewing 15 posts - 1,486 through 1,500 (of 6,036 total)