<html xmlns:v="urn:schemas-microsoft-com:vml" xmlns:o="urn:schemas-microsoft-com:office:office" xmlns:w="urn:schemas-microsoft-com:office:word" xmlns:m="http://schemas.microsoft.com/office/2004/12/omml" xmlns="http://www.w3.org/TR/REC-html40">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=us-ascii">
<meta name="Generator" content="Microsoft Word 14 (filtered medium)">
<style><!--
/* Font Definitions */
@font-face
        {font-family:Calibri;
        panose-1:2 15 5 2 2 2 4 3 2 4;}
@font-face
        {font-family:Tahoma;
        panose-1:2 11 6 4 3 5 4 4 2 4;}
@font-face
        {font-family:Consolas;
        panose-1:2 11 6 9 2 2 4 3 2 4;}
/* Style Definitions */
p.MsoNormal, li.MsoNormal, div.MsoNormal
        {margin:0cm;
        margin-bottom:.0001pt;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
a:link, span.MsoHyperlink
        {mso-style-priority:99;
        color:blue;
        text-decoration:underline;}
a:visited, span.MsoHyperlinkFollowed
        {mso-style-priority:99;
        color:purple;
        text-decoration:underline;}
p
        {mso-style-priority:99;
        mso-margin-top-alt:auto;
        margin-right:0cm;
        mso-margin-bottom-alt:auto;
        margin-left:0cm;
        font-size:12.0pt;
        font-family:"Times New Roman","serif";
        color:black;}
pre
        {mso-style-priority:99;
        mso-style-link:"HTML Preformatted Char";
        margin:0cm;
        margin-bottom:.0001pt;
        font-size:10.0pt;
        font-family:"Courier New";
        color:black;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;}
span.EmailStyle20
        {mso-style-type:personal-reply;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
.MsoChpDefault
        {mso-style-type:export-only;
        font-size:10.0pt;}
@page WordSection1
        {size:612.0pt 792.0pt;
        margin:70.85pt 70.85pt 70.85pt 70.85pt;}
div.WordSection1
        {page:WordSection1;}
--></style><!--[if gte mso 9]><xml>
<o:shapedefaults v:ext="edit" spidmax="1026" />
</xml><![endif]--><!--[if gte mso 9]><xml>
<o:shapelayout v:ext="edit">
<o:idmap v:ext="edit" data="1" />
</o:shapelayout></xml><![endif]-->
</head>
<body bgcolor="white" lang="EN-US" link="blue" vlink="purple">
<div class="WordSection1">
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Hello Daniel,<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">It seems oracle is expecting the body value converted as an hex string. i.e:<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><?xml version="1.0" encoding="UTF-8"?><presence xmlns:dm="urn:ietf:params:xml:ns:pidf:data-model" xmlns:rpid="urn:ietf:params:xml:ns:pidf:rpid" entity="sip:giovanni.mele@ims-nagra.test"
 xmlns="urn:ietf:params:xml:ns:pidf"> <tuple id="d5zdxq">  <status>   <basic>open</basic>  </status>  <contact priority="0.8">sip:giovanni.mele@ims-nagra.test</contact>  <timestamp>2016-05-02T11:06:54Z</timestamp> </tuple></presence><o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Should be<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">3c3f786d6c2076657273696f6e3d22312e302220656e636f64696e673d225554462d38223f3e3c70726573656e636520786d6c6e733a646d3d2275726e3a696574663a706172616d733a786d6c3a6e733a706964663a646174612d6d6f64656c2220786d6c6e733a727069643d2275726e3a696574663a706172616d733a786d6c3a6e733a706964663a727069642220656e746974793d227369703a67696f76616e6e692e6d656c6540696d732d6e616772612e746573742220786d6c6e733d2275726e3a696574663a706172616d733a786d6c3a6e733a70696466223e203c7475706c652069643d2264357a647871223e20203c7374617475733e2020203c62617369633e6f70656e3c2f62617369633e20203c2f7374617475733e20203c636f6e74616374207072696f726974793d22302e38223e7369703a67696f76616e6e692e6d656c6540696d732d6e616772612e746573743c2f636f6e746163743e20203c74696d657374616d703e323031362d30352d30325431313a30363a35345a3c2f74696d657374616d703e203c2f7475706c653e3c2f70726573656e63653e<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">If I execute the following query in isql:<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">> insert into presentity (domain,username,event,etag,sender,body,received_time,priority,expires ) values ('ims-nagra.test','giovanni.mele','presence','a.1462186899.8822.1.0','','3c3f786d6c2076657273696f6e3d22312e302220656e636f64696e673d225554462d38223f3e3c70726573656e636520786d6c6e733a646d3d2275726e3a696574663a706172616d733a786d6c3a6e733a706964663a646174612d6d6f64656c2220786d6c6e733a727069643d2275726e3a696574663a706172616d733a786d6c3a6e733a706964663a727069642220656e746974793d227369703a67696f76616e6e692e6d656c6540696d732d6e616772612e746573742220786d6c6e733d2275726e3a696574663a706172616d733a786d6c3a6e733a70696466223e203c7475706c652069643d2264357a647871223e20203c7374617475733e2020203c62617369633e6f70656e3c2f62617369633e20203c2f7374617475733e20203c636f6e74616374207072696f726974793d22302e38223e7369703a67696f76616e6e692e6d656c6540696d732d6e616772612e746573743c2f636f6e746163743e20203c74696d657374616d703e323031362d30352d30325431313a30363a35345a3c2f74696d657374616d703e203c2f7475706c653e3c2f70726573656e63653e',1462187244,0,1462190844);<o:p></o:p></span></p>
<p class="MsoNormal"><span lang="DE-CH" style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">it works….<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">But if you convert it in hex string when inserting, I suppose you will have to do the reverse operation when reading it from the db…<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Regards<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D">Giovanni<o:p></o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="font-size:11.0pt;font-family:"Calibri","sans-serif";color:#1F497D"><o:p> </o:p></span></p>
<div>
<div style="border:none;border-top:solid #B5C4DF 1.0pt;padding:3.0pt 0cm 0cm 0cm">
<p class="MsoNormal"><b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext">From:</span></b><span style="font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext"> sr-users [mailto:sr-users-bounces@lists.sip-router.org]
<b>On Behalf Of </b>Daniel-Constantin Mierla<br>
<b>Sent:</b> lundi 2 mai 2016 13:57<br>
<b>To:</b> Kamailio (SER) - Users Mailing List<br>
<b>Subject:</b> Re: [SR-Users] Kamailio and Oracle database<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p>Hello,<o:p></o:p></p>
<p>I wrote in a previous email as well -- it seems that oracle doesn't like '\n' characters in the xml doc for presence. Can you check the docs for oracle and see if needs some special format in such case or maybe a special column definition? The xml is sent
 by the client, kamailio just has to store it in db.<o:p></o:p></p>
<p class="MsoNormal" style="margin-bottom:12.0pt">Cheers,<br>
Daniel<o:p></o:p></p>
<div>
<p class="MsoNormal">On 02/05/16 13:25, gmele wrote:<o:p></o:p></p>
</div>
<blockquote style="margin-top:5.0pt;margin-bottom:5.0pt">
<pre>Hello,<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>it seems kamailio has a problem inserting a value in the oracle BLOB column<o:p></o:p></pre>
<pre>BODY in the PRESENTITY table.<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>I executed the command without the BLOB value and all is working fine. As<o:p></o:p></pre>
<pre>soon as I try to insert the BLOB, it fails.<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>Is there some incompatibility handling Oracle blobs?<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre><o:p> </o:p></pre>
<pre>Regards<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre><o:p> </o:p></pre>
<pre>Giovanni<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre><o:p> </o:p></pre>
<pre><o:p> </o:p></pre>
<pre>--<o:p></o:p></pre>
<pre>View this message in context: <a href="http://sip-router.1086192.n5.nabble.com/Kamailio-and-Oracle-database-tp147990p148026.html">http://sip-router.1086192.n5.nabble.com/Kamailio-and-Oracle-database-tp147990p148026.html</a><o:p></o:p></pre>
<pre>Sent from the Users mailing list archive at Nabble.com.<o:p></o:p></pre>
<pre><o:p> </o:p></pre>
<pre>_______________________________________________<o:p></o:p></pre>
<pre>SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list<o:p></o:p></pre>
<pre><a href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a><o:p></o:p></pre>
<pre><a href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a><o:p></o:p></pre>
</blockquote>
<p class="MsoNormal"><br>
<br>
<o:p></o:p></p>
<pre>-- <o:p></o:p></pre>
<pre>Daniel-Constantin Mierla<o:p></o:p></pre>
<pre><a href="http://www.asipto.com">http://www.asipto.com</a><o:p></o:p></pre>
<pre><a href="http://twitter.com/#!/miconda">http://twitter.com/#!/miconda</a> - <a href="http://www.linkedin.com/in/miconda">http://www.linkedin.com/in/miconda</a><o:p></o:p></pre>
<pre>Kamailio World Conference, Berlin, May 18-20, 2016 - <a href="http://www.kamailioworld.com">http://www.kamailioworld.com</a><o:p></o:p></pre>
</div>
</body>
</html>