Create the Tasks to download the Police data

We need to create a Workflow Task to import each of the different types of Police data into the PostgreSQL database.

  • Right click on the Jobs entry you have just created to Refresh Police Data in the tree and select New Task.
  • We need to specify Spatial Data Transformation as the task type and click OK.

  • Enter the following information:

Task Name

Enter a Name for the task.  In the above example we have chosen NeighbourhoodEvents.

Source Data

Here you need to select the WFS Workflow Connection you have just created.

Table

Here you need to select the correct table for the type of Police data that you wish to extract. The options are:

      • neighbourhood_events
      • neighbourhood_teams
      • neighbourhood_centroids
      • neighbourhood_locations
      • street_outcomes
      • street_crimes
      • streetcrime_crosstab
      • neighbourhood_crimes
      • neighbourhood_boundaries

We have chosen neighbourhood_events in our example.

Note

If there is no drop down selection then it is possible that you are missing the errorconfig.xml file from your Studio\config folder.


Output

In this instance will want to output to the PostgreSQL database so select then name of your Data Share database.

Table

Enter a name for the Table that you wish to create in the PostgreSQL database. If you leave this blank it will default to the Source table name.

Input encoding

Select UTF8 from the drop down selection.

Expert mode

For each Spatial Data Transformation task, be sure to add a parameter limiting the download to your spatial area. Tick the Show expert mode box and add the following in the Additional parameters box, substituting your bounding box values where appropriate:

Syntax
-spat xmin ymin xmax ymax 
  • Click Save to update the Studio with your changes.

 

Although we have created the Workflow Task to import the data from the WFS Feed we need to actually Run the task to import the data.

  • Either click on the Run button  or Right Click on the Task you have just created and select Run Task NeighbourhoodEvents or whatever you have called it. This may take a little while but you should see a successful completion message when the download has finished. This will import the WFS feed into the specified table.
  • Now you need to repeat this step to create a Spatial Data Transformation Task for each type of Police datasets that you wish to download and display.