1 Reply Latest reply on Nov 17, 2008 4:04 PM by Günter Schenk

    Problem filtering on dynamic list column.


      I have a big problem with a dynamic list...

      My full SQL statement is pasted below but my first select is..

      "SELECT CONCAT(jobs.job_stamp, jobs.job_id) AS job_ref"

      This is okay for returning the basic data but when I want to filter on this column I get an error...

      "Unknown column 'job_ref' in 'where clause"

      Can anyone help, please?

      Ta Paul

      $query_rsTest = "SELECT CONCAT(jobs.job_stamp, jobs.job_id) AS job_ref, jobs.job_id, jobs.company_name, jobs.emp_name, jobs.date_received, jobs.embassy, jobs.process_location FROM jobs WHERE {$NXTFilter_rsTest} AND {$NXTFilter_rsTest} AND {$NXTFilter_rsTest} ORDER BY {$NXTSort_rsTest} ";
      $query_limit_rsTest = sprintf("%s LIMIT %d, %d", $query_rsTest, $startRow_rsTest, $maxRows_rsTest);
      $rsTest = mysql_query($query_limit_rsTest, $connServer) or die(mysql_error());
      $row_rsTest = mysql_fetch_assoc($rsTest);