CRM-15168 stdise whitespace across schema xml to make editing easier
[civicrm-core.git] / xml / schema / Contact / Household.xml
CommitLineData
6a488035
TO
1<?xml version="1.0" encoding="iso-8859-1" ?>
2
3<table>
4 <base>CRM/Contact</base>
5 <class>Household</class>
6 <name>civicrm_household</name>
7 <comment>Define household specific properties</comment>
8 <add>1.1</add>
9 <log>true</log>
10 <field>
8f069c03
EM
11 <name>id</name>
12 <type>int unsigned</type>
13 <required>true</required>
14 <comment>Unique Household ID</comment>
15 <add>1.1</add>
6a488035
TO
16 </field>
17 <primaryKey>
8f069c03
EM
18 <name>id</name>
19 <autoincrement>true</autoincrement>
6a488035
TO
20 </primaryKey>
21 <field>
8f069c03
EM
22 <name>contact_id</name>
23 <type>int unsigned</type>
24 <required>true</required>
25 <comment>FK to Contact ID</comment>
26 <add>1.1</add>
6a488035
TO
27 </field>
28 <foreignKey>
8f069c03
EM
29 <name>contact_id</name>
30 <table>civicrm_contact</table>
31 <key>id</key>
32 <add>1.1</add>
6a488035
TO
33 </foreignKey>
34 <field>
8f069c03
EM
35 <name>household_name</name>
36 <type>varchar</type>
37 <length>128</length>
38 <import>true</import>
39 <headerPattern>/^household|(h(ousehold\s)?name)$/i</headerPattern>
40 <dataPattern>/^\w+$/</dataPattern>
41 <comment>Household Name.</comment>
42 <fulltext/>
43 <add>1.1</add>
6a488035
TO
44 </field>
45 <index>
8f069c03
EM
46 <name>index_household_name</name>
47 <fieldName>household_name</fieldName>
48 <add>1.8</add>
6a488035
TO
49 </index>
50 <field>
8f069c03
EM
51 <name>primary_contact_id</name>
52 <type>int unsigned</type>
53 <comment>Optional FK to Primary Contact for this household.</comment>
54 <add>1.1</add>
6a488035
TO
55 </field>
56 <foreignKey>
8f069c03
EM
57 <name>primary_contact_id</name>
58 <table>civicrm_contact</table>
59 <key>id</key>
60 <add>1.1</add>
6a488035
TO
61 </foreignKey>
62 <index>
63 <name>UI_contact</name>
64 <fieldName>contact_id</fieldName>
65 <unique>true</unique>
66 <add>1.6</add>
67 </index>
68</table>