﻿{"VERSION": "1",
 "CONFIG": ["vf","200","50","1","5000","20","https://{s}.tile.openstreetmap.org/{z}/{x}/{y}.png","Tiles (c) OpenStreetMap","","Query String","START"],
 "TABLES": {
  "VF_TABLES": [
   ["URL","HAZARDS",null,"text/csv; charset=utf-8","https://data.sfgov.org/api/v3/views/re79-p8j5/query.csv","UTF-8",",","","\"","",0,1,1,0,null,null,"300","X-App-Token","WFcphN3Ea8iFSlqDd7X7TpHb6","","",320],
   ["URL","SCHOOLS",null,"text/csv; charset=utf-8","https://data.sfgov.org/api/v3/views/7e7j-59qk/query.csv","UTF-8",",","","\"","",0,1,1,0,null,null,"300","X-App-Token","WFcphN3Ea8iFSlqDd7X7TpHb6","","",310]
  ],
  "VF_SQL": [
   ["Dropping Schools Hazards cross join",340,"drop table if exists schools_hazards\n"],
   ["Dropping Map View",370,"drop view if exists map_view;"],
   ["Creating Map View",380,"create view if not exists map_view\nas\nselect s.*,\n       'Hazard Zone ID:'||h.id as tooltip\nfrom schools s,\n     hazards h,\n     schools_hazards j\nwhere j.schools_rowid = s.rowid and\n      j.hazards_rowid = h.rowid and\n      j.rowid in \n       (select src_rowid\n        from schools_hazard_result\n        where result = 'true');"],
   ["Creating Schools Hazards cross join",350,"create table if not exists schools_hazards\nas\nselect s.rowid as schools_rowid,\n       s.\"point\" as the_point,\n       h.rowid as hazards_rowid,\n       h.the_geom as the_polygon\nfrom schools s,\n     hazards h;"]
  ],
  "VF_SEQUENCE": [
   ["Schools Hazards",300,"310,320,340,350,360,370,380,390"]
  ],
  "VF_PROMPT_INPUT": [
  ],
  "VF_CUSTOM_FUNCTION": [
   ["Performing Point in Polygon test","schools_hazards",2390,"schools_hazard_result",0,360]
  ],
  "VF_CUSTOM_FUNCTION_PARAMETER": [
   ["Performing Point in Polygon test",0,"Column Value","the_point"],
   ["Performing Point in Polygon test",1,"Column Value","the_polygon"],
   ["Performing Point in Polygon test",2,"Literal Constant","false"]
  ],
  "VF_RUN_MENU": [
   ["Schools Hazard","",300,""]
  ],
  "VF_TABLE_VISUALIZATION": [
  ],
  "VF_CHART_VISUALIZATION": [
  ],
  "VF_MAP_VISUALIZATION": [
   ["Schools Seismic Map Visualization","map_view",null,"Literal Constant","SF Schools in Seismic Hazard Zones",390,"","point","Column Value","tooltip","radius","regular","Literal Constant","6","radius","regular","Literal Constant","","radius","regular","Literal Constant","","radius","regular","Literal Constant","","radius","regular","Literal Constant","","radius","regular","Literal Constant","","","Drilldown",0,null,null,null]
  ],
  "VF_NETWORK_VISUALIZATION": [
  ],
  "VF_HEATMAP_VISUALIZATION": [
  ],
  "VF_MEDIA_VISUALIZATION": [
  ]
 }
}
