[asterisk-bugs] [JIRA] (ASTERISK-27283) Realtime config fail with PostgreSQL version before 9.1
Asterisk Team (JIRA)
noreply at issues.asterisk.org
Wed Aug 8 10:22:59 CDT 2018
[ https://issues.asterisk.org/jira/browse/ASTERISK-27283?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Asterisk Team updated ASTERISK-27283:
-------------------------------------
Target Release Version/s: 16.0.0
> Realtime config fail with PostgreSQL version before 9.1
> -------------------------------------------------------
>
> Key: ASTERISK-27283
> URL: https://issues.asterisk.org/jira/browse/ASTERISK-27283
> Project: Asterisk
> Issue Type: Bug
> Security Level: None
> Components: Resources/res_config_pgsql
> Environment: Linux
> PostgreSQL 8.4.21 on i486-pc-linux-gnu, compiled by GCC gcc-4.4.real (Debian 4.4.5-8) 4.4.5, 32-bit
> Reporter: Rodrigo Ramirez Norambuena
> Assignee: Rodrigo Ramirez Norambuena
> Target Release: 13.18.0, 14.7.0, 15.1.0, 16.0.0
>
>
> When is used a previous version of PostgreSQL than 9.1 the realtime fail because the is need double backslash to use ESCAPE
> Log
> Using `queue show`
> {code}
> [Sep 19 08:48:19] DEBUG[15708]: res_config_pgsql.c:227 pgsql_exec: PostgreSQL query attempt 1
> [Sep 19 08:48:19] ERROR[15708]: res_config_pgsql.c:165 _pgsql_exec: PostgreSQL RealTime: Failed to query 'queues at asterisk'.
> [Sep 19 08:48:19] ERROR[15708]: res_config_pgsql.c:166 _pgsql_exec: PostgreSQL RealTime: Query Failed: SELECT * FROM queues WHERE name LIKE '%' ESCAPE '\' ORDER BY name
> [Sep 19 08:48:19] ERROR[15708]: res_config_pgsql.c:167 _pgsql_exec: PostgreSQL RealTime: Query Failed because: ERROR: unterminated quoted string at or near «'\' ORDER BY name»
> LINE 1: SELECT * FROM queues WHERE name LIKE '%' ESCAPE '\' ORDER BY...
> ^
> (PGRES_FATAL_ERROR)
> [Sep 19 08:48:19] DEBUG[15708]: res_config_pgsql.c:227 pgsql_exec: PostgreSQL query attempt 1
> [Sep 19 08:48:19] DEBUG[15708]: res_config_pgsql.c:183 _pgsql_exec: PostgreSQL query successful: SELECT * FROM queues WHERE name = 'queue_test'
> [Sep 19 08:48:19] DEBUG[15708]: res_config_pgsql.c:481 realtime_pgsql: PostgreSQL RealTime: Result=0x939dbe0 Query: SELECT * FROM queues WHERE name = 'queue_test'
> [Sep 19 08:48:19] DEBUG[15708]: res_config_pgsql.c:489 realtime_pgsql: PostgreSQL RealTime: Found 1 rows.
> [Sep 19 08:48:19] DEBUG[15708]: res_config_pgsql.c:227 pgsql_exec: PostgreSQL query attempt 1
> [Sep 19 08:48:19] ERROR[15708]: res_config_pgsql.c:165 _pgsql_exec: PostgreSQL RealTime: Failed to query 'queue_members at asterisk'.
> [Sep 19 08:48:19] ERROR[15708]: res_config_pgsql.c:166 _pgsql_exec: PostgreSQL RealTime: Query Failed: SELECT * FROM queue_members WHERE interface LIKE '%' ESCAPE '\' AND queue_name = 'queue_test' ORDER BY interface
> [Sep 19 08:48:19] ERROR[15708]: res_config_pgsql.c:167 _pgsql_exec: PostgreSQL RealTime: Query Failed because: ERROR: syntax error at or near «queue_test»
> LINE 1: ...E interface LIKE '%' ESCAPE '\' AND queue_name = 'queue_test' ORDE...
> ^
> (PGRES_FATAL_ERROR)
> {code}
--
This message was sent by Atlassian JIRA
(v6.2#6252)
More information about the asterisk-bugs
mailing list