Foros del Web » Programación para mayores de 30 ;) » Bases de Datos General » SQL Server »

Primary Key Clustered?

Estas en el tema de Primary Key Clustered? en el foro de SQL Server en Foros del Web. Buenas, me podrian confirmar si al crear un indice Primary Key se crea como Clustered? que ventajas me otorga a las consultas hacerlo clustered o ...
  #1 (permalink)  
Antiguo 26/04/2012, 21:55
 
Fecha de Ingreso: abril-2012
Ubicación: Capital Federal
Mensajes: 283
Antigüedad: 12 años
Puntos: 15
Primary Key Clustered?

Buenas, me podrian confirmar si al crear un indice Primary Key se crea como Clustered? que ventajas me otorga a las consultas hacerlo clustered o no?

Necesito que me aclaren este tema.

Gracias, saludos
  #2 (permalink)  
Antiguo 27/04/2012, 08:18
Avatar de Libras
Colaborador
 
Fecha de Ingreso: agosto-2006
Ubicación: En la hermosa perla de occidente
Mensajes: 7.412
Antigüedad: 17 años, 8 meses
Puntos: 774
Respuesta: Primary Key Clustered?

try with this, what is the matter with the search in English or you don't know how to made a search in spanish, if you try this you can find a lot of information about what is the difference between a cluster index and noncluster index like those following links:

http://www.marten-online.com/databas...tructures.html

http://stackoverflow.com/questions/5...lustered-index

Regards,
Libras
__________________
What does an execution plan say to t-sql query? Go f**k yourself, if you are not happy with me
  #3 (permalink)  
Antiguo 27/04/2012, 10:02
 
Fecha de Ingreso: abril-2012
Ubicación: Capital Federal
Mensajes: 283
Antigüedad: 12 años
Puntos: 15
Respuesta: Primary Key Clustered?

Algun articulo en español sobre el tema, podrian recomendarme?
  #4 (permalink)  
Antiguo 27/04/2012, 11:00
Avatar de Libras
Colaborador
 
Fecha de Ingreso: agosto-2006
Ubicación: En la hermosa perla de occidente
Mensajes: 7.412
Antigüedad: 17 años, 8 meses
Puntos: 774
Respuesta: Primary Key Clustered?

A ver traducido al español: Tan dificil es hacer una busqueda del tipo

diferencias entre cluster index y non cluster index sql server en el google y ver los resultados? por ejemplo esta liga:

http://grimpidev.wordpress.com/2008/...en-sql-server/

saludos!
__________________
What does an execution plan say to t-sql query? Go f**k yourself, if you are not happy with me
  #5 (permalink)  
Antiguo 27/04/2012, 17:34
Avatar de matanga  
Fecha de Ingreso: octubre-2007
Ubicación: España
Mensajes: 1.091
Antigüedad: 16 años, 5 meses
Puntos: 85
Respuesta: Primary Key Clustered?

Cita:
..me podrian confirmar si al crear un indice Primary Key se crea como Clustered?...
Por defecto si, para que el índice de la primary key no sea clustered hay que indicarlo expresamente, por ejemplo:

Código:
create table t1 (id int not null)
go
alter table t1 add constraint pk_id primary key nonclustered (id)
go
Cita:
..que ventajas me otorga a las consultas hacerlo clustered o no?
Este enlace comenta las consultas que se benefician del tipo de índice http://msdn.microsoft.com/es-es/libr...v=sql.90).aspx

Saludos
  #6 (permalink)  
Antiguo 27/04/2012, 19:43
 
Fecha de Ingreso: abril-2012
Ubicación: Capital Federal
Mensajes: 283
Antigüedad: 12 años
Puntos: 15
Respuesta: Primary Key Clustered?

Gracias matanga! saludos

Etiquetas: key, primary
Atención: Estás leyendo un tema que no tiene actividad desde hace más de 6 MESES, te recomendamos abrir un Nuevo tema en lugar de responder al actual.
Respuesta




La zona horaria es GMT -6. Ahora son las 17:36.