Sei sulla pagina 1di 5

Versioning in Sitecore

As Sitecore supports versioning of items, it also provides a list of options


about the versioning of fields of items/templates. The options we have for
each of the field while creating the template are Versioned, Shared,
Unversioned. Let us see in detail about each of these types.

1. Versioned fields
By default every field in Sitecore is a versioned field. These fields can have
separate language versions and several numbered versions for each
language version. To mark a field as versioned do not check Shared and
Unversioned checkboxes while creating the template.

2. Shared fields
While creating the templates, we need to check the Shared checkbox to
make a field 'Shared'. The data in the Shared fields are shared among all
languages and all numbered versions. So if you make a change in one
language version of an item it would reflect in other languages and their
numbered versions. These type of fields are used mainly if there is some
data whose value need not to b versioned at all. Like a profile image or
something.
When a field is shared, it will be visible from the item using that template.
Say there is an item called 'Sample Item', with a shared field 'Title', then
there is a small note '[Shared]' visible beside the field in all the items which
are using this template.

3. Unversioned fields
While creating the template, we need to check the Unversioned checkbox
to make a field Unversioned. The data in the Unversioned fields are
separate for each language version but all the numbered versions share
the same data. Select this type of field if you need to maintain different data
for different languages but do not need numbered versions. Like a product
name field, as it could be different in different languages and you might
have decided not to maintain numbered versions.
Similar to the shared fields, Unversioned fields will also carry a small note
'[Unversioned]' beside the field name.

4. Unversioned, Shared fields


What if you have checked both Unversioned and Shared? - As the
shared fields does not maintain language or numbered versions, if we
select both 'Unversioned' and 'Shared', the fields would be acting like
'Shared' fields. So it does not make any affect checking or unchecking
'Unversioned' checkbox after selecting the 'Shared' checkbox.

Fields which are marked as Shared and Unversioned will carry a small note
'[Unversioned, shared]' beside the field name
5. Final Layout
All the changes made to this layout are specific to that language and
numbered version. Initially all the controls from shared layout are imported
to the final layout. Once you start making any changes in the final layout,
these changes will remain here and become specific to that particular
language version and numbered version.

Potrebbero piacerti anche