| /* |
| * Licensed to the Apache Software Foundation (ASF) under one |
| * or more contributor license agreements. See the NOTICE file |
| * distributed with this work for additional information |
| * regarding copyright ownership. The ASF licenses this file |
| * to you under the Apache License, Version 2.0 (the |
| * "License"); you may not use this file except in compliance |
| * with the License. You may obtain a copy of the License at |
| * |
| * http://www.apache.org/licenses/LICENSE-2.0 |
| * |
| * Unless required by applicable law or agreed to in writing, |
| * software distributed under the License is distributed on an |
| * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY |
| * KIND, either express or implied. See the License for the |
| * specific language governing permissions and limitations |
| * under the License. |
| */ |
| /* |
| * Description : Disasters with friends |
| * Expected Res : Success |
| * Date : May 17 |
| * Author : Steven Jacobs |
| */ |
| |
| use channels; |
| upsert into UserLocations([ |
| {"user_id":1, "latitude":5, "longitude":5, "timestamp":current_datetime()}, |
| {"user_id":2, "latitude":10, "longitude":10, "timestamp":current_datetime()}, |
| {"user_id":3, "latitude":15, "longitude":15, "timestamp":current_datetime()}] |
| ); |
| upsert into EmergencyShelters([ |
| {"name":"A", "location":create_point(5.0,5.0)}, |
| {"name":"B", "location":create_point(10.0,10.0)}, |
| {"name":"C", "location":create_point(15.0,15.0)}] |
| ); |
| upsert into EmergencyReports([ |
| {"emergencyType":"tornado", "impactZone":create_circle(create_point(5.0,6.0), 10.0), "timestamp":current_datetime()}, |
| {"emergencyType":"flood", "impactZone":create_circle(create_point(5.0,6.0), 5.0), "timestamp":current_datetime()}, |
| {"emergencyType":"tornado", "impactZone":create_circle(create_point(30.0,70.0), 5.0), "timestamp":current_datetime()}] |
| ); |