public ArrayList<Franchise> GetAllFranchises()
            throws UnauthorizedUserException, BadConnectionException, DoubleEntryException
    {
        Statement statment = null;
        ResultSet results = null;
        String statString = "SELECT * FROM Franchise WHERE Active = 'Y'";

        ArrayList<Franchise> BPList = new ArrayList<Franchise>();
        
        try {
            statment = con.createStatement();
            results = statment.executeQuery(statString);
                        
            while (results.next())
            {
                Franchise temp = new Franchise();
                    
                temp.setAddress(results.getString("Address"));
                temp.setAirportID(results.getInt("AirportID"));
                temp.setCity(results.getString("City"));
                temp.setEmail(results.getString("Email"));
                temp.setFranchiseID(results.getInt("FranchiseNumber"));
                temp.setPhone(results.getString("Phone"));
                temp.setState(results.getString("State"));
                temp.setZip(results.getInt("Zip"));
                    
                BPList.add(temp);
           }
           
        }catch(SQLException sqlE) {
            if(sqlE.getErrorCode() == 1142)
                throw(new UnauthorizedUserException("AccessDenied"));
            else if(sqlE.getErrorCode() == 1062)
                throw(new DoubleEntryException("DoubleEntry"));
            else 
                throw(new BadConnectionException("BadConnection"));
        }
        finally {
            try {
                if (results != null) results.close();
            }catch (Exception e) {};
            try {
                if (statment != null) statment.close();
            }catch (Exception e) {};
        }
                  
        return BPList;
 }// end GetAllFranchises