<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DZone Snippets: database code</title>
    <link>http://snippets.dzone.com/posts</link>
    <pubDate>Sun, 27 Jul 2008 09:25:22 GMT</pubDate>
    <description>DZone Snippets: database code</description>
    <item>
      <title>Debug logs in the database</title>
      <link>http://snippets.dzone.com/posts/show/4077</link>
      <description>How to log things in the database&lt;br /&gt;&lt;br /&gt;Create the table:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;create table TMP_LOG (HORA date, ENTRADA varchar(4000));&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Write the things I need to the table:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;INSERT INTO TMP_LOG (HORA, ENTRADA) VALUES(SYSDATE, &lt;br /&gt;  'V_NOM_DESTINATARIO1: '||V_NOM_DESTINATARIO1||', V_DOM_DESTINATARIO1: '||V_DOM_DESTINATARIO1||&lt;br /&gt;  ', P_NOM_DESTINATARIO_2: '||P_NOM_DESTINATARIO_2||', P_DOM_DESTINATARIO_2: '||P_DOM_DESTINATARIO_2||&lt;br /&gt;  ', B_DESTINATARIO: '||B_DESTINATARIO||&lt;br /&gt;  ', V_NOM_DESTINATARIO2: '||V_NOM_DESTINATARIO2||', V_DOM_DESTINATARIO2: '||V_DOM_DESTINATARIO2);&lt;br /&gt;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Consult the things written:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;select * from tmp_log order by hora desc;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;Dont forget to drop it at the end:&lt;br /&gt;&lt;code&gt;&lt;br /&gt;drop table TMP_LOG;&lt;br /&gt;&lt;/code&gt;&lt;br /&gt;</description>
      <pubDate>Wed, 30 May 2007 16:59:19 GMT</pubDate>
      <guid>http://snippets.dzone.com/posts/show/4077</guid>
      <author>koke24 (Koke)</author>
    </item>
  </channel>
</rss>
