Collection Analysis
for $5 a Month. CHEAP
https://rayvoelker.github.io/iug2022/
https://collection-analysis.cincy.pl/
Ray Voelker
ray.voelker@gmail.com | ray.voelker@cincinnatilibrary.org
datasette publish that can package and deploy to services like Heroku or Google Cloud)https://docs.datasette.io/en/stable/deploying.html#deployment-fundamentals
Scripts For Extracting Data From ILS (Sierra)
https://github.com/cincinnatilibrary/collection-analysis
Downloadable Audiobook, Downloadable Book, Downloadable Video, Downloadable Music, Web Document
select
item.location_code,
l.location_name,
l.branch_name,
count(*) as count_items,
'https://collection-analysis.cincy.pl/current_collection/'
|| 'item_view?location_code__exact='
|| item.location_code as items_link
from
item
join location_view as l on l.location_code = item.location_code
where branch_name = :branch_name
group by 1, 2, 3
run this query
Named parameters: Datasette provides a nice interface when a named parameter is placed within a SQL query
where
(
select
value
from
json_each(bib.indexed_subjects)
) like '%' || :subject_like || '%'
# Datasette URI construction
scheme = "https://"
host = "collection-analysis.cincy.pl"
# path contains the name of the database
path = "/current_collection"
# this is either a table, view, or canned query
canned_query_path = "/item_view"
response_format = '' # '' or '.csv' or '.json'
query_parameter = "?barcode__exact="
query_parameter_value = "A000036107985"
full_request_uri = scheme + host \
+ path + canned_query_path + response_format \
+ query_parameter + query_parameter_value
Thanks, and PLEASE, let me know if you come up with any cool queries, ❤️ Datasette as much as I do, or want to use this at your library!
Ray Voelker
ray.voelker@gmail.com
ray.voelker@cincinnatilibrary.org