From 668cac4d1b992742db942dc3a086d8089a1da97d Mon Sep 17 00:00:00 2001 From: rey jean-Francois Date: Mon, 29 Jul 2013 16:43:25 +0200 Subject: [PATCH] check if solr quieres is empty --- main_tools/ExploitConfidencePass.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/main_tools/ExploitConfidencePass.sh b/main_tools/ExploitConfidencePass.sh index e2590ea..01b5410 100755 --- a/main_tools/ExploitConfidencePass.sh +++ b/main_tools/ExploitConfidencePass.sh @@ -227,10 +227,10 @@ do datePattern=`$SCRIPT_PATH/daybefore2after.sh $(echo $BASENAME | cut -c1-6)` # Create SOLR queries cat $SHOW_DIR/$bn".confzone" | $SCRIPT_PATH/GenerateSOLRQueries.pl | iconv -f ISO_8859-1 -t UTF-8 > "$SHOW_DIR/$bn.queries" - query=$(cat $SHOW_DIR/$bn.queries)"&fq=docDate:[$datePattern]" - echo $query > $SHOW_DIR/$bn.queries # Ask SOLR DB if [ $(wc -w "$SHOW_DIR/$bn.queries" | cut -f1 -d' ') -gt 0 ]; then + query=$(cat $SHOW_DIR/$bn.queries)"&fq=docDate:[$datePattern]" + echo $query > $SHOW_DIR/$bn.queries python $SCRIPT_PATH/ProcessSOLRQueries.py $SHOW_DIR/$bn.queries $SOLR_RES/$bn.keywords.tmp $SOLR_RES/$bn.txt.tmp cat $SOLR_RES/$bn.keywords.tmp | sort -u > $SOLR_RES/$bn.keywords cat $SOLR_RES/$bn.txt.tmp | sort -u > $SOLR_RES/$bn.txt -- 1.8.2.3