<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: Persistant chat configuration with postgres DB in DevNet General Discussions</title>
    <link>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456467#M181</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes I found the information in the link, forgot to update the message.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cups/8_0/english/compliance/guide/CUPIMCompliance/imcplan.html" title="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cups/8_0/english/compliance/guide/CUPIMCompliance/imcplan.html"&gt;Instant Messaging Compliance Guide for Cisco Unified Presence Release 8.0, 8.5 and 8.6 - Planning for IM Compliance [Cis…&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks Howard.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 19 May 2014 06:08:21 GMT</pubDate>
    <dc:creator>yogeshshanbhag</dc:creator>
    <dc:date>2014-05-19T06:08:21Z</dc:date>
    <item>
      <title>Persistant chat configuration with postgres DB</title>
      <link>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456465#M179</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Team,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I was able to complete the setup of Postgres DB and configure it to CUPS (for Persistant chat) as per the steps mentioned in the link given below.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cups/8_0/english/install_upgrade/database/guide/CUPDBSetup/Configuring_Database_CUP.html" title="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cups/8_0/english/install_upgrade/database/guide/CUPDBSetup/Configuring_Database_CUP.html" target="_blank"&gt;Database Setup Guide for Cisco Unified Presence Release 8.0, 8.5 and 8.6 - Configuring an External Database on Cisco Uni…&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I see that the checks 'Ping External DB' and ' Connectivity to External DB' both pass. I also see the tables created in the postgres database schema.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The issue I am facing is that the insert statements that persist the chat messages are failing (invalid syntax as per the postgres DB logs).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The sql statement looks like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;INSERT INTO tc_msgarchive(msg_id, to_jid, from_jid, nick_jid, sent_date, msg_type, body_len, message_len, body_string, message_string, body_text, MESSAGE_TEXT, subject)&lt;/P&gt;&lt;P&gt;VALUES('1',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'testconf@conf.abc.local',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'user@abc.local',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'testconf@conf.abc.local/user1@abc.local/jabber_1111',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '2014-05-12 08:32:13.839975',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'g',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 4,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 469,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'test',&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '&amp;lt;message from=\'user1@abc.local/jabber_1111\' id=\'uid:5359230a:000049ec:00000679\' to=\'testconf@conf.abc.local\' type=\'groupchat\' xml:lang=\'en\'&amp;gt;&amp;lt;body&amp;gt;test&amp;lt;/body&amp;gt;&amp;lt;html xmlns=\'&lt;/SPAN&gt;&lt;A class="jive-link-external-small" href="http://jabber.org/protocol/xhtml-im" rel="nofollow" target="_blank"&gt;http://jabber.org/protocol/xhtml-im&lt;/A&gt;&lt;SPAN&gt;\'&amp;gt;..........&amp;lt;/message&amp;gt;'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '',&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '');&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;ERROR:&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN style="text-decoration: underline;"&gt;syntax error at or near "user1" at character 417&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The error is because of the '\' (backslash) which is escaping the " ' " single quote in the &amp;lt;message&amp;gt; tag.&lt;/P&gt;&lt;P&gt;&amp;lt;message from=&lt;SPAN style="text-decoration: underline;"&gt;\'user1@abc.local/jabber_1111\'&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If I change the '\' backslash to " ' " , the insert query works fine.&lt;/P&gt;&lt;P&gt;&amp;lt;message from=&lt;SPAN style="text-decoration: underline;"&gt;''user1@abc.local/jabber_1111''&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;Is anyone facing this issue with postgres DB for chat persistance setup? Is there a way to tell CUPS to use " ' " (single quotes) instead of '/' (backslash).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 01 Mar 2019 10:44:21 GMT</pubDate>
      <guid>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456465#M179</guid>
      <dc:creator>yogeshshanbhag</dc:creator>
      <dc:date>2019-03-01T10:44:21Z</dc:date>
    </item>
    <item>
      <title>Re: Persistant chat configuration with postgres DB</title>
      <link>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456466#M180</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Yogesh,&lt;/P&gt;&lt;P&gt;You need to edit the postgressql.conf for the following attribute&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;escape_string_warning = off&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;&lt;A class="loading" href="http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html#GUC-ESCAPE-STRING-WARNING" title="http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html#GUC-ESCAPE-STRING-WARNING"&gt;http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html#GUC-ESCAPE-STRING-WARNING&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;And maybe this as well&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;backslash_quote = on/off&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;&lt;A class="loading" href="http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html#GUC-BACKSLASH-QUOTE" title="http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html#GUC-BACKSLASH-QUOTE"&gt;http://www.postgresql.org/docs/8.2/static/runtime-config-compatible.html#GUC-BACKSLASH-QUOTE&lt;/A&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;Regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: monospace; font-size: 12.800000190734863px;"&gt;Howard&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 14 May 2014 15:36:37 GMT</pubDate>
      <guid>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456466#M180</guid>
      <dc:creator>tinghche</dc:creator>
      <dc:date>2014-05-14T15:36:37Z</dc:date>
    </item>
    <item>
      <title>Re: Persistant chat configuration with postgres DB</title>
      <link>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456467#M181</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes I found the information in the link, forgot to update the message.&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cups/8_0/english/compliance/guide/CUPIMCompliance/imcplan.html" title="http://www.cisco.com/c/en/us/td/docs/voice_ip_comm/cups/8_0/english/compliance/guide/CUPIMCompliance/imcplan.html"&gt;Instant Messaging Compliance Guide for Cisco Unified Presence Release 8.0, 8.5 and 8.6 - Planning for IM Compliance [Cis…&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks Howard.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 19 May 2014 06:08:21 GMT</pubDate>
      <guid>https://community.cisco.com/t5/devnet-general-discussions/persistant-chat-configuration-with-postgres-db/m-p/3456467#M181</guid>
      <dc:creator>yogeshshanbhag</dc:creator>
      <dc:date>2014-05-19T06:08:21Z</dc:date>
    </item>
  </channel>
</rss>

