I guess it is not possible to change the ID for a Node.
So is it possible to make sure that the next ID for a Umbraco Node is starting from a specific number?
Eg. last created Content Node has ID = 4_000
I need the next node (Content or Media) to start from 5_000
I could make a DB change on the column [Id] in the table [UmbracoNode] so the IdentitySeed is 5_000
But Í rather not change any table settings in the DB.
A work-around could be creating several ContentNodes and the delete also from recyclebin.
k
Kevin Jump
02/19/2025, 2:27 PM
Hi, you can't set the node Id, but you can set the Key, so i would try not to hardwire anything to getting content by id, but rather get it by key, you can then at least know that is going to be the same between sites.
m
Mikkel Johansen
02/20/2025, 10:31 AM
After a little research in the database. I believe that a minor "reseed" of the table [UmbracoNode] could solve the wish.
DBCC CHECKIDENT ('UmbracoNode', RESEED, 5000);
s
Sebastiaan
02/20/2025, 10:44 AM
We used to reseed all the time. But it was a symptom of a problem and it was definitely not a good way to do things since at some point.. you underestimate the number of nodes you thought you'd have and then you'd be stuck.
As Kevin hinted at: not a good idea to rely on the int identifier, always rely on the node key (GUID) insted and use a great tool like uSync or Deploy to help you move nodes between environments.
m
Mikkel Johansen
02/20/2025, 2:18 PM
I understand your concerns about using IDs. In this specific case, it's unfortunately not possible to use GUIDs.
We are currently exploring alternative solutions regarding the ID value.
s
Sebastiaan
02/20/2025, 2:56 PM
You can reseed to the millions I guess, and pray 😅