<html>
<head>
<meta content="text/html; charset=ISO-8859-1"
http-equiv="Content-Type">
</head>
<body bgcolor="#FFFFFF" text="#000000">
<br>
<br>
On 11/22/11 11:54 AM, Stephen Dodge (Bistech) wrote:
<blockquote
cite="mid:63C98A4100A7D34C9D3B85021AA8F0EA148AAE29F2@BIS-EXS01-VIC-V.office.bistech.co.uk"
type="cite">
<meta http-equiv="Content-Type" content="text/html;
charset=ISO-8859-1">
<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:11.0pt;
        font-family:"Calibri","sans-serif";
        color:black;
        mso-fareast-language:EN-US;}
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;}
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.EmailStyle17
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:windowtext;}
span.EmailStyle18
        {mso-style-type:personal;
        font-family:"Calibri","sans-serif";
        color:#1F497D;}
span.HTMLPreformattedChar
        {mso-style-name:"HTML Preformatted Char";
        mso-style-priority:99;
        mso-style-link:"HTML Preformatted";
        font-family:Consolas;
        color:black;
        mso-fareast-language:EN-US;}
span.EmailStyle21
        {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:72.0pt 72.0pt 72.0pt 72.0pt;}
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]-->
<div class="WordSection1">
<p class="MsoNormal"><span style="color:#1F497D">Thanks Daniel,
I just needed to cast the NULL before returning it from my
MySQL function.<o:p></o:p></span></p>
<p class="MsoNormal"><span style="color:#1F497D"><o:p> </o:p></span></p>
<p class="MsoNormal"><span style="color: rgb(31, 73, 125);">cast(NULL
as unsigned integer)</span></p>
</div>
</blockquote>
ok, good hint. I guess MYSQL_TYPE_NULL is returned as type for such
cases -- I assume the type is not a valid one to define columns, but
used for returned values from functions and procedures, also
probably for views with columns defined null always.<br>
<br>
It may be an option to map internally in db_mysql module the
MYSQL_TYPE_NULL to integer type -- the value should have the null
flag set as well.<br>
<br>
Cheers,<br>
Daniel<br>
<blockquote
cite="mid:63C98A4100A7D34C9D3B85021AA8F0EA148AAE29F2@BIS-EXS01-VIC-V.office.bistech.co.uk"
type="cite">
<div class="WordSection1">
<p class="MsoNormal"><span style="color:#1F497D"><o:p></o:p></span></p>
<div>
<p class="MsoNormal"><span
style="color:#1F497D;mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span
style="color:#1F497D;mso-fareast-language:EN-GB">Regards<o:p></o:p></span></p>
<p class="MsoNormal"><span
style="color:#1F497D;mso-fareast-language:EN-GB"><o:p> </o:p></span></p>
<p class="MsoNormal"><span
style="font-size:16.0pt;color:#1F497D;mso-fareast-language:EN-GB">Steve</span><span
style="color:#1F497D;mso-fareast-language:EN-GB"><o:p></o:p></span></p>
</div>
<p class="MsoNormal"><span style="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;mso-fareast-language:EN-GB"
lang="EN-US">From:</span></b><span
style="font-size:10.0pt;font-family:"Tahoma","sans-serif";color:windowtext;mso-fareast-language:EN-GB"
lang="EN-US"> Daniel-Constantin Mierla
[<a class="moz-txt-link-freetext" href="mailto:miconda@gmail.com">mailto:miconda@gmail.com</a>] <br>
<b>Sent:</b> 18 November 2011 09:40<br>
<b>To:</b> SIP Router - Kamailio (OpenSER) and SIP
Express Router (SER) - Users Mailing List<br>
<b>Cc:</b> Stephen Dodge (Bistech)<br>
<b>Subject:</b> Re: [SR-Users] FW: db_mysql ->
unhandled data type column<o:p></o:p></span></p>
</div>
</div>
<p class="MsoNormal"><o:p> </o:p></p>
<p class="MsoNormal">Hello,<br>
<br>
On 11/18/11 9:46 AM, Stephen Dodge (Bistech) wrote: <o:p></o:p></p>
<p class="MsoNormal">Hello,<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D">I thought I’d
post this again just in case anyone has some suggestions.
Apologies if this is a basic question!!</span><o:p></o:p></p>
<p class="MsoNormal"><span style="color:#1F497D"> </span><o:p></o:p></p>
<p class="MsoNormal">We are using Kamailio 3.1.5 in production.
We use the sqlops module to run a mysql function to return
parameters. In the logs I am seeing the flowing warnings. <o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal">/usr/sbin/kamailio[3991]: WARNING: db_mysql
[km_res.c:143]: unhandled data type column (diallednumber)
type id (6), use DB1_STRING as default
<o:p></o:p></p>
<p class="MsoNormal">/usr/sbin/kamailio[3991]: WARNING: db_mysql
[km_res.c:143]: unhandled data type column (ringtime) type id
(6), use DB1_STRING as default<o:p></o:p></p>
<p class="MsoNormal"> <o:p></o:p></p>
<p class="MsoNormal"><span style="mso-fareast-language:EN-GB"> </span><o:p></o:p></p>
<p class="MsoNormal">I think these are generated when we return
a null value, although this is not causing us a problem can
anyone advise how to eliminate these warnings.<o:p></o:p></p>
<p class="MsoNormal"><span
style="font-size:12.0pt;font-family:"Times New
Roman","serif";mso-fareast-language:EN-GB">what
are the definitions of the columns diallednumber and
ringtime in the database table?<br>
<br>
The log message is not related to value, but to the column's
data type, which is not recognized by db_mysql, thus the
value is stored as string in the result array.<br>
<br>
Cheers,<br>
Daniel<br>
<br>
<o:p></o:p></span></p>
<pre>-- <o:p></o:p></pre>
<pre>Daniel-Constantin Mierla -- <a moz-do-not-send="true" href="http://www.asipto.com">http://www.asipto.com</a><o:p></o:p></pre>
<pre>Kamailio Advanced Training, Dec 5-8, Berlin: <a moz-do-not-send="true" href="http://asipto.com/u/kat">http://asipto.com/u/kat</a><o:p></o:p></pre>
<pre><a moz-do-not-send="true" href="http://linkedin.com/in/miconda">http://linkedin.com/in/miconda</a> -- <a moz-do-not-send="true" href="http://twitter.com/miconda">http://twitter.com/miconda</a><o:p></o:p></pre>
</div>
<br>
<hr>
<font color="Gray" face="Arial" size="1">Information in this
message, including any attachments, is confidential to the
person to whom it is addressed and may be legally privileged. If
you are not the intended recipient please notify the sender and
delete the message from your system. Please note that Bistech
Group plc, Bistech plc, Bisnet Limited and the sender do not
accept any responsibility for viruses. It is your responsibility
to check the e-mail and any attachments for viruses. Calls may
be monitored and recorded.<br>
</font>
<br>
<fieldset class="mimeAttachmentHeader"></fieldset>
<br>
<pre wrap="">_______________________________________________
SIP Express Router (SER) and Kamailio (OpenSER) - sr-users mailing list
<a class="moz-txt-link-abbreviated" href="mailto:sr-users@lists.sip-router.org">sr-users@lists.sip-router.org</a>
<a class="moz-txt-link-freetext" href="http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users">http://lists.sip-router.org/cgi-bin/mailman/listinfo/sr-users</a>
</pre>
</blockquote>
<br>
<pre class="moz-signature" cols="72">--
Daniel-Constantin Mierla -- <a class="moz-txt-link-freetext" href="http://www.asipto.com">http://www.asipto.com</a>
Kamailio Advanced Training, Dec 5-8, Berlin: <a class="moz-txt-link-freetext" href="http://asipto.com/u/kat">http://asipto.com/u/kat</a>
<a class="moz-txt-link-freetext" href="http://linkedin.com/in/miconda">http://linkedin.com/in/miconda</a> -- <a class="moz-txt-link-freetext" href="http://twitter.com/miconda">http://twitter.com/miconda</a></pre>
</body>
</html>