views:

99

answers:

1
Category:    
  columns:
    id:
    type: integer(11)
    primary: true
    autoincrement: true
    unsigned: true
  name:
    type: string(255)
    notnull: true
actAs:
  Timestampable:
    created:
      name: created_at
      type: timestamp
      format: Y-m-d H:i:s
    updated:
      name: updated_at
      type: timestamp
      format: Y-m-d H:i:s

Hi everyone! Here is my schema.yml and the problem is that when I run doctrine buil-all-reload it generates database but instead of timestamp it adds datetime. Why?
This migh be another question but since it is closely related I will ask here. I wanted to use timestamp because of on update CURRENT_TIMESTAMP Is there another way of doing such thing in Zend or Doctrine?

A: 

I think you should:

  1. Use default Timestampable behavior which uses datetime, or:
  2. Write your own behavior which uses timestamps so that you can on update CURRENT_TIMESTAMP them (timestamp from doctrine manual)
bouke