4if [ -z $JPP_DIR ]; then
 
    5    echo "Variable JPP_DIR undefined."
 
    9source $JPP_DIR/setenv.sh $JPP_DIR  >&  /dev/null
 
   11set_variable:  DEBUG     DATABASE_DEBUG      2
 
   12set_variable:  WORKDIR   DATABASE_WORKDIR    `pwd`
 
   15    usage "$script <detector identifier> <run>[-<run>] [source [parameter]]"
 
   19    4)  set_variable  PARAMETER      $4;&
 
   20    3)  set_variable  SOURCE         $3;&
 
   21    2)  set_variable  RUNS           $2;
 
   22        set_variable  DETID          $1;;
 
   23    *)  fatal "Invalid number of arguments."
 
   26set_variable  DETID        `getDetector -D $DETID -O string`
 
   27set_variable  FILENAME     $WORKDIR/${DETID}_${RUNS}${SOURCE+.}${SOURCE}.log
 
   34if [[ -n "$SOURCE"    ]]; then; SELECTOR+="source_name=$SOURCE";       fi
 
   35if [[ -n "$PARAMETER" ]]; then; SELECTOR+="parameter_name=$PARAMETER"; fi
 
   37if [[ ! -f ${FILENAME}.gz ]]; then
 
   40        --load-cookies=$HOME/.km3netdb_cookie                                         \
 
   41        --secure-protocol=TLSv1_2                                                     \
 
   42        "https://km3netdbweb.in2p3.fr/streamds/datalogstrings.txt?${(j:&:)SELECTOR}"  \
 
   47    if (( $? == 0 )) && [[ `head ${FILENAME}` != "ERROR: "* ]]; then