US County - fixed query

这个提交包含在:
Andreas 2022-05-29 20:01:44 +02:00
父节点 ced69b8ea4
当前提交 9e4c6c6e72

查看文件

@ -844,14 +844,13 @@ class Logbook_model extends CI_Model {
function call_us_county($callsign) { function call_us_county($callsign) {
$this->db->select('COL_CALL, COL_CNTY'); $this->db->select('COL_CALL, COL_CNTY');
$this->db->where('COL_CALL', $callsign); $this->db->where('COL_CALL', $callsign);
$where = "COL_NAME != \"\""; $where = "COL_CNTY != \"\"";
$this->db->where($where); $this->db->where($where);
$this->db->order_by("COL_TIME_ON", "desc"); $this->db->order_by("COL_TIME_ON", "desc");
$this->db->limit(1); $this->db->limit(1);
$query = $this->db->get($this->config->item('table_name')); $query = $this->db->get($this->config->item('table_name'));
$name = "";
if ($query->num_rows() > 0) if ($query->num_rows() > 0)
{ {
$data = $query->row(); $data = $query->row();