Merge pull request #4252 from civicrm/4.4
[civicrm-core.git] / xml / schema / Contact / SavedSearch.xml
1 <?xml version="1.0" encoding="iso-8859-1" ?>
2
3 <table>
4 <base>CRM/Contact</base>
5 <class>SavedSearch</class>
6 <name>civicrm_saved_search</name>
7 <comment>Users can save their complex SQL queries and use them later.</comment>
8 <add>1.1</add>
9 <field>
10 <name>id</name>
11 <type>int unsigned</type>
12 <required>true</required>
13 <comment>Saved search ID</comment>
14 <add>1.1</add>
15 </field>
16 <primaryKey>
17 <name>id</name>
18 <autoincrement>false</autoincrement>
19 </primaryKey>
20 <field>
21 <name>query</name>
22 <title>SQL Query</title>
23 <type>text</type>
24 <import>true</import>
25 <comment>SQL query for this search</comment>
26 <add>1.1</add>
27 <drop>1.5</drop>
28 </field>
29 <field>
30 <name>form_values</name>
31 <title>Submitted Form Values</title>
32 <type>text</type>
33 <import>true</import>
34 <comment>Submitted form values for this search</comment>
35 <add>1.1</add>
36 </field>
37 <field>
38 <name>is_active</name>
39 <type>boolean</type>
40 <comment>Is this entry active?</comment>
41 <add>1.1</add>
42 <drop>1.5</drop>
43 </field>
44 <field>
45 <name>mapping_id</name>
46 <type>int unsigned</type>
47 <comment>Foreign key to civicrm_mapping used for saved search-builder searches.</comment>
48 <add>1.5</add>
49 </field>
50 <foreignKey>
51 <name>mapping_id</name>
52 <table>civicrm_mapping</table>
53 <key>id</key>
54 <add>1.5</add>
55 </foreignKey>
56 <field>
57 <name>search_custom_id</name>
58 <type>int unsigned</type>
59 <comment>Foreign key to civicrm_option value table used for saved custom searches.</comment>
60 <add>2.0</add>
61 </field>
62 <field>
63 <name>where_clause</name>
64 <type>text</type>
65 <comment>the sql where clause if a saved search acl</comment>
66 <add>1.6</add>
67 </field>
68 <field>
69 <name>select_tables</name>
70 <type>text</type>
71 <comment>the tables to be included in a select data</comment>
72 <add>1.6</add>
73 </field>
74 <field>
75 <name>where_tables</name>
76 <type>text</type>
77 <comment>the tables to be included in the count statement</comment>
78 <add>1.6</add>
79 </field>
80 </table>