As all know, FK on MySQL must be unsigned in order to be able to add
constraing fk index on it, otherwise when adding constraint key on it, it
gives errno 150.
when I set unsigned status of FK as true like this:

$metadata->mapField(array(
   'fieldName' => 'productId',
   'columnName' => 'product_id',
   'type' => 'integer',
   'nullable' => false,

*   'unsigned' => true,*   'comment' => '',
  ));

then run orm:update it revokes unsigned status as below:
ALTER TABLE .... CHANGE product_id product_id INT NOT NULL;
then on next line when it wants to add constraing key, it gives 150 error,
so I was forced to output the orm:update to a text file, remove CHANGE then
copy/paste it in MySQL console and this way it can adds constrainy key fine!

So isn't it a bug on orm:update that it does not recognize
   'unsigned' => true,
and revokes unsigned status when orm:update is applied?

-- 
You received this message because you are subscribed to the Google Groups 
"doctrine-user" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/doctrine-user.
For more options, visit https://groups.google.com/d/optout.

Reply via email to