AUTO_INCREMENT db.xml ?
Permalink
how can i make an AUTO_INCREMENT field using db.xml?
this has not worked:
<field name="eID" type="I">
<key ></key>
<unsigned ></unsigned>
</field>
this has not worked:
<field name="eID" type="I">
<key ></key>
<unsigned ></unsigned>
</field>

You have to add it in to the field info, try:
when i install the package with the code you gave a get the error:
mysql error: [1075: Incorrect table definition; there can be only one auto column and it must be defined as a key] in EXECUTE("ALTER TABLE 3dgalleryList MODIFY COLUMN eID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT")
any other suggestion?
thank you.
mysql error: [1075: Incorrect table definition; there can be only one auto column and it must be defined as a key] in EXECUTE("ALTER TABLE 3dgalleryList MODIFY COLUMN eID INTEGER UNSIGNED NOT NULL AUTO_INCREMENT")
any other suggestion?
thank you.
From the error message, it sounds like you've already got an auto incrementing field on your database table.
I'd check and/or modify your database table or you could uninstall your package, delete the database table and try installing it again.
I'd check and/or modify your database table or you could uninstall your package, delete the database table and try installing it again.
thank you , i deleted the table and it works.