--- CSC 365 Spring 2008
--- Lab 8 AIR dataset test 01


--- read AIR package

start BAKERY-package.sql

show errors

--- SQL queries involving new functions

--- note: I am using table names from "my" database: please adjust them to match your
---       table names

--- item_revenue()

--- query 1

 select distinct air.num_flights('AID') from
  flights;

--- query 2

 select distinct air.num_flights('AXG') from
  flights;



--- query 3


 select distinct air.num_flights('ANV') from
  flights;


--- query 4

select source, air.num_flights(source) as num
 from flights
 order by num
;


--- query 5

 select source 
 from flights
 where air.num_flights(source) > 17
;



