0
votes

I installed Pimcore 3.1.1 and I have lot of issue with message like:

(
    [message] => SQLSTATE[42000]: Syntax error or access violation: 1091 Can't DROP 'p_index_person__id'; check that column/key exists, query was: ALTER TABLE `object_store_3` DROP INDEX `p_index_person__id`;
    [method] => query
    [arguments] => Array
        (
            [0] => ALTER TABLE `object_store_3` DROP INDEX `p_index_person__id`;
        )

)

(
    [message] => SQLSTATE[42000]: Syntax error or access violation: 1091 Can't DROP 'p_index_person__type'; check that column/key exists, query was: ALTER TABLE `object_store_3` DROP INDEX `p_index_person__type`;
    [method] => query
    [arguments] => Array
        (
            [0] => ALTER TABLE `object_store_3` DROP INDEX `p_index_person__type`;
        )

)

(
    [message] => SQLSTATE[42000]: Syntax error or access violation: 1091 Can't DROP 'p_index_Options'; check that column/key exists, query was: ALTER TABLE `object_store_12` DROP INDEX `p_index_Options`;
    [method] => query
    [arguments] => Array
        (
            [0] => ALTER TABLE `object_store_12` DROP INDEX `p_index_Options`;
        )

)

Same errors are reported in Pimcore forum at the bottom of the post.

Is there an issue about this ? Currently, I can't work with Pimcore. Every change in object structure corrupts the data. Any advice ?

UPDATE #001 : I have tried Johan's solutions :

First one

  1. Backup your entire system
  2. Export class defintions from within admin
  3. Import class definitions from within admin, save class

Second

  1. Export the class definitios from within admin
  2. Remove files in website/var/classes
  3. Import your class definitions again

I always have the same errors in log with alter table.

When I try to add an ObjectBricks to my object, I see this : No choice in ObjectBricks

Thanks for your help.

Have a nice day.

1

1 Answers

0
votes

you could try to

  1. Backup your entire system
  2. Export class defintions from within admin
  3. Import class definitions from within admin, save class

If that does not do the trick then you could try to (be sure you did a backup Before and know your recover steps)

  1. Export the class definitios from within admin
  2. Remove files in website/var/classes
  3. Import your class definitions again

/Johan