It's not the same without you

Join the community to find out what other Atlassian users are discussing, debating and creating.

Atlassian Community Hero Image Collage

Can't import Object schema

 I am trying to import previously exported Object schema, but an error appears. Log can be downloaded via link: https://goo.gl/1ipD5p 

error.JPG

2 comments

Hi Artem,

I could not download the log from the link.

Could you report this object schema export issue as an bug report at https://portal.riada.se/servicedesk/customer/portal/12 and also attach the log there?

Best Regards
Alexander

https://pastebin.com/C6XnDLQJ - this resource is available from everywhere. i attached log here

Hi Artem!

Looking at the log I think I know the why it fails.

Error: ValidationInsightException: Validation errors were found: Errors: {name=Name has to be unique within the same object type}

 This validation messages is thrown multiple times and indicates that you have names that are not unique in your object type(s). Basically this is a normal scenario under certain conditions.

  1. You create a schema with object types and add objects
  2. You then select the Name attribute to be unique

This causes the possibility to have more than one object with the same name as the unique check was added after objects been created, possibly with the same name, and this will cause this error on import.

A possible way to solve this is to remove the unique checkbox on the object types in the original schema and do another export, and then set the checkboxes back again. 

Best Regards
Alexander

Well, Alexander, I understand a possible way to solve this problem, but how can I easily find the objects with setted unique checkbox? I have tried to find this setted checkbox at more than 50 object types, but I haven't found it.  I have also tried to find this parameter at XML-configuration of exported scheme,<uniqueAttribute>false</uniqueAttribute> is everywhere in the configuration. Can you show me step-by-step, how to find setted unique checkbox?

Hi Artem,

Looking at the link to the log you mentioned, I can see statements like this:

2018-02-07 04:34:20,923 [insight-ObjectSchemaImportServiceImpl-0-thread] | Unable to insert object type ObjectTypeBean [id=null, name=Contractor] will skip this object type, Error: ValidationInsightException: Validation errors were found: Errors: {name=Name has to be unique within the same object type}

So I would look at the mentioned Object Types, and review this setting, i.e check the configuration for the Name attribut.

Let us know the result.

Best Regards
Alexander

Thanks! There were 3 pairs of object types with the same name. Import of scheme has been done successfully! 

Ok! Glad to hear that it got resolved :)

Hello!

I have the same problem but the error in log is

[insight-ObjectSchemaImportServiceImpl-0-thread] | Error when importing object schema and objects, object schema id: 2, Error: ValidationInsightException: Validation errors were found: Errors: {name=Name has to be unique in both global configuration and for this object schema.}

What does it mean? I checked my types and its haven't  a setted unique checkbox

Hi, 

In this case it means that you have duplicates of either References, Icons or Statuses. There can be only one of these types with the same name (these are case insensitive so CLOSED and Closed are considered to be duplicates). 

Check your schema and see if you have some duplicate names of any of these and try to export again. 

 

Cheers

Comment

Log in or Sign up to comment
TAGS
Community showcase
Published in Marketplace Apps & Integrations

How to increase productivity and grow billable hours amount in Jira

    For several managers it’s a real challenge (sometimes a nightmare) to deal with multiple service contracts and turn every working hour into a billable hour. This is crucial to m...

82 views 0 2
Read article

Community Events

Connect with like-minded Atlassian users at free events near you!

Find an event

Connect with like-minded Atlassian users at free events near you!

Unfortunately there are no Community Events near you at the moment.

Host an event

You're one step closer to meeting fellow Atlassian users at your local event. Learn more about Community Events

Events near you