3

桌子上的parent_id字段是做什么用的?sales_flat_order_payment我猜它是entity_idfrom sales_flat_order,但如果我正确阅读它,那么根据http://www.magereverse.com/index/magento-database-diagram/version/1-7-0-1entity_id表上的实际sales_flat_order_payment是指而是放在桌子上entity_idsales_flat_order

在我们的生产机器上,parent_ids 都entity_idsales_flat_order_payment. 在我们的开发机器上,有些匹配,有些不匹配。这是可以预料的吗?

使用 magento 1.7.0.1 谢谢

4

1 回答 1

5

的输出show create table sales_flat_order_payment;是:

CONSTRAINT `FK_SALES_FLAT_ORDER_PAYMENT_PARENT_ID_SALES_FLAT_ORDER_ENTITY_ID` 
  FOREIGN KEY  (`parent_id`) REFERENCES `sales_flat_order` (`entity_id`) 
  ON DELETE CASCADE ON UPDATE CASCADE

意味着你是绝对正确的parent_identity_idsales_flat_order

于 2012-11-20T15:38:27.260 回答