Hi everyone,
The followings actions works fine. But only the first NDF (PRIMERO) is growing up.
I don't get the point at all, I though that SEGUNDO would store February, TERCERO March and
CUARTO April to December (according RANGE LEFT)
I feel that there is something very important that I did not in all of this...
I'm stuck.
--Definition table
CREATE TABLE [dbo].[DatosMensuales](
[Id] [int] NOT NULL,
[Concepto] [varchar](50) COLLATE Modern_Spanish_CI_AS NULL,
[FechaAlta] [datetime] NULL
) ON rangoMesFE(FechaAlta)
CREATE PARTITION FUNCTION rangoMesFP(datetime)
AS RANGE LEFT FOR VALUES('200601','200602','200603');
CREATE PARTITION SCHEME rangoMesFE
AS PARTITION rangoMesFP
TO (PRIMERO,SEGUNDO,TERCERO,CUARTO);
--loading data properly
EXEC CARGARMESES '2006-01-01 00:01:01', 'PRUEBAS ENERO', 1, 10000
EXEC CARGARMESES '2006-02-01 00:01:01', 'PRUEBAS FEBRERO', 10001,20000
EXEC CARGARMESES '2006-03-01 00:01:01', 'PRUEBAS MARZO', 20001,30000
EXEC CARGARMESES '2006-04-01 00:01:01', 'PRUEBAS ABRIL', 30001,40000
SELECT $partition.rangoMesFP('200606') --> DATA IN THE FOURTH PARTITION, OK
Does anyone have any idea about this?
When I launch sp_helpdb only NDF which belong to PRIMERO partition are altered:
pruebas 1 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\pruebas.mdf PRIMARY 7168 KB Unlimited 1024 KB data only
pruebas_log 2 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\pruebas_log.ldf NULL 1024 KB 2147483648 KB 10% log only
fich_1 3 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\fich_1.ndf PRIMERO 4096 KB Unlimited 1024 KB data only
fich_2 4 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\fich_2.ndf PRIMERO 4096 KB Unlimited 1024 KB data only
fich_5 5 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\fich_5.ndf CUARTO 3072 KB Unlimited 1024 KB data only
fich_6 6 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\fich_6.ndf QUINTO 3072 KB Unlimited 1024 KB data only
fich_3 7 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\fich_3.ndf SEGUNDO 3072 KB Unlimited 1024 KB data only
fich_4 8 C:\Program Files\Microsoft SQL Server\MSSQL.1\MSSQL\DATA\fich_4.ndf TERCERO 3072 KB Unlimited 1024 KB data only
No comments:
Post a Comment