Database_Exception [ 0 ]: ERROR: syntax error at or near ")" LINE 1: ...es_phones.share_id AND shares_phones.clinic_id IN()) ORDER B... ^ [ SELECT "share".* FROM "shares" AS "share" WHERE "city_id" = '121' AND "share"."id" != '198' AND "share"."date_to" >= '2024-03-28' AND EXISTS (SELECT id FROM shares_phones WHERE share.id=shares_phones.share_id AND shares_phones.clinic_id IN()) ORDER BY random() LIMIT 2 ]

APPPATH/classes/kohana/database/postgresql.php [ 194 ]

189 					$rows = pg_num_rows($result);
190 				break;
191 				case PGSQL_BAD_RESPONSE:
192 				case PGSQL_NONFATAL_ERROR:
193 				case PGSQL_FATAL_ERROR:
194 					throw new Database_Exception(':error [ :query ]',
195 						array(':error' => pg_result_error($result), ':query' => $sql));
196 				case PGSQL_COPY_OUT:
197 				case PGSQL_COPY_IN:
198 					pg_end_copy($this->_connection);
199 
  1. MODPATH/database/classes/kohana/database/query.php [ 245 ] » Kohana_Database_PostgreSQL->query(arguments)

  2. MODPATH/orm/classes/kohana/orm.php [ 969 ] » Kohana_Database_Query->execute(arguments)

  3. MODPATH/orm/classes/kohana/orm.php [ 928 ] » Kohana_ORM->_load_result(arguments)

  4. APPPATH/classes/model/share.php [ 423 ] » Kohana_ORM->find_all()

  5. APPPATH/classes/controller/city/shares.php [ 79 ] » Model_Share->get_other_rand_shares(arguments)

  6. {PHP internal call} » Controller_City_Shares->action_view()

  7. SYSPATH/classes/kohana/request/client/internal.php [ 118 ] » ReflectionMethod->invoke(arguments)

  8. SYSPATH/classes/kohana/request/client.php [ 64 ] » Kohana_Request_Client_Internal->execute_request(arguments)

  9. SYSPATH/classes/kohana/request.php [ 1138 ] » Kohana_Request_Client->execute(arguments)

  10. DOCROOT/index.php [ 122 ] » Kohana_Request->execute()

  11. DOCROOT/index_memcached.php [ 65 ] » include(arguments)

Environment