<html><head><style type="text/css"><!-- DIV {margin:0px;} --></style></head><body><div style="font-family:times new roman, new york, times, serif;font-size:10pt"><div>Hi friends.<br><br>OK. People... I'm almost getting crazy. I don't understand what is happening.<br>I already looked for an answer, but I didn't find nothing yet. I am recording 8 extra <br>values in ACC, but the SQL command is using a weird value for one of them. So, <br>I removed 6 of them to facilitate the analyze. Look at the code:<br><br>.<br>.<br>modparam("acc", "db_extra", "valueA=$avp(i:15); valueB=$avp(i:16)")<br>.<br>.<br>.<br>avp_write("i:15","$avp(i:15)");<br>avp_write("i:16","$avp(i:16)");<br><br>if(!t_relay())<br>{<br>&nbsp;&nbsp;&nbsp; sl_reply_error();<br>&nbsp;&nbsp;&nbsp; exit;<br>};<br><br>avp_print();<br>exit;<br><br><br><br>OK.&nbsp; Looking at these lines, I would say: "the sql INSERT command will use the value<br>15 for avp:15 and 16 for avp:16". Now, look at the
 result of "avp_print":<br><br><br>&nbsp;2(11112) INFO:avpops:print_avp: p=0xb3b4a900, flags=0x0000<br>&nbsp;2(11112) INFO:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; id=&lt;16&gt;<br>&nbsp;2(11112) INFO:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; val_int=&lt;16&gt;<br>&nbsp;2(11112) INFO:avpops:print_avp: p=0xb3b4a8e8, flags=0x0000<br>&nbsp;2(11112) INFO:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; id=&lt;15&gt;<br>&nbsp;2(11112) INFO:&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; val_int=&lt;15&gt;<br><br>Nice. AVP 15 has the value 15 and the AVP 16 has 16. <br>But something is happening.... It is the insert command:<br><br>insert into acc (from_uri,to_uri,sip_method...............valueA,valueB,time) values<br>.........,'16','16','2008-05-19
 12:48:38').<br><br>16 twice!! Why? This question is running in loop inside my head. It should be&nbsp; "....'15','16','2008-05-19 12:48:38'.....". <br><br><br>The openser code above is executed just once by the INVITE. <br><br>I can bet this error is the like when we sum "2 and 3" and the result is "6". <br>You look at the equation, but you don't see it at all. And, when you ask your<br>younger brother to see, he says: "you are stupid... 2+3=5". <br><br>I never had this problem. I use several avps to log in the database and it is the<br>first time that it happens. You can see that I'M NOT CHANGING the values <br>of the avps.<br><br>Am I doing a stupid thing? Or, maybe, am I being blind? <br><br>By the way, I'm using version 1.1.1. <br><br>Tks people.<br><br><br><br><br>OK. Apparently, there's nothing wrong. <br><br><br><br><br><br><br><br></div></div><br>


      <hr size=1>Abra sua conta no <a href="http://br.rd.yahoo.com/mail/taglines/mail/*http://br.mail.yahoo.com/">Yahoo! Mail</a>, o único sem limite de espaço para armazenamento! 
</body></html>