I have used content porter to export all publications (around 50) from one environment to other.

On Source the publication id's are 39, 40, 41 etc., but on destination auto generated publication ID of imported publications start with 1018.

CMS: 2013 SP1, Content Porter 2013

Is there any settings for Content Porter for publication ID on destination CMS??

  • How are you using Publication Ids? If you need them the same for delivery-side code, could you use Publication Titles instead? Jul 10, 2014 at 22:01

2 Answers 2


Unfortunately, there is no mechanism in Content Porter for setting the ID's of newly created items (including Publications). The ID is auto-generated each time and just incremented (from the last used ID).

Writing code that relies on fixed ID's is bad practice in Tridion. If possible, I'd recommend that you use WebDAV paths, or have a configuration file for ID's that may change between environments.

One way to make ID's the same between environments is to do a Database Refresh (of the Tridion_cm database) from Production to the other environment(s).


Let's understand how the Publication IDs are getting generated in the SDL Tridion: The publication IDs are NOT generated based on any algorithm or calculations but they are simply the integer type data column with Identity set to true - You can refer the Publications table in the Tridion Content Manager Database. Now as the property of MS-SQL Server Identity column suggests - If you create 10 publications for an example, you will have their Publication ID from 1 to 10; if you delete 4 last created publications - you will left with 6 publication with Pub ID from 1 to 6 and now if you create a 7th publication, the publication ID for this will be 11 - So creation & configuration of Publication ID is something in control of MS-SQL Server and not SDL Tridion.

Now how to control the Identity columns is something should be raised to SQL Server community and also this is something none of us will suggest you to do considering it may end your SDL support.

However, if you are really interested in configuring/resetting the Publication IDs generated by Reseeding the identity column, to help you with, you can (please note I am not recommending due to the reason suggested by Jonathan in the answer above) execute following command -


Here the last parameter will specify the next Publication ID (in the above example: 0 means the next publication ID will be 1 provided there is no already existing publication with this ID)

  • Some valuable insight there @Pankaj! I do not know the database structure that well, but I would not recommend re-seeding the identity column in this situation (or probably any situation!). The Publication IDs that @Saurabh mentions are 39, 40, etc. However, this is the order that they were created in the source CMS - it may not necessarily be the order in which Content Porter creates them. Also, the values are probably used as foreign keys in other tables (for Publishing Targets, permissions, etc.) - I'm not sure I'd be brave enough to mess with those things (or to invalidate my support)! Jul 10, 2014 at 9:46
  • While importing content, Content Porter failed a few times (about 10 times) - due to different reasons - like component's data was not validating with Schema (since schema was modified to have a new mandatory field), transaction timeout etc. - all those issues were resolved. Is this correct that every time content porter import failed it roll back everything from SQL.. that's the reason for having such big publication ID (1018).. when porting was successfull???? Since on destination CMS, only 5 publications were created and none was deleted. Jul 10, 2014 at 10:06
  • @JonathanWilliams: Ofcourse; And even I have mentioned this in my answer clearly that I am not recommending to do this and even I am not brave enough to play around with that...I just have shared one possibility that it "Can" be done...and definitely at your own risk :) Jul 10, 2014 at 10:16
  • @Saurabh: Yes by default if CP failed it will roll back everything, however, there is a check box in the wizard which you can use whether you want to rollback in case of failure or not Jul 10, 2014 at 10:18
  • @JonathanWilliams: "Values are probably used as foreign key..." Not agree, as the command above would not change anything in the existing data. "Invalidate Support.." ofcourse, I have already mentioned that in my answer :) Jul 10, 2014 at 10:22

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.