305 reputation
211
bio website dvt.co.za
location South Africa
age 44
visits member for 2 years, 11 months
seen yesterday

I've been developing software of all shapes and sizes using Microsoft technologies for over 20 years now.

The wonder of our profession is that we continue to learn something new every day, and that to teach IS to learn.

Current obsession : Having a chuckle at local South African culture (or lack thereof)


Jan
26
comment MySQL and window functions
Have a look at this workaround here and here
Oct
24
comment How can I change Referential Integrity from a Unique Key Constraint to a Primary Key?
@ypercube - indeed, that's what I had feared I had to do in the original fiddle above. I guess I was hoping there was a back door hack to somehow get Sql to switch / influence the way in which it enforced the FK.
Oct
24
comment How can I change Referential Integrity from a Unique Key Constraint to a Primary Key?
Thanks Jon - will generate drop scripts for the UKC and FK's and recreate the FK's.
Oct
24
comment How can I change Referential Integrity from a Unique Key Constraint to a Primary Key?
Interestingly enough, SQL seems determined to use the UKC ahead of the PK even if the RI is created afterwards, e.g. sqlfiddle.com/#!6/34c52
Jul
24
comment Difference between count(*) and count(1) in mysql?
Thanks Emmad - updated.
Oct
8
comment Best table schema to store daily hits for many items?
Option 2 doesn't make much sense given your requirement to determine cumulative hits between any 2 dates. Your first option gives most flexibility.
Aug
24
comment How can place SQL Server online on the internet?
You might consider hosting your SQL database at a service provider - there are a lot of security concerns you need to address and a provider is likely to have more experience.
Aug
17
comment Difference between count(*) and count(1) in mysql?
Yes, is interesting to see how the different RDBMS handle an invalid expression.
Jul
30
comment Implications of using a Unique NonClustered Index with Covering Columns instead of a Primary Key
Thanks - it turns out that the index stats showed that the PK was still heavily used for scans. It seems I was being overzealous - the readability / convention benefits of retaining the PK should outweigh any storage implications in the long run. The point about transactional replication clinches it though - we WILL need to replicate this database shortly.
Jul
26
comment Implications of using a Unique NonClustered Index with Covering Columns instead of a Primary Key
Thanks - do you have any reference links? w.r.t. slightly worse, are you referring solely to the lower index density in the covering index, or is there something else which would cause this?
Jul
26
comment Implications of using a Unique NonClustered Index with Covering Columns instead of a Primary Key
@jn29098 - Updated. Confirmed that we do have a clustered index, on columns which are neither the PK nor the covering columns, so this doesn't seem relevant to this decision.
Feb
1
comment Attaching MDF without LDF
Have a look at this post - it discusses how to rebuild the log in emergency mode, but as it requires a restart of SQL server isn't something to do on your Prod Server (Nb - Jose Basilio's answer, not the accepted one) stackoverflow.com/questions/773059/…