From d23409f1101a1a0b97963df53d0fff16f3f40e08 Mon Sep 17 00:00:00 2001 From: root Date: Wed, 11 Sep 2013 14:59:42 +1000 Subject: [PATCH] Correctly get the limesurvey id --- functions/functions.operator.php | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/functions/functions.operator.php b/functions/functions.operator.php index ead1f671..256709d5 100644 --- a/functions/functions.operator.php +++ b/functions/functions.operator.php @@ -428,7 +428,11 @@ function add_case($sample_id,$questionnaire_id,$operator_id = "NULL",$testing = if (!$db->HasFailedTrans()) //if the transaction hasn't failed { - $lime_sid = get_limesurvey_id($operator_id); + $sql = "SELECT lime_sid + FROM questionnaire + WHERE questionnaire_id = '$questionnaire_id'"; + + $lime_sid = $db->GetOne($sql); if ($lime_sid) {