CRM-13497 - getting there on main tables
[civicrm-core.git] / xml / schema / Campaign / CampaignGroup.xml
CommitLineData
6a488035
TO
1<?xml version="1.0" encoding="iso-8859-1" ?>
2<table>
3 <base>CRM/Campaign</base>
4 <class>CampaignGroup</class>
5 <name>civicrm_campaign_group</name>
6 <comment>Campaign Group Details.</comment>
7 <add>3.3</add>
3c7d2158 8
6a488035
TO
9 <field>
10 <name>id</name>
11 <type>int unsigned</type>
12 <required>true</required>
13 <comment>Campaign Group id.</comment>
14 <add>3.3</add>
15 </field>
16 <primaryKey>
17 <name>id</name>
18 <autoincrement>true</autoincrement>
19 </primaryKey>
3c7d2158 20
6a488035
TO
21 <field>
22 <name>campaign_id</name>
23 <type>int unsigned</type>
24 <required>true</required>
25 <comment>Foreign key to the activity Campaign.</comment>
26 <add>3.3</add>
27 </field>
28 <foreignKey>
29 <name>campaign_id</name>
30 <table>civicrm_campaign</table>
31 <key>id</key>
32 <add>3.3</add>
33 <onDelete>CASCADE</onDelete>
34 </foreignKey>
35
36 <field>
37 <name>group_type</name>
38 <type>enum</type>
39 <values>Include, Exclude</values>
40 <default>NULL</default>
41 <comment>Type of Group.</comment>
614d72ec 42 <html>
43 <type>Select</type>
44 </html>
6a488035
TO
45 </field>
46
3c7d2158 47 <field>
6a488035
TO
48 <name>entity_table</name>
49 <type>varchar</type>
3c7d2158 50 <length>64</length>
6a488035
TO
51 <default>NULL</default>
52 <comment>Name of table where item being referenced is stored.</comment>
53 <add>3.3</add>
54 </field>
55
56 <field>
57 <name>entity_id</name>
58 <type>int unsigned</type>
59 <default>NULL</default>
60 <comment>Entity id of referenced table.</comment>
61 <add>3.3</add>
62 </field>
71e5aa5c
ARW
63
64 <dynamicForeignKey>
65 <idColumn>entity_id</idColumn>
66 <typeColumn>entity_table</typeColumn>
67 <add>3.3</add>
68 </dynamicForeignKey>
6a488035 69</table>