Click here to Skip to main content
15,884,176 members
Home / Discussions / Database
   

Database

 
GeneralRe: Shipping tracking Link output to google search from MYSQL Database Pin
Richard Deeming25-Apr-18 9:46
mveRichard Deeming25-Apr-18 9:46 
GeneralRe: Shipping tracking Link output to google search from MYSQL Database Pin
bfg9000d36025-Apr-18 9:50
bfg9000d36025-Apr-18 9:50 
GeneralRe: Shipping tracking Link output to google search from MYSQL Database Pin
Richard Deeming25-Apr-18 10:08
mveRichard Deeming25-Apr-18 10:08 
GeneralRe: Shipping tracking Link output to google search from MYSQL Database Pin
bfg9000d36025-Apr-18 10:12
bfg9000d36025-Apr-18 10:12 
GeneralRe: Shipping tracking Link output to google search from MYSQL Database Pin
Richard Deeming25-Apr-18 10:16
mveRichard Deeming25-Apr-18 10:16 
GeneralRe: Shipping tracking Link output to google search from MYSQL Database Pin
bfg9000d36026-Apr-18 1:17
bfg9000d36026-Apr-18 1:17 
QuestionCopying the Headers of Result Set of Select statement Pin
indian14324-Apr-18 9:05
indian14324-Apr-18 9:05 
AnswerRe: Copying the Headers of Result Set of Select statement Pin
JChrisCompton24-Apr-18 11:42
JChrisCompton24-Apr-18 11:42 
AnswerRe: Copying the Headers of Result Set of Select statement Pin
Mycroft Holmes24-Apr-18 12:53
professionalMycroft Holmes24-Apr-18 12:53 
GeneralRe: Copying the Headers of Result Set of Select statement Pin
indian14324-Apr-18 14:09
indian14324-Apr-18 14:09 
GeneralRe: Copying the Headers of Result Set of Select statement Pin
Mycroft Holmes24-Apr-18 14:32
professionalMycroft Holmes24-Apr-18 14:32 
GeneralRe: Copying the Headers of Result Set of Select statement Pin
indian14325-Apr-18 9:48
indian14325-Apr-18 9:48 
QuestionNaming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
JChrisCompton20-Apr-18 11:55
JChrisCompton20-Apr-18 11:55 
AnswerRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Victor Nijegorodov21-Apr-18 3:34
Victor Nijegorodov21-Apr-18 3:34 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
JChrisCompton23-Apr-18 3:00
JChrisCompton23-Apr-18 3:00 
AnswerRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Eddy Vluggen23-Apr-18 5:19
professionalEddy Vluggen23-Apr-18 5:19 
AnswerRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Jörgen Andersson23-Apr-18 21:58
professionalJörgen Andersson23-Apr-18 21:58 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
JChrisCompton24-Apr-18 11:21
JChrisCompton24-Apr-18 11:21 
> I believe you're mixing up indexes with keys.

Perhaps - let me try again; maybe I didn't convey this well.

The index isn't just for lookup speed, it is a unique index (same functionality as a unique constraint unless I'm missing something... I'm more of an 'app dba' than a 'real DBA') to enforce referential integrity because... referential integrity.

The addition of the Identity field was due to my concern about page splits. The guid will remain the primary key for the table. The guid is generated within a vendor's application so there isn't much I can do about that at the moment.

I know (or at least 'think') that fill factor is only applied at rebuild or creation. This troubled me since guids are random (in the sense that where a newly generated guid falls numerically in relation to an existing list of guids is a random position). Inserts will fill up any fill factor <100 and then splits start (and the splits are equivalent to fill factor = 100 as the table grows).

So I came up with the idea of a Clustered Identity as the 'physical sorting field' (numerically increasing won't generate page split) because it seems a better idea than (1) guid inserts causing page splits, and (2) better than making the table a heap (without a clustered index).

Someone mentioned the volume being low. Yes, last month was 3,000 but this will be expanded from 1 to 5 categories. This could cause 3,100 entries next month or 31,000 entries. I don't have the time of day of the inserts but it is all first shift and (I think) mostly at the start of the month. If I can cause less work for the db, it feels like I should.

One new piece of information that I'll share: testing this I don't see as much of a negative impact from a pk clustered guid as I expected.
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Eddy Vluggen25-Apr-18 0:41
professionalEddy Vluggen25-Apr-18 0:41 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
JChrisCompton25-Apr-18 4:40
JChrisCompton25-Apr-18 4:40 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Eddy Vluggen25-Apr-18 5:33
professionalEddy Vluggen25-Apr-18 5:33 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
JChrisCompton30-Apr-18 5:30
JChrisCompton30-Apr-18 5:30 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Eddy Vluggen30-Apr-18 5:58
professionalEddy Vluggen30-Apr-18 5:58 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
JChrisCompton30-Apr-18 7:35
JChrisCompton30-Apr-18 7:35 
GeneralRe: Naming my clustered index column which isn't the PK (and is a non-PK clustered Identity a good idea?) Pin
Eddy Vluggen30-Apr-18 8:13
professionalEddy Vluggen30-Apr-18 8:13 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.