July 20, 2021 at 7:13 pm
I have a partition scheme created and just need to create a table using it, but i need to use syntax for adding the indexing and primary key at the same time if possible. Can this be done? "PS_Year_Partition" is my partition scheme name:
CREATE TABLE [dbo].[CallLogCommonPartitioned](
[CALL_ID] [varchar](255) NOT NULL,
[DATE] [date] NOT NULL,
[TIME] [time](0) NOT NULL,
[lead_id] [varchar](255) NULL,
[DOMAIN] [varchar](4) NOT NULL,
[SESSION_ID] [varchar](255) NULL,
[CALL_TYPE] [varchar](255) NOT NULL
)
ON PS_Year_Partition ([date]);
GO
And what about the below added into the T-SQL?:
CREATE PRIMARY KEY CLUSTERED
(
[CALL_ID] ASC,
[DATE] ASC,
)WITH (PAD_INDEX = OFF, STATISTICS_NORECOMPUTE = OFF, IGNORE_DUP_KEY = OFF, ALLOW_ROW_LOCKS = ON, ALLOW_PAGE_LOCKS = ON) ON [PRIMARY]
) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY]
GO
July 21, 2021 at 8:10 pm
Thanks for posting your issue and hopefully someone will answer soon.
This is an automated bump to increase visibility of your question.
Viewing 2 posts - 1 through 1 (of 1 total)
You must be logged in to reply to this topic. Login to reply