symfony1doctrinedata-dump

Symfony 1.4 doctrine:data-dump reserverd words


I have a table with 2 columns with reserved words (read, write), while yes I can change the column names I want to see if there is a way to do things as is, for educational purposes :-)

When I load these tables and build my models there is no issue, Symfony has no issue reading the tables from my YAML file, however when I try a data dump the SQL freaks out because read/write are reserved words, YES they are being put into read ticks appropriately, but still no love.

So my question is, is their an option to use escape chars or some other option to give data-dump to account for these special chars, OR Is there a way to exclude a table from the data-dump?

Any help appreciated!


Solution

  • Consider to use *quote_identifier: true*

    doctrine:
      class: sfDoctrineDatabase
      param:
        dsn:      mysql:host=localhost;dbname=mydbname
        username: root
        password: mysecret
        attributes:
          quote_identifier: true
          default_table_collate: utf8_general_ci
          default_table_charset: utf8