Hello!
When loading fixtures with i18n data 'symfony propel-load-data' fails with the following error message:
[PropelException]
Unable to execute INSERT statement. [wrapped: Could not execute update [Native Error: Duplicate entry '0-' for key 1] [User Info: INSERT INTO wiki_i18n (SUBJECT,BODY) VALUES ('test2','Hello again!')]]
I marked this ticket as priority 'major', since it is big show-stopper for development (using the 'trinity' of 'propel-dump-data; propel-build-all; propel-load-data' a lot)
Interpreting the error message, it looks as if it would be necessary to explicitly use the i18n indexes for the INSERT statements, since they can not be 'guessed'. Something like:
INSERT INTO wiki_i18n (SUBJECT,BODY,CULTURE,ID) VALUES ('test2','Hello again!','en',1)
Testscenario:
config/schema.yml:
propel:
wiki:
id:
created_at:
updated_at:
wiki_i18n:
subject: varchar(255)
body: longvarchar
fixtures/myapp.yml:
---
Wiki:
Wiki_2:
created_at: 2007-11-26 00:00:00
updated_at: 2007-11-26 00:00:00
Wiki_1:
created_at: 2007-11-26 00:00:00
updated_at: 2007-11-26 00:00:00
WikiI18n:
WikiI18n_1_de:
subject: test1 deutsch
body: Guten Tag!
WikiI18n_2_en:
subject: test2
body: Hello again!
WikiI18n_1_en:
subject: test1
body: hello!
symfony cli command:
symfony propel-load-data myapp
Other specs:
-Ubuntu 7.10 Gutsy
-MySQL 5.0.45
-PHP 5.2.3
-symfony install method: PEAR