Exporting CAD Data

 

Often times it is desired that Crimestar CAD interface to external systems for the purpose of providing real-time or semi-real-time event and unit data to those external systems.  All Crimestar CAD event and unit history data is stored within two (2) tables (calls_for_service & cfs_units) of the Crimestar RMS database.  Both of these tables are easily accessible and can be queried by external applications providing that programmatic access to these database tables is allowed by the host agency.

There are a few potential problems with external systems directly querying the Crimestar database to obtain information.  Firstly, the external system must poll or periodically scan the entire table(s) within the database because it has no real way of knowing what data may have been recently added or modified.  This periodic scanning of the entire CAD table(s) can have a serious performance impact on the host agency’s system causing it to slow as the database is busy with these tables being repeatedly queried.

In response to this situation Crimestar CAD offers a real-time event XML record export directly from the CAD software.  When activated at a CAD workstation, the software will, upon closing a CAD event record, create an XML data file which contains the entire CAD event record as well as all unit data related to that specific CAD event.  The XML file is saved to any network directory or folder that you specify.  The most common location for these files would be to place them into a shared directory or folder that can be polled or monitored by external systems.  This allows the external system to simply check a specific folder or system location to obtain any new or modified data without the need to directly access the host database or perform and extensive searches that may impact performance.

To activate the CAD XML file export, the host agency need only modify the [CAD] section of the Crimestar INI file on each CAD workstation where closed event records are to be exported.  The INI file entries are specified in Appendix “B” and are as follows:

CAD_EVENT_XML=ON/OFF                  (default is OFF)
CAD_XML_PATH=C:\SHAREDFOLDER

Due to the additional data processing involved, turning this option on will cause a slight delay (less than a second) in the time it takes a CAD workstation to close the event.  

The following is a sample of a CAD Event XML output file:
 

<?xml version="1.0" encoding="Windows-1252" standalone="yes" ?>
<CRIMESTAR>

<cad_event>

<cfs_index>2749415.0240</cfs_index>
<event_no>0901130002</event_no>
<incident_no>09000018</incident_no>
<call_type>BURGLARY</call_type>
<event_type>P</event_type>
<agency>AMB</agency>
<priority>3</priority>
<date_reported>2009-01-13</date_reported>
<time_reported>09:52:17</time_reported>
<call_source>9</call_source>
<datetime_rpt>2009-01-13T09:52:17</datetime_rpt>
<location_index>0.0000</location_index>
<location>123 W MAIN STREET</location>
<digits>123</digits>
<dir>W</dir>
<street>MAIN</street>
<st_type>ST</st_type>
<suffix> E</suffix>
<apartment>22A</apartment>
<city>SAN JOSE</city>
<county>NAPA</county>
<beat>03</beat>
<sector>07</sector>
<district>10</district>
<latitude>0</latitude>
<longitude>0</longitude>
<description>Victim returned home, window broken, items missing</description>
<rep_party>Smith, Robert</rep_party>
<last_name>Smith</last_name>
<first_name>Robert</first_name>
<middle_name />
<mni_index>0.0000</mni_index>
<invl_index>0.0000</invl_index>
<rp_location>123 W MAIN STREET</rp_location>
<rp_area>408</rp_area>
<rp_phone>555-1212</rp_phone>
<req_contact>true</req_contact>
<pri_unit>006</pri_unit>
<officer_id/> L21</officer_id>
<sec_unit />
<officer_id2 />
<dispatcher>A821</dispatcher>
<time_disp>2009-01-13T09:52:17</time_disp>
<time_disp2 />
<time_enroute />
<time_enroute2 />
<time_arrive>2009-01-13T09:52:17</time_arrive>
<time_arrive2 />
<time_clear>2009-01-13T09:53:41</time_clear>
<time_clear2 />
<total_consumed>24</total_consumed>
<disposition>RPT</disposition>
<disp_cmnts>Victim will call with additional property information</disp_cmnts>
<press_release>true</press_release>
<emd_code>NA<emd_code />
<updt_oper />
<fincident_no />
<mincident_no />
<ent_oper>A821</ent_oper>
<date_enter>2009-01-13</date_enter>
<date_updt>2009-01-13T09:53:42</date_updt>
<modify_flag>true</modify_flag>
<rec_lock>0</rec_lock>
<unit_data>

<event_units>

<unit_id>006</unit_id>
<ustatus>D</ustatus>
<officer_id />L21</officer_id>
<officer_id2 />
<veh_id />
<ulocation>123 W MAIN STREET</ulocation>
<ucomment>NO LIGHTS</ucomment>
<oper_id>A821</oper_id>
<date_updt>2009-01-13T09:52:17</date_updt>

</event_units>
<event_units>

<unit_id>006</unit_id>
<ustatus>A</ustatus>
<officer_id />L21</officer_id>
<officer_id2 />
<veh_id />
<ulocation>123 W MAIN STREET</ulocation>
<ucomment>NO LIGHTS</ucomment>
<oper_id>A821</oper_id>
<date_updt>2009-01-13T09:59:11</date_updt>

</event_units>
<event_units>

<unit_id>006</unit_id>
<ustatus>CL</ustatus>
<officer_id />L21</officer_id>
<officer_id2 />
<veh_id />
<ulocation>123 W MAIN STREET</ulocation>
<ucomment>Victim Will Call</ucomment>
<oper_id>A821</oper_id>
<date_updt>2009-01-13T10:23:31</date_updt>

 

</event_units>

</unit_data>

 

</cad_event>

</CRIMESTAR>