Commit 64e1f6e4 authored by gnat's avatar gnat

added another schema example with onDelete: CASCADE

generalized a connection example to use user:pass instead of jwage:pass...
parent c456e4c7
...@@ -108,10 +108,40 @@ GroupUser: ...@@ -108,10 +108,40 @@ GroupUser:
primary: true primary: true
</code> </code>
+++ One to One Aggregate
<code type="yaml">
---
User:
columns:
id:
type: integer(4)
primary: true
autoincrement: true
contact_id:
type: integer(4)
username:
type: string(255)
password:
type: string(255)
relations:
Contact:
foreignType: one
onDelete: CASCADE
Contact:
columns:
id:
type: integer(4)
primary: true
autoincrement: true
name:
type: string(255)
</code>
++ Connection Binding ++ Connection Binding
<code type="php"> <code type="php">
Doctrine::connection('mysql://jwage:pass@localhost/connection1', 'connection1'); Doctrine::connection('mysql://user:pass@localhost/connection1', 'connection1');
</code> </code>
<code type="yaml"> <code type="yaml">
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment