dongxibeng5324 2013-08-10 19:19
浏览 150

Doctrine 2如何创建允许一方为空的onetoone关系

Using Doctrine 2 I'm having trouble creating a onetoone relationship for an order to have a final IPN associated with it. Of course the IPN wlil not generated until the PayPal transaction is concluded.

I tried to annotate the class with nullable=true but it complained that nullable is not a valid annotation.

Any ideas?

  • 写回答

1条回答 默认 最新

  • dongyuan9292 2013-08-10 20:14
    关注

    the annotation needs to be on the column that can be null and not on the whole class and if you want to use the nullable column as reference you will get unexpected results as there can be multiple null values

    评论

报告相同问题?

悬赏问题

  • ¥15 想问一下树莓派接上显示屏后出现如图所示画面,是什么问题导致的
  • ¥100 嵌入式系统基于PIC16F882和热敏电阻的数字温度计
  • ¥15 cmd cl 0x000007b
  • ¥20 BAPI_PR_CHANGE how to add account assignment information for service line
  • ¥500 火焰左右视图、视差(基于双目相机)
  • ¥100 set_link_state
  • ¥15 虚幻5 UE美术毛发渲染
  • ¥15 CVRP 图论 物流运输优化
  • ¥15 Tableau online 嵌入ppt失败
  • ¥100 支付宝网页转账系统不识别账号