Question

I have tried to import a solution (as managed) in another environment (TEST), but because said solution included an Option Set and a Field having the same name (I really don't see why CRM would think this is a problem in the first place, they are both completely different objects) the import process in the TEST environment failed saying something like:

Column names in each table must be unique. Column name 'my_column_name' in table 'AccountExtensionBase' is specified more than once.

So I went back to the solution in the DEV environment (where all our solution are stored there as Unmanaged) and removed the field from the form, deleted the field and optionset (which both had the same name) and recreated everything with different names.

Thinking this would fix it, I tried importing this in the TEST environment once again.

Well, same error as shown above.

So I went and browsed the table 'AccountExtensionBase' and indeed, the column is there. Thinking this is CRM getting way too confused for a little mistake on my part, I deleted the column from the table (I know, not support neither recommended).

Tried the import once again, now there error is:

The column 'my_column_name' was specified multiple times for 'Account'.

At this point, I don't really know what to do. Did I really break the TEST (target) environment with this small stupid mistake of mine ?

Any help is appreciated.

PS: I always import the solution as managed and tell it to "overwrite" previous changes, not maintain.

Was it helpful?

Solution

Solution imports are always additive - nothing is ever deleted when a solution is imported.

The reason deleting the column from the database wasn't successful is because CRM also maintains a set of tables which contain metadata describing the imported solutions.

I would suggest in this order:

  1. Restore your database to a good state if you can.
  2. Try and delete the fields from test via the CRM UI in the customisations section, you might get lucky if the field is non longer part of your managed solution.
  3. Uninstall the managed solution, you will loose any data but it should give you a fresh base.
  4. Contact Microsoft for support in case they have any wizardry they can apply at the database level.
  5. Try hacking the field out of the metadata (be sure to take a backup).
  6. Create a new test instance - its only a test environment after all and they are expendable for these reasons.
Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top