<commit_before>#!/bin/sh
# /cronjobs/set_itemtype.sh
# update itemtype based on mediaType,format

RES="`cat <<-EOF | koha-mysql $(koha-list --enabled) --default-character-set=utf8 -N 2>&1

    UPDATE biblioitems
JOIN (
    SELECT biblionumber, CASE
    WHEN mediatype='Lydbok' THEN 'LYDBOK'
    WHEN mediatype='Bok' THEN 'BOK'
    WHEN mediatype='Tegneserie' THEN 'BOK'
    WHEN mediatype='E-bok' THEN 'BOK'
    WHEN mediatype='Film' THEN 'FILM'
    WHEN mediatype='Spill' THEN 'SPILL'<commit_msg>itemtype cronjob: BOK -> EBOK<commit_after>#!/bin/sh
# /cronjobs/set_itemtype.sh
# update itemtype based on mediaType,format

RES="`cat <<-EOF | koha-mysql $(koha-list --enabled) --default-character-set=utf8 -N 2>&1

    UPDATE biblioitems
JOIN (
    SELECT biblionumber, CASE
    WHEN mediatype='Lydbok' THEN 'LYDBOK'
    WHEN mediatype='Bok' THEN 'BOK'
    WHEN mediatype='Tegneserie' THEN 'BOK'
    WHEN mediatype='E-bok' THEN 'EBOK'
    WHEN mediatype='Film' THEN 'FILM'
    WHEN mediatype='Spill' THEN 'SPILL'
{'fraction_non_alphanumeric': 0.13748763600395647, 'fraction_numerical': 0.005934718100890208, 'mean_word_length': 4.00990099009901, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 6, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '2861109', 'n_tokens_mistral': 438, 'n_tokens_neox': 395, 'n_words': 92}