q_fish_ticket.Rd
query fish ticket data
q_fish_ticket(
year,
species,
area,
db,
add_fields = NULL,
print_sql = FALSE,
save = TRUE
)
max year to query through (and location to save results)
species group code e.g., "DUSK"
fmp_area (GOA, BSAI) or fmp_subarea (BS, AI, WG, CG, WY, EY, SE) - also available (SEI, PWSI), can use all fmp_areas or all fmp_subareas, but don't mix the two
data server to connect to (akfin)
add other columns to the database (must currently exist on server). "*" will return all table columns available
outputs the sql query instead of calling the data - save must be false
saves a file to the data/raw folder, otherwise sends output to global enviro (default: TRUE)
saves fish ticket data as data/raw/fishticket_data.csv or outputs to the global environment, save also saves a copy of the SQL code used for the query and stores it in the data/sql folder.
if (FALSE) {
q_fish_ticket(year=2022, species="NORK", area="goa", db=db)
}