-- DBMS: bigquery
CREATE TABLE `bigquery-public-data.new_york_taxi_trips.tlc_yellow_trips_2020`
(
  vendor_id STRING NOT NULL OPTIONS(description="A code indicating the LPEP provider that provided the record. 1= Creative Mobile Technologies, LLC; 2= VeriFone Inc."),
  pickup_datetime TIMESTAMP OPTIONS(description="The date and time when the meter was engaged"),
  dropoff_datetime TIMESTAMP OPTIONS(description="The date and time when the meter was disengaged"),
  passenger_count INT64 OPTIONS(description="The number of passengers in the vehicle. This is a driver-entered value."),
  trip_distance NUMERIC OPTIONS(description="The elapsed trip distance in miles reported by the taximeter."),
  rate_code STRING OPTIONS(description="The final rate code in effect at the end of the trip. 1= Standard rate 2=JFK 3=Newark 4=Nassau or Westchester 5=Negotiated fare 6=Group ride"),
  store_and_fwd_flag STRING OPTIONS(description="This flag indicates whether the trip record was held in vehicle memory before sending to the vendor, aka 'store and forward,' because the vehicle did not have a connection to the server. Y= store and forward trip N= not a store and forward trip"),
  payment_type STRING OPTIONS(description="A numeric code signifying how the passenger paid for the trip. 1= Credit card 2= Cash 3= No charge 4= Dispute 5= Unknown 6= Voided trip"),
  fare_amount NUMERIC OPTIONS(description="The time-and-distance fare calculated by the meter"),
  extra NUMERIC OPTIONS(description="Miscellaneous extras and surcharges. Currently, this only includes the $0.50 and $1 rush hour and overnight charges"),
  mta_tax NUMERIC OPTIONS(description="$0.50 MTA tax that is automatically triggered based on the metered rate in use"),
  tip_amount NUMERIC OPTIONS(description="Tip amount. This field is automatically populated for credit card tips. Cash tips are not included."),
  tolls_amount NUMERIC OPTIONS(description="Total amount of all tolls paid in trip."),
  imp_surcharge NUMERIC OPTIONS(description="$0.30 improvement surcharge assessed on hailed trips at the flag drop. The improvement surcharge began being levied in 2015."),
  airport_fee NUMERIC OPTIONS(description=""),
  total_amount NUMERIC OPTIONS(description="The total amount charged to passengers. Does not include cash tips."),
  pickup_location_id STRING OPTIONS(description="TLC Taxi Zone in which the taximeter was engaged"),
  dropoff_location_id STRING OPTIONS(description="TLC Taxi Zone in which the taximeter was disengaged"),
  data_file_year INT64 OPTIONS(description="Datafile timestamp year value"),
  data_file_month INT64 OPTIONS(description="Datafile timestamp month value")
);

INSERT INTO `bigquery-public-data.new_york_taxi_trips.tlc_yellow_trips_2020` (vendor_id, pickup_datetime, dropoff_datetime, passenger_count, trip_distance, rate_code, store_and_fwd_flag, payment_type, fare_amount, extra, mta_tax, tip_amount, tolls_amount, imp_surcharge, airport_fee, total_amount, pickup_location_id, dropoff_location_id, data_file_year, data_file_month) VALUES ('2', '2020-10-01 00:32:39+00:00', '2020-10-01 00:51:27+00:00', 5, '7.620000000', '1.0', 'N', '1', '23.500000000', '0.500000000', '0.500000000', '6.820000000', '0E-9', '0.300000000', NULL, '34.120000000', '144', '75', 2020, 10), ('1', '2020-10-01 00:08:14+00:00', '2020-10-01 00:36:24+00:00', 1, '13.400000000', '1.0', 'N', '1', '36.000000000', '3.000000000', '0.500000000', '9.900000000', '0E-9', '0.300000000', NULL, '49.700000000', '141', '89', 2020, 10), ('2', '2020-10-01 00:22:00+00:00', '2020-10-01 00:44:26+00:00', 1, '6.530000000', '1.0', 'N', '1', '22.000000000', '0.500000000', '0.500000000', '5.160000000', '0E-9', '0.300000000', NULL, '30.960000000', '161', '181', 2020, 10), ('2', '2020-10-01 00:18:57+00:00', '2020-10-01 00:38:51+00:00', 1, '7.440000000', '1.0', 'N', '1', '24.000000000', '0.500000000', '0.500000000', '7.590000000', '0E-9', '0.300000000', NULL, '32.890000000', '132', '258', 2020, 10), ('2', '2020-10-01 00:51:29+00:00', '2020-10-01 00:51:39+00:00', 1, '0E-9', '5.0', 'N', '1', '20.000000000', '0E-9', '0.500000000', '4.160000000', '0E-9', '0.300000000', NULL, '24.960000000', '139', '139', 2020, 10);