Saturday, February 25, 2012

page splits

Say you have a table as such
create table test
(col1 int identity(1,1) primary key,
col2 varchar(10),
col3 varchar(10))
and now you pound this table with heavy inserts from multiple clients
Can it cause page splits ? It would appear that its inserting in order in
col1 and that pages will be ordered and written sequentially.. If it does
cause page splits, can you explain how ? And also will changing col1 to
nonclustered help ?
ThanksIt should not create page splits on inserts alone but if you update the
varchars later to a value larger than the original it can cause a split.
--
Andrew J. Kelly SQL MVP
Solid Quality Mentors
"Hassan" <hassan@.hotmail.com> wrote in message
news:%23B8bqUlFIHA.4308@.TK2MSFTNGP06.phx.gbl...
> Say you have a table as such
> create table test
> (col1 int identity(1,1) primary key,
> col2 varchar(10),
> col3 varchar(10))
> and now you pound this table with heavy inserts from multiple clients
> Can it cause page splits ? It would appear that its inserting in order in
> col1 and that pages will be ordered and written sequentially.. If it does
> cause page splits, can you explain how ? And also will changing col1 to
> nonclustered help ?
> Thanks
>

No comments:

Post a Comment