Error applying the automatic scripting

May 17, 2011 at 2:03 PM

Hello again. This version solves many issues (resize form, typing Server name...) but I cannot apply the script created with SQL Server Compression Estimator because in all cases I get the following error:

 -- This compression script was created by Compression Estimator

-- By applying PAGE compression setting, you should obtain
-- approximately 20,00% compression
ALTER TABLE [Sales].[SpecialOfferProduct]
REBUILD PARTITION = 1
WITH (DATA_COMPRESSION = PAGE);

-- By applying PAGE compression setting, you should obtain
-- approximately 44,66% compression
ALTER TABLE [Sales].[Store]
REBUILD PARTITION = 1
WITH (DATA_COMPRESSION = PAGE);

The database is AdventureWorks2008R2

The error in all cases is

Msg 7729, Level 16, State 1, Line 5

Cannot specify partition number in the alter index statement as the index 'PK_SpecialOfferProduct_SpecialOfferID_ProductID' is not partitioned.

 

 

Thank you very much


Coordinator
May 17, 2011 at 10:31 PM

I will take a look at this and see what is going on. Every object always has at least one partition... I may have to tweak the script - but I shouldn't have to.

Thanks for the continuing feedback.

boB

May 18, 2011 at 1:02 PM
Thank you very much.


From: [email removed]
To: [email removed]
Date: Tue, 17 May 2011 15:31:49 -0700
Subject: Re: Error applying the automatic scripting [ssce:257929]

From: majikbybob
I will take a look at this and see what is going on. Every object always has at least one partition... I may have to tweak the script - but I shouldn't have to.
Thanks for the continuing feedback.
boB
Read the full discussion online.
To add a post to this discussion, reply to this email (ssce@discussions.codeplex.com)
To start a new discussion for this project, email ssce@discussions.codeplex.com
You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.
Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com
May 20, 2011 at 8:25 AM

Thank you, with the new vesion I get the following error:

 

Msg 7735, Level 16, State 1, Line 5

Cannot specify partition number in alter table statement to rebuild or reorganize a partition of table 'colectivos' as table is not partitioned.

Coordinator
May 23, 2011 at 9:29 AM

I am working on this now. I hope to have an update available by the end of the week.

May 23, 2011 at 10:23 AM
Hello.

I will be alert during the week

Thank you

From: [email removed]
To: [email removed]
Date: Mon, 23 May 2011 02:29:09 -0700
Subject: Re: Error applying the automatic scripting [ssce:257929]

From: majikbybob
I am working on this now. I hope to have an update available by the end of the week.
Read the full discussion online.
To add a post to this discussion, reply to this email (ssce@discussions.codeplex.com)
To start a new discussion for this project, email ssce@discussions.codeplex.com
You are receiving this email because you subscribed to this discussion on CodePlex. You can unsubscribe on CodePlex.com.
Please note: Images and attachments will be removed from emails. Any posts to this discussion will also be available online at CodePlex.com
Coordinator
May 23, 2011 at 5:47 PM

Thank you  - the script generation code was incorrectly identifying whether or not an indexe was partitioned and was emitting the wrong script fragment.

This has been corrected in V1.0.3.0

May 26, 2011 at 1:20 PM

Thank you very much. The problem was solved. Congratulations for your program

May 8, 2012 at 12:38 PM

I am also getting the same error as above

"Cannot specify partition number in the alter index statement as the index  is not partitioned."

When i queried Sys.partitions table for the table name i could get multiple rows so i had rebuilt below syantax

alter index <Indexname1> on <tablename>
rebuild partition = 1

But recieve the error "Cannot specify partition number in the alter index statement as the index  is not partitioned."

I had removed partition =1 from alter index and rebuild the index but when i check the fragmentaation level on physical _io_stats, i could find the fragmentation level >50.

Need help to defragment the table.

Details: SQL Server 2005
Indexes : two indexes
Query on sys.partitions for table : 2 rows