This forum is in READ-ONLY mode.
You can look around, but if you want to ask a new question, please use Stack Overflow.

Creating Localized Schema

Notes and reports about symfony 1.0.x stable

Creating Localized Schema

by fishlurch » Thu Jan 06, 2011 3:36 pm

Hi @ all,


want to have several translations for my database contentand created a i18n scheme:

Code: Select all
ail_templates:
    _attributes:            { phpName: MailTemplates, idMethod: native, isI18N: true, i18nTable: mail_templates_i18n  }
    template_id:            { type: integer, required: true, primaryKey: true, autoIncrement: true }
    template_name:          { type: varchar(100), required: true }
    template_module:        { type: smallint, required: true, foreignTable: param_module, foreignReference: pr_module_id }
    template_lastmod_user:   { type: varchar(50) }
    created_at:  ~
    updated_at:  ~


Code: Select all
mail_templates_i18n:     
    _attributes:          { phpName: MailTemplatesI18n }
    template_id:          { type: integer, required: true, primaryKey: true, foreignTable: mail_templates, foreignReference: template_id }
    culture:              { isCulture: true, type: varchar, size: 7, required: true, primaryKey: true }
    template_description:   { type: longvarchar, required: true }
    template_text:          { type: longvarchar, required: true }


But when wanting to use this scheme in formulars like

Code: Select all
<?php $value = $mail_templates->getTemplateDescription(); echo $value ? $value : '&nbsp;' ?>
#

the following error occurs:

Unable to execute INSERT statement. [wrapped: Could not execute update [Native Error: Unknown column 'TEMPLATE_DESCRIPTION' in 'field list'] [User Info: INSERT INTO mail_templates


Any idea?

thanks and Greez
fishlurch
Junior Member
 
Posts: 9
Joined: Mon Dec 06, 2010 8:47 pm