fix entry in resource mate file
[migration-tools.git] / mig-xml / resource_mate.xml
1 <reports_file>
2 <!-- sample reports entry
3     <report>
4         <name>name of report</name>
5         <iteration value='0' /> which version, the first version to run is 0, first backup is 1, then so on
6         <tag>money</tag>  arbitrary tags, each should go in separate tag
7         <report_title>Migrated Billings</report_title>  title used in the asciidoc output
8         <heading column='1'>Number of Billings.Migrated.Total</heading> period delimited 
9         <query>SELECT COUNT(id),x_migrate,SUM(amount) FROM money_billing_legacy GROUP BY 2;</query>  query itself, will be replaced
10         <note>Arbitrary note that can be included in the entries.</note>
11     </report>
12 -->
13     <!-- branches -->
14     <!-- circs -->
15
16     <report>
17         <name>rm_load_circ_count</name>
18         <tag>circs</tag>
19         <iteration>0</iteration>
20         <report_title>Circulations in Extract</report_title>
21         <heading>Count of Circs.Status</heading>
22         <query>SELECT COUNT(id), l_is_checked_out FROM asset_copy_legacy GROUP BY 2</query>
23     </report>
24
25
26     <!-- holds -->
27     <!-- assets -->
28
29    <report>
30         <name>rm_load_asset_by_resource_type</name>
31         <report_title>Count of Copies in Extract by Resource Type</report_title>
32         <tag>assets</tag>
33         <iteration>0</iteration>
34         <heading>Count.Resource Type</heading>
35         <query>SELECT COUNT(*), l_resource_type FROM asset_copy_legacy GROUP BY 2 ORDER BY 2</query>
36     </report>
37      
38    <report>
39         <name>rm_load_asset_by_location</name>
40         <report_title>Count of Copies in Extract by Location</report_title>
41         <tag>assets</tag>
42         <iteration>0</iteration>
43         <heading>Count.Location</heading>
44         <query>SELECT COUNT(*), l_location FROM asset_copy_legacy GROUP BY 2 ORDER BY 2</query>
45     </report>
46     
47     <report>
48         <name>rm_load_asset_by_category</name>
49         <report_title>Count of Copies in Extract by Category</report_title>
50         <tag>assets</tag>
51         <iteration>0</iteration>
52         <heading>Count.Category</heading>
53         <query>SELECT COUNT(*), l_category FROM asset_copy_legacy GROUP BY 2 ORDER BY 2</query>
54     </report>
55     
56     <report>
57         <name>rm_load_asset_by_status</name>
58         <report_title>Count of Copies in Extract by Status</report_title>
59         <tag>assets</tag>
60         <iteration>0</iteration>
61         <heading>Count.Location</heading>
62         <query>SELECT COUNT(*), l_status FROM asset_copy_legacy GROUP BY 2 ORDER BY 2</query>
63     </report>
64
65     
66     <!-- money -->
67
68
69    <report>
70         <name>rm_accounts_with_fines</name>
71         <report_title>Count of Accounts with a Grocery Bill to Migrate</report_title>
72         <tag>money</tag>
73         <iteration>0</iteration>
74         <heading>Count</heading>
75         <query>SELECT COUNT(*) FROM fines</query>
76     </report>
77
78    <report>
79         <name>rm_fine_w_no_account</name>
80         <report_title>Fines with No Matching Account</report_title>
81         <tag>money</tag>
82         <iteration>0</iteration>
83         <heading>First Name.Last Name.Fine Amount</heading>
84         <query>SELECT first_given_name, family_name, amount FROM fines WHERE au_id IS NULL ORDER BY 2, 1</query>
85     </report>
86              
87       <report>
88         <name>rm_fine_w_multi_matching</name>
89         <report_title>Fines with Multiple Matching Accounts</report_title>
90         <tag>money</tag>
91         <iteration>0</iteration>
92         <heading>First Name.Last Name.Fine Amount</heading>
93         <query>SELECT first_given_name, family_name, amount FROM fines WHERE multi_au IS TRUE ORDER BY 2, 1</query>
94     </report>
95      
96
97
98     <!-- bibs -->
99
100     <report>
101         <name>rm_load_bibs_loaded</name>
102         <report_title>Bibs Successfully Staged</report_title>
103         <tag>bibs</tag>
104         <iteration>0</iteration>
105         <heading>Count</heading>
106         <query>SELECT COUNT(eg) FROM bib_id_map</query>
107     </report>
108
109     <!-- actors -->
110
111     <report>
112         <name>rm_actor_address_summary</name>
113         <report_title>Patrons Address Components</report_title>
114         <tag>actors</tag>
115         <iteration>0</iteration>
116         <heading>Count.Address Component</heading>
117         <query>SELECT COUNT(id), 'Address 1' FROM actor_usr_legacy WHERE LENGTH(l_address_1) > 1
118             UNION ALL SELECT COUNT(id), 'Address 2' FROM actor_usr_legacy WHERE LENGTH(l_address_2) > 1
119             UNION ALL SELECT COUNT(id), 'City' FROM actor_usr_legacy WHERE LENGTH(l_city) > 1
120             UNION ALL SELECT COUNT(id), 'State' FROM actor_usr_legacy WHERE LENGTH(l_state) > 1
121             UNION ALL SELECT COUNT(id), 'County' FROM actor_usr_legacy WHERE LENGTH(l_country) > 1
122             UNION ALL SELECT COUNT(id), 'Zip Code' FROM actor_usr_legacy WHERE LENGTH(l_zip_code) > 1                    
123         </query>
124     </report>
125     
126     <report>
127         <name>rm_actor_expirations</name>
128         <report_title>Patrons by Year of Expiration</report_title>
129         <tag>actors</tag>
130         <iteration>0</iteration>
131         <heading>Count.Expiration Year</heading>
132         <query>SELECT COUNT(id), RIGHT(BTRIM(l_membership_expiry),4) FROM actor_usr_legacy GROUP BY 2 ORDER BY 2;       
133         </query>
134     </report>
135     
136     <report>
137         <name>rm_actor_barcodes</name>
138         <report_title>Patrons by Barcode Length</report_title>
139         <tag>actors</tag>
140         <iteration>0</iteration>
141         <heading>Count.Barcode Length</heading>
142         <query>SELECT COUNT(id), LENGTH(l_barcode) FROM actor_usr_legacy GROUP BY 2 ORDER BY 2;       
143         </query>
144     </report>
145   
146     <report>
147         <name>rm_actor_birthdates</name>
148         <report_title>Patrons with Birthdates</report_title>
149         <tag>actors</tag>
150         <iteration>0</iteration>
151         <heading>Count</heading>
152         <query>SELECT COUNT(id) FROM actor_usr_legacy WHERE LENGTH(l_birthdate) > 1;       
153         </query>
154     </report>
155
156     <report>
157         <name>rm_actor_groups</name>
158         <report_title>Patrons by User Groups</report_title>
159         <tag>actors</tag>
160         <iteration>0</iteration>
161         <heading>Count.Group</heading>
162         <query>SELECT COUNT(id), l_user_group FROM actor_usr_legacy GROUP BY 2 ORDER BY 2;       
163         </query>
164     </report>
165
166     <report>
167         <name>rm_actor_access</name>
168         <report_title>Patrons by Access Field</report_title>
169         <tag>actors</tag>
170         <iteration>0</iteration>
171         <heading>Count.Access</heading>
172         <query>SELECT COUNT(id), l_access_if_applicable FROM actor_usr_legacy GROUP BY 2 ORDER BY 2;       
173         </query>
174     </report>
175
176     <report>
177         <name>rm_actor_contact_summary</name>
178         <report_title>Patrons Contact Fields</report_title>
179         <tag>actors</tag>
180         <iteration>0</iteration>
181         <heading>Count.Address Component</heading>
182         <query>SELECT COUNT(id), 'email' FROM actor_usr_legacy WHERE LENGTH(l_e_mail) > 1
183             UNION ALL SELECT COUNT(id), 'Phone (home)' FROM actor_usr_legacy WHERE LENGTH(l_phone_home) > 1
184             UNION ALL SELECT COUNT(id), 'Phone (work)' FROM actor_usr_legacy WHERE LENGTH(l_phone_work) > 1
185             UNION ALL SELECT COUNT(id), 'Phone (cell)' FROM actor_usr_legacy WHERE LENGTH(l_phone_cell) > 1
186         </query>
187     </report> 
188   
189     <report>
190         <name>rm_actor_comments</name>
191         <report_title>Patrons Comments Count and Sample</report_title>
192         <tag>actors</tag>
193         <iteration>0</iteration>
194         <heading>Count.Sample</heading>
195         <query>SELECT COUNT(id), 'All Comments' FROM actor_usr_legacy WHERE LENGTH(l_comments) > 1
196             UNION ALL SELECT NULL, l_comments FROM  actor_usr_legacy WHERE LENGTH(l_comments) > 1 LIMIT 10
197         </query>
198     </report> 
199     
200     <report>
201         <name>rm_actor_circulation_note</name>
202         <report_title>Patrons Circulation Notes Count and Sample</report_title>
203         <tag>actors</tag>
204         <iteration>0</iteration>
205         <heading>Count.Sample</heading>
206         <query>SELECT COUNT(id), 'All Notes' FROM actor_usr_legacy WHERE LENGTH(l_circulation_note) > 1
207             UNION ALL SELECT NULL, l_circulation_note FROM  actor_usr_legacy WHERE LENGTH(l_circulation_note) > 1 LIMIT 10
208         </query>
209     </report>       
210 </reports_file>
211