DBAL-530: sqlite: foreignKey - definition wrong when tables has databasename as prefix #1737

doctrinebot opened this Issue May 24, 2013 · 1 comment

2 participants


Jira issue originally created by user rosslau@my-hammer.de:

Because of the fact that SQLite doesn't support multiple databases in one file, Doctrine handles definitions like that:

 * @ORM\Entity()
 * @ORM\Table(name="database.table")

in this way:

CREATE TABLE database**table[...]

But when another Tabele references a table defined like the one above, the foreignkey definition is generated wrong:

[...]FOREIGN KEY (table_id) REFERENCES database.table (id) NOT DEFER[...]

{color:red}SQLSTATE[HY000]: General error: 1 near ".": syntax error{color}

I guess this would be the right query:

[...]FOREIGN KEY (table*id) REFERENCES database_*table (id) NOT DEFER[...]

Issue was closed with resolution "Fixed"

@doctrinebot doctrinebot added the Bug label Dec 6, 2015
@beberlei beberlei was assigned by doctrinebot Dec 6, 2015
@doctrinebot doctrinebot added this to the 2.4 milestone Dec 6, 2015
@doctrinebot doctrinebot closed this Dec 6, 2015
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment