<?xml version='1.0' encoding='UTF-8'?><?xml-stylesheet href="http://www.blogger.com/styles/atom.css" type="text/css"?><feed xmlns='http://www.w3.org/2005/Atom' xmlns:openSearch='http://a9.com/-/spec/opensearchrss/1.0/' xmlns:georss='http://www.georss.org/georss' xmlns:gd='http://schemas.google.com/g/2005' xmlns:thr='http://purl.org/syndication/thread/1.0'><id>tag:blogger.com,1999:blog-4677316190423110840</id><updated>2011-12-12T22:11:39.012+01:00</updated><category term='vss'/><category term='mail'/><category term='ctx'/><category term='bug'/><category term='sql plus'/><category term='efficiency'/><category term='front-end'/><category term='piracy'/><category term='storage'/><category term='about'/><category term='sql developer'/><category term='photos'/><category term='firebird'/><category term='log buffer'/><category term='picasa'/><category term='exadata'/><category term='excel'/><category term='11g'/><category term='spam'/><category term='strings'/><category term='flashback'/><category term='backup'/><category term='patch'/><category term='linux'/><category term='plsql'/><category term='xml'/><category term='other'/><category term='php'/><category term='security'/><category term='programming'/><category term='dba'/><category term='beehive'/><category term='links'/><category term='blog'/><category term='book'/><category term='pdf'/><category term='oracle'/><category term='ora_rowscn'/><category term='oow2008'/><category term='software'/><category term='search'/><category term='microsoft'/><category term='rman'/><category term='fun'/><category term='maps'/><category term='error'/><category term='drcp'/><category term='hp'/><category term='google'/><title type='text'>Software Engineer Thoughts</title><subtitle type='html'>My thoughts about developing software. Problems descriptions and solutions, tips, tricks, links to useful resources. Mostly on Oracle, but also PHP, Delphi and other languages &amp; tools.</subtitle><link rel='http://schemas.google.com/g/2005#feed' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/posts/default'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default?max-results=100'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/'/><link rel='hub' href='http://pubsubhubbub.appspot.com/'/><link rel='next' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default?start-index=101&amp;max-results=100'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><generator version='7.00' uri='http://www.blogger.com'>Blogger</generator><openSearch:totalResults>105</openSearch:totalResults><openSearch:startIndex>1</openSearch:startIndex><openSearch:itemsPerPage>100</openSearch:itemsPerPage><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3549721679378034128</id><published>2009-04-20T22:36:00.001+02:00</published><updated>2009-04-20T22:39:28.592+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>What a news! Oracle Buys Sun !</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
What a news: &lt;a title="Oracle Buys Sun" href="http://www.oracle.com/us/corporate/press/018363" id="znd:"&gt;Oracle Buys Sun&lt;/a&gt; !! I'm not the first one that blogs about it, but anyway let me express my comments. What does it mean for IT:&lt;br&gt;
1. Oracle software will be installed on almost every PC; Sun Java might be renamed to Oracle Java. It will give wider recognition for Oracle trademark also to people that are not so much engaged with IT Industry.&lt;br&gt;
2. Oracle becomes hardware producer. Well, you might know already HP-Oracle Database Machine (Exadata), but this was joint-venture. Now Oracle will produce hardware and software that runs on it. If everything goes right next "Database Machine" will be fully "Oracle".&lt;br&gt;
3. Sun Solaris is #1 platform for running Oracle, and the second one is Linux. This could mean that rate for Linux implementation in enterprises will be lower, as many companies would choose OS and DB from one vendor. I know that Oracle is also offering Linux, but Oracle sales will be promoting Solaris, as this deals will be better for Oracle.&lt;br&gt;
4. Oracle now owns 2, ehh, 3 databases: Oracle, Berkley XML DB and now MySQL. I could mean that MySQL will get even bettor, or rather it will mean that Oracle will offer MySQL customer to migrate to Oracle. So far Oracle does not have good record for supporting free editions of Databases. We will see...&lt;br&gt;
5. With Oracle-Sun merge, Oracle will be shipping now full stack: hardware,OS, Database, Midlleware, ERM, CRM and many others. Oracle is becoming giant now...&lt;br&gt;
&lt;br&gt;
Read also what others have to say:&lt;br&gt;
&lt;ul&gt;&lt;li&gt;Mark Rittman - &lt;a title="Oracle Buys Sun - What Does It Mean for Oracle BI&amp;amp;DW?" href="http://www.rittmanmead.com/2009/04/20/oracle-buys-sun-what-does-it-mean-for-oracle-bidw/" id="o_w6"&gt;Oracle Buys Sun - What Does It Mean for Oracle BI&amp;amp;DW?&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;Pythian - &lt;a title="Oracle Buys Sun" href="http://www.pythian.com/news/2080/oracle-buys-sun" id="v:79"&gt;Oracle Buys Sun&lt;/a&gt; &lt;br&gt;
&lt;/li&gt;
&lt;li&gt;Marco Gralike - &lt;a title="Oracle to buy Sun, Ehh MySQL, Ehh Glashfish…" href="http://www.liberidu.com/blog/?p=998" id="csc:"&gt;Oracle to buy Sun, Ehh MySQL, Ehh Glashfish…&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;Tanel Poder - &lt;a title="Oracle buys Sun - hooray!" href="http://blog.tanelpoder.com/2009/04/20/oracle-buys-sun-hooray/" id="fzoh"&gt;Oracle buys Sun - hooray!&lt;/a&gt; &lt;br&gt;
&lt;/li&gt;
&lt;li&gt;Tim Hall - &lt;a title="Oracle Buy Sun Microsystems…" href="http://www.oracle-base.com/blog/2009/04/20/oracle-buy-sun-microsystems/" id="ibt9"&gt;Oracle Buy Sun Microsystems…&lt;/a&gt; &lt;br&gt;
&lt;/li&gt;
&lt;li&gt;Kevin Closson - &lt;a title="Everyone Else is Doing It!" href="http://kevinclosson.wordpress.com/2009/04/20/everyone-else-is-doing-it/" id="z0og"&gt;Everyone Else is Doing It!&lt;/a&gt; &lt;br&gt;
&lt;/li&gt;
&lt;li&gt;Jaffar - &lt;a title="Oracle to acquire SUN?" href="http://jaffardba.blogspot.com/2009/04/oracle-acquire-sun.html" id="eqx_"&gt;Oracle to acquire SUN?&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;
&lt;br&gt;
Keep reading,&lt;br id="oe53"&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3549721679378034128?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3549721679378034128/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3549721679378034128' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3549721679378034128'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3549721679378034128'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2009/04/what-news-oracle-buys-sun.html' title='What a news! Oracle Buys Sun !'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1761009546289933004</id><published>2009-04-06T11:59:00.001+02:00</published><updated>2009-04-06T12:01:11.376+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='plsql'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='bug'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Caution: FOR loop and CONTINUE in Oracle 11g</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
Friend of mine showed me interesting issue of using CONTINUE Statement. CONTINUE is an new &lt;a title="statement in Oracle 11" href="http://download.oracle.com/docs/cd/B28359_01/server.111/b28279/chapter1.htm#FEATURENO07600" id="g453"&gt;statement in Oracle 11&lt;/a&gt;; it allow to skip processing of current iteration of look, and go to &lt;a title="begging of next iteration" href="http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28370/continue_statement.htm#CJAHCFBF" id="i79l"&gt;begging of next iteration&lt;/a&gt;. So here is working sample:&lt;br&gt;
&lt;blockquote&gt;SQL&amp;gt; set serveroutput on&lt;br&gt;
SQL&amp;gt; begin&lt;br&gt;
&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('=== START');&lt;br&gt;
&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp; for i in 1..15 loop&lt;br&gt;
&amp;nbsp; 4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('before:'||i);&lt;br&gt;
&amp;nbsp; 5&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if mod(i, 5) = 0 then&lt;br&gt;
&amp;nbsp; 6&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('CONTINUE');&lt;br&gt;
&amp;nbsp; 7&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; continue;&lt;br&gt;
&amp;nbsp; 8&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end if;&lt;br&gt;
&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('after:'||i);&lt;br&gt;
&amp;nbsp;10&amp;nbsp;&amp;nbsp;&amp;nbsp; end loop;&lt;br&gt;
&amp;nbsp;11&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('=== STOP');&lt;br&gt;
&amp;nbsp;12&amp;nbsp; end;&lt;br&gt;
&amp;nbsp;13&amp;nbsp; /&lt;br&gt;
=== START&lt;br&gt;
before:1&lt;br&gt;
after:1&lt;br&gt;
before:2&lt;br&gt;
after:2&lt;br&gt;
before:3&lt;br&gt;
after:3&lt;br&gt;
before:4&lt;br&gt;
after:4&lt;br&gt;
before:5&lt;br&gt;
CONTINUE&lt;br&gt;
before:6&lt;br&gt;
after:6&lt;br&gt;
before:7&lt;br&gt;
after:7&lt;br&gt;
before:8&lt;br&gt;
after:8&lt;br&gt;
before:9&lt;br&gt;
after:9&lt;br&gt;
before:10&lt;br&gt;
CONTINUE&lt;br&gt;
before:11&lt;br&gt;
after:11&lt;br&gt;
before:12&lt;br&gt;
after:12&lt;br&gt;
before:13&lt;br&gt;
after:13&lt;br&gt;
before:14&lt;br&gt;
after:14&lt;br&gt;
before:15&lt;br&gt;
CONTINUE&lt;br&gt;
=== STOP&lt;br&gt;
&lt;/blockquote&gt;
&lt;br&gt;
But when we use CONTINUE in loop, that is based on implicit cursor, it gives &lt;b&gt;wrong results&lt;/b&gt;:&lt;br&gt;
&lt;blockquote&gt;SQL&amp;gt; begin&lt;br&gt;
&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('=== START');&lt;br&gt;
&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp; for r in (select level num from dual connect by level &amp;lt;= 115) loop&lt;br&gt;
&amp;nbsp; 4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('before:'||r.num);&lt;br&gt;
&amp;nbsp; 5&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if mod(r.num, 5) = 0 then&lt;br&gt;
&amp;nbsp; 6&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('CONTINUE');&lt;br&gt;
&amp;nbsp; 7&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; continue;&lt;br&gt;
&amp;nbsp; 8&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end if;&lt;br&gt;
&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('after:'||r.num);&lt;br&gt;
&amp;nbsp;10&amp;nbsp;&amp;nbsp;&amp;nbsp; end loop;&lt;br&gt;
&amp;nbsp;11&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('=== STOP');&lt;br&gt;
&amp;nbsp;12&amp;nbsp; end;&lt;br&gt;
&amp;nbsp;13&amp;nbsp; /&lt;br&gt;
=== START&lt;br&gt;
before:1&lt;br&gt;
after:1&lt;br&gt;
before:2&lt;br&gt;
after:2&lt;br&gt;
before:3&lt;br&gt;
after:3&lt;br&gt;
before:4&lt;br&gt;
after:4&lt;br&gt;
before:5&lt;br&gt;
CONTINUE&lt;br&gt;
before:101&lt;br&gt;
after:101&lt;br&gt;
before:102&lt;br&gt;
after:102&lt;br&gt;
before:103&lt;br&gt;
after:103&lt;br&gt;
before:104&lt;br&gt;
after:104&lt;br&gt;
before:105&lt;br&gt;
CONTINUE&lt;br&gt;
=== STOP&lt;br&gt;
&lt;/blockquote&gt;
&lt;br&gt;
In that case CONTINUE statement goes to iteration no 101 instead of going to iteration 6, as expected!!&lt;br&gt;
To make the long story short, I've experiment with few setting and found that setting &lt;b&gt;PLSQL_OPTIMIZE_LEVEL to 1&lt;/b&gt; this block runs as expected:&lt;br&gt;
&lt;blockquote&gt;SQL&amp;gt; ALTER SESSION SET PLSQL_OPTIMIZE_LEVEL = 1;&lt;br&gt;
SQL&amp;gt; begin&lt;br&gt;
&amp;nbsp; 2&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('=== START');&lt;br&gt;
&amp;nbsp; 3&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; for r in (select level num from dual connect by level &amp;lt;= 115) loop&lt;br&gt;
&amp;nbsp; 4&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('before:'||r.num);&lt;br&gt;
&amp;nbsp; 5&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; if mod(r.num, 5) = 0 then&lt;br&gt;
&amp;nbsp; 6&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('CONTINUE');&lt;br&gt;
&amp;nbsp; 7&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; continue;&lt;br&gt;
&amp;nbsp; 8&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end if;&lt;br&gt;
&amp;nbsp; 9&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('after:'||r.num);&lt;br&gt;
&amp;nbsp;10&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; end loop;&lt;br&gt;
&amp;nbsp;11&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; dbms_output.put_line('=== STOP');&lt;br&gt;
&amp;nbsp;12&amp;nbsp; end;&lt;br&gt;
&amp;nbsp;13&amp;nbsp; /&lt;br&gt;
=== START&lt;br&gt;
before:1&lt;br&gt;
after:1&lt;br&gt;
before:2&lt;br&gt;
after:2&lt;br&gt;
before:3&lt;br&gt;
after:3&lt;br&gt;
before:4&lt;br&gt;
after:4&lt;br&gt;
before:5&lt;br&gt;
CONTINUE&lt;br&gt;
before:6&lt;br&gt;
after:6&lt;br&gt;
&lt;i&gt;[... many lines cutted out from output...]&lt;/i&gt;&lt;br&gt;
after:99&lt;br&gt;
before:100&lt;br&gt;
CONTINUE&lt;br&gt;
before:101&lt;br&gt;
after:101&lt;br&gt;
before:102&lt;br&gt;
after:102&lt;br&gt;
before:103&lt;br&gt;
after:103&lt;br&gt;
before:104&lt;br&gt;
after:104&lt;br&gt;
before:105&lt;br&gt;
CONTINUE&lt;br&gt;
before:106&lt;br&gt;
&lt;i&gt;[... many lines cutted out from output...]&lt;/i&gt;&lt;br&gt;
after:114&lt;br&gt;
before:115&lt;br&gt;
CONTINUE&lt;br&gt;
=== STOP&lt;br&gt;
&lt;/blockquote&gt;
&lt;br&gt;
For me it looks as bug in PL/SQL Optimizer on level 2. In that case PL/SQL does bulk collect for 100 rows when FOR LOOP with cursor is used. Seems that CONTINUE in that case causes to fetch next portion of records instead of taking next record from buffer. I've reported bug to Oracle Support, but until it will get fixed, be aware of possible wrong results.&lt;br&gt;
This was tested on Oracle 11.1.0.6 and 11.1.0.7 Enterprise Edition.&lt;br&gt;
&lt;br&gt;
Keep reading,&lt;br id="oe53"&gt;
Paweł&lt;br id="fy0e"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;&lt;li&gt;&lt;a title="Comments in SQL*Plus" href="http://pbarut.blogspot.com/2007/10/comments-in-sqlplus.html" id="aolm"&gt;Comments in SQL*Plus&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Dynamically set name of spool file in SQL*Plus" href="http://pbarut.blogspot.com/2007/06/dynamically-set-name-of-spool-file-in.html" id="r8en"&gt;Dynamically set name of spool file in SQL*Plus&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Table that cannot be deleted" href="http://pbarut.blogspot.com/2007/03/table-that-cannot-be-deleted.html" id="w:03"&gt;Table that cannot be deleted&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;&lt;li&gt;&lt;a title="ORA-03297 on empty datafile" href="http://pbarut.blogspot.com/2007/01/ora-03297-on-empty-datafile.html" id="y_n2"&gt;ORA-03297 on empty datafile&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Flashback Table and Materialized View – not working together" href="http://pbarut.blogspot.com/2006/09/flashback-table-and-materialized-view.html" id="ciid"&gt;Flashback Table and Materialized View – not working together&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1761009546289933004?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1761009546289933004/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1761009546289933004' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1761009546289933004'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1761009546289933004'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2009/04/caution-for-loop-and-continue-in-oracle.html' title='Caution: FOR loop and CONTINUE in Oracle 11g'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3759183749524807717</id><published>2009-03-29T12:55:00.001+02:00</published><updated>2009-03-29T13:01:53.388+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='excel'/><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='pdf'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><category scheme='http://www.blogger.com/atom/ns#' term='book'/><title type='text'>Book Review: Processing XML documents with Oracle JDeveloper 11g</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
This time I would like to recommend a book &lt;a title="Processing XML documents with Oracle JDeveloper 11g" href="https://www.packtpub.com/processing-xml-documents-with-oracle-jdeveloper-11g/book" id="a2aa"&gt;Processing XML documents with Oracle JDeveloper 11g&lt;/a&gt; published by &lt;a title="PacktPub.com" href="http://www.packtpub.com/" id="f5hp"&gt;PacktPub.com&lt;/a&gt;. As I have some experience with XML processing inside Oracle DB (XMLDB) I was lacking the knowledge of XML manipulation in Java, especially using &lt;a title="Oracle JDeveloper" href="http://www.oracle.com/technology/software/products/jdev/htdocs/soft11.html" id="atc5"&gt;Oracle JDeveloper&lt;/a&gt;. This book is rather not for beginners - you should have basic knowledge of what is XML, at least theoretically. From the book you can learn how to manage XML Schemas in JDeveloper, then write XML documents based on those schema and finally validate them in JDeveloper or write Java code to validate it automatically. Chapters that I value much are those describing how to generate PDF documents. There are two methods described - one using &lt;a title="Apache FOP API" href="http://xmlgraphics.apache.org/fop/" id="l7z1"&gt;Apache FOP API&lt;/a&gt; , and &lt;a title="Oracle XML Publisher" href="http://www.oracle.com/technology/products/xml-publisher/index.html" id="w.vi"&gt;Oracle XML Publisher&lt;/a&gt;. As I was not generating PDF's this way so far, I found those 2 chapters very interesting. There is also chapter on generatin Excel by transformation of XML using &lt;a title="Apache HSSF API" href="http://poi.apache.org/spreadsheet/index.html" id="cn6s"&gt;Apache HSSF API&lt;/a&gt; .&lt;br&gt;
&lt;br&gt;
Book is very practical. If you want to start with subjects described above then this book is for you. Of course it does not mean that you do not have to study documentation. However, it will be easier for you to make first steps. Beside describing Oracle JDeveloper, author also shows how to install and use &lt;a title="Oracle Berkley XML DB" href="http://www.oracle.com/database/berkeley-db/xml/index.html" id="bbdf"&gt;Oracle Berkley XML DB&lt;/a&gt;  to store, query and update XML Documents - using command line and XML DB API.&lt;br&gt;
&lt;br&gt;
I especially recommend eBook version. All URLs in eBook version are active, so linking to web pages are very simple. Also coping sample code is easy. This book contains many practical and usefull tips on XML processing and tools as well. So if those XML aspects are in your interest, then it's definitelly good to invest in this book.&lt;br&gt;
&lt;br&gt;
Keep reading,&lt;br id="oe53"&gt;
Paweł&lt;br id="fy0e"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;&lt;li&gt;
&lt;a title="ORA-00904: &amp;quot;XMLROOT&amp;quot;: invalid identifier" href="http://pbarut.blogspot.com/2008/05/ora-00904-xmlroot-invalid-identifier.html" id="n5ye"&gt;ORA-00904: "XMLROOT": invalid identifier&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Useful links on Oracle XML DB" href="http://pbarut.blogspot.com/2008/02/useful-links-on-oracle-xml-db.html" id="q-55"&gt;Useful links on Oracle XML DB&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Solving ORA-22905: cannot access rows from a non-nested table item" href="http://pbarut.blogspot.com/2007/05/solving-ora-22905-cannot-access-rows.html" id="hqqw"&gt;Solving ORA-22905: cannot access rows from a non-nested table item&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Oracle XMLType: exctractvalue vs. extract" href="http://pbarut.blogspot.com/2007/01/oracle-xmltype-exctractvalue-vs-extract.html" id="nvhj"&gt;Oracle XMLType: exctractvalue vs. extract&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="ORA-30625 and XMLType" href="http://pbarut.blogspot.com/2006/11/ora-30625-and-xmltype.html" id="dg7o"&gt;ORA-30625 and XMLType&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;
&lt;ul&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3759183749524807717?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3759183749524807717/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3759183749524807717' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3759183749524807717'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3759183749524807717'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2009/03/book-review-processing-xml-documents.html' title='Book Review: Processing XML documents with Oracle JDeveloper 11g'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3393886326237248309</id><published>2009-03-15T22:39:00.000+01:00</published><updated>2009-03-15T22:40:15.984+01:00</updated><title type='text'>Multiplying texts and null effect</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
This time short notice on side effect of implicit type conversion ans short expression evaluation. Let me show this on example - try this statement:&lt;br&gt;
&lt;blockquote&gt;SQL&amp;gt; select 'a'*'b' from dual;&lt;br&gt;
select 'a'*'b' from dual&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; *&lt;br&gt;
ERROR at line 1:&lt;br&gt;
ORA-01722: invalid number&lt;br&gt;
&lt;/blockquote&gt;
As expected we get error. It is due to fact that multiplexing operator (*) is expecting numbers on both sides, an implicit conversion takes place. However this statement:&lt;br&gt;
&lt;blockquote&gt;SQL&amp;gt; select ''*'b' from dual;&lt;br&gt;
&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp; ''*'B'&lt;br&gt;
----------&lt;br&gt;
&lt;/blockquote&gt;
does not give error. How is it possible? In oracle empty string is in fact an null. null multiplied by any number gives null, so due to optimization oracle decided to evaluate this expression to null.&lt;br&gt;
As you know also 0 (zero) multiplied by any number gives zero. So let's test it:&lt;br&gt;
&lt;blockquote&gt;SQL&amp;gt; select '0'*'b' from dual;&lt;br&gt;
select '0'*'b' from dual&lt;br&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; *&lt;br&gt;
ERROR at line 1:&lt;br&gt;
ORA-01722: invalid number&lt;br&gt;
&lt;/blockquote&gt;
In that case Oracle did not optimized evaluation, and decided to make full calculation. I do not know the reason for different behaviour but is repeatable (at least on instances I've access to).&lt;br&gt;
My recommendation: always make sure that you provide data in proper data-type. Make explicit data conversion using to_number, to_date or to_char functions.&lt;br&gt;
&lt;br&gt;
Keep reading,&lt;br id="oe53"&gt;
Paweł&lt;br id="fy0e"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;&lt;li&gt;&lt;a title="UTL_MATCH - String Similarity in Oracle" href="http://pbarut.blogspot.com/2006/12/utlmatch-string-similarity-in-oracle.html" id="c.bg"&gt;UTL_MATCH - String Similarity in Oracle&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Rolling Back the DDL" href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html" id="t3ez"&gt;Rolling Back the DDL&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="DB Link to Oracle 11g" href="http://pbarut.blogspot.com/2008/08/db-link-to-oracle-11g.html" id="tcpx"&gt;DB Link to Oracle 11g&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="How to shrink Oracle Context Index" href="http://pbarut.blogspot.com/2008/01/how-to-shrink-oracle-context-index.html" id="q0o1"&gt;How to shrink Oracle Context Index&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Using Named Parameters within SQL" href="http://pbarut.blogspot.com/2007/10/using-named-parameters-within-sql.html" id="c2u6"&gt;Using Named Parameters within SQL&lt;/a&gt; &lt;/li&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3393886326237248309?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3393886326237248309/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3393886326237248309' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3393886326237248309'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3393886326237248309'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2009/03/multiplying-texts-and-null-effect.html' title='Multiplying texts and null effect'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2656261515119608452</id><published>2008-09-26T06:52:00.003+02:00</published><updated>2008-11-25T22:14:10.881+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='exadata'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>OOW2008 day 5 – It’s A Wrap</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br/&gt;
Before I start to summarize my Day 5 at Oracle OpenWorld, I would like to add few words to &lt;a href="http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html"&gt;day 4 (Wednesday)&lt;/a&gt;.

&lt;br/&gt;&lt;br/&gt;&lt;b&gt;Managing Very, Very Large XML Documents with Oracle XML Database&lt;/b&gt;&lt;br/&gt;
It was very good session. It one of those where practical experience was shared. Presenters showed step by step how to load very large XML files to DB:&lt;ul&gt;
&lt;li&gt;Setting up XML schema
&lt;li&gt;Schema annotation technique and few directives
&lt;li&gt;Direct Insert Store for XML
&lt;li&gt;Differences with loading XML into XML DB in 10.2g and 11g
&lt;/ul&gt;
&lt;br/&gt;&lt;br/&gt;&lt;b&gt;The Appreciation Event.&lt;/b&gt;&lt;br/&gt;
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_6xECfZb_CD0/SNxrKkrjpTI/AAAAAAAAFfU/hwUkuXv91L8/s1600-h/DSC_5468.JPG"&gt;&lt;img style="float:right; margin:0 0 10px 10px;cursor:pointer; cursor:hand;" src="http://4.bp.blogspot.com/_6xECfZb_CD0/SNxrKkrjpTI/AAAAAAAAFfU/hwUkuXv91L8/s400/DSC_5468.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5250189094996387122" /&gt;&lt;/a&gt;It was very nice concert on Treasure Island. I’ve especially liked Seal. Beside that there was lot of good food and drinks.
&lt;p&gt;&lt;h2&gt;Day 5&lt;/h2&gt;&lt;/p&gt;
I will start with session &lt;b&gt;Oracle’s New Database Accelerator: Query Processing Revolutionized&lt;/b&gt;. As I’ve expected it was related to announcement made yesterday. 
My yesterday’s description was not perfect. Now I will try to fix this. First of all we have 2 new machines. But one them is included in the second one.
&lt;br/&gt;&lt;b&gt;Oracle Exodata Storage Server&lt;/b&gt; - it is hardware from HP: 2 Intel quad-core processors, 12 disks (300GB, 15RPM or 750 GB, 10 RPM) with disk controller optimized for best bandwidth and 2 InfiniBand connectors to connect to external equipment. The code for this product is HP DL180G5 (at least that was on one of slides). This computer is sold with preinstalled Oracle Enterprise Linux 5.1. The main role of this machine is to store database files. It cannot be used to store normal files.
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_6xECfZb_CD0/SNxrjOIk5mI/AAAAAAAAFfk/Dv0Oa_m5gCk/s1600-h/DSC_5471.JPG"&gt;&lt;img style="float:left; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_6xECfZb_CD0/SNxrjOIk5mI/AAAAAAAAFfk/Dv0Oa_m5gCk/s400/DSC_5471.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5250189518440818274" /&gt;&lt;/a&gt;
&lt;br/&gt;The second hardware is &lt;b&gt;HP-Oracle Exodata DB Machine&lt;/b&gt; - This one is rack box equipped with 14 Oracle Exodata Storage Servers and 8 DB Servers each with 8 Intel processors. On those DB Server runs Oracle Enterprise Linux 5.1 and Oracle RDBMS 11g (11.1.0.7). Even more – 6 such DB Machines can be connected into cluster.
&lt;br/&gt;&lt;b&gt;Where is the revolution?&lt;/b&gt; In the way Oracle DB communicates with storage. There is new protocol &lt;b&gt;iDB&lt;/b&gt; that allows to push query predicated down to storage. With this, number of data transferred from Storage to DB Server is minimized. This feature is called &lt;b&gt;Smart Scan&lt;/b&gt;. It can be leveraged only when full table (or partition) scans occurs. And it still keeps all read consistency.
&lt;br/&gt;And &lt;a href="http://www.oracle.com/solutions/business_intelligence/exadata.html"&gt;here is technical spec from Oracle&lt;/a&gt;.

&lt;br/&gt;&lt;br/&gt;And short on my other sessions:
&lt;b&gt;Oracle Database Performance on Flash Drives&lt;/b&gt;&lt;br/&gt;Very interesting session showing results of different approaches for using Flash drives. As an conclusion there was presented formula, when Flash drives can help with performance, and when it is better to stay with fast rotating drives, and when even with low cost but high capacity drives. As an side note when we consider power usage, Flash drives can be even more economic then traditional rotating drives.
&lt;br/&gt;&lt;br/&gt;&lt;b&gt;Oracle ACE Director: Birds-of-a-Feather Tips and Techniques&lt;/b&gt;&lt;br/&gt;Session lead by Oracle ACE’s: Lewis Cunningan, Arup Nunda, Edie Awad, Mark Rittman, Tim Hall, Hans Forbich and Bradley Brown. The session was Q&amp;A style. ACE’s were answering questions based on own experience, and that is sometimes different that Oracle’s official recommendation.
&lt;br/&gt;&lt;br/&gt;&lt;b&gt;Real-World XML DB Examples from Oracle Support&lt;/b&gt;&lt;br/&gt;This was rather chaotic session, and did not gave me useful information- IHMO waste of time.
&lt;br/&gt;&lt;br/&gt;And the last session by Tom Kyte &lt;b&gt;Reorganizing Objects&lt;/b&gt;&lt;br/&gt;
Tom have done great job showing different myths about when DBA’s should reorganize tables and indexes. It was really Great speech. Might be there was too much material for an 1h session, and everything was shown little bit in an hurry.
&lt;br/&gt;&lt;br/&gt;The day has ended with small party &lt;b&gt;It’s A WRAP&lt;/b&gt;&lt;br/&gt;
While writing this I’m sitting in hotel and watching Fireworks over the San Francisco Port. Tomorrow I’m leaving San Francisco for 18h trip back to home.
&lt;br/&gt;&lt;br/&gt;
Cheers, &lt;br/&gt;
Paweł&lt;br/&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Preparing for Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/09/preparing-for-oracle-openworld-2008.html"&gt;Preparing for Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Arriving San Francisco – OOW2008 day 1." href="http://pbarut.blogspot.com/2008/09/arriving-san-francisno-oow2008-day-1.html"&gt;Arriving San Francisco – OOW2008 day 1.&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 2 – Oracle Beehive" href="http://pbarut.blogspot.com/2008/09/oow2008-day-1-oracle-beehive.html"&gt;OOW2008 day 2 – Oracle Beehive&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 3" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3.html"&gt;OOW2008 day 3&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html"&gt;OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 5 – It’s A Wrap" href="http://pbarut.blogspot.com/2008/09/oow2008-day-5-its-wrap.html"&gt;OOW2008 day 5 – It’s A Wrap&lt;/a&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2656261515119608452?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2656261515119608452/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2656261515119608452' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2656261515119608452'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2656261515119608452'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/09/oow2008-day-5-its-wrap.html' title='OOW2008 day 5 – It’s A Wrap'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_6xECfZb_CD0/SNxrKkrjpTI/AAAAAAAAFfU/hwUkuXv91L8/s72-c/DSC_5468.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2414249852539756900</id><published>2008-09-25T01:25:00.004+02:00</published><updated>2008-11-25T22:13:51.676+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='hp'/><category scheme='http://www.blogger.com/atom/ns#' term='exadata'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br/&gt;
Today is very busy day for me. It’s just after Larry Ellison keynote on which first Oracle Hardware was presented. I’m a little big skeptic if Oracle is realy going for hardware business. It is rather that Oracle had great idea how to solve problems with really big databases and growing demand for storage, and joined forces with HP to create new quality in data processing. 
So, how it looks: in one box we have 2 intel 4 core processors and 12 disks as storage – it is called &lt;span style="font-weight:bold;"&gt;The Exadata Programmable Storage Server&lt;/span&gt;. This machine is not storage, and is not pure DB Server as well. It can process queries (so it is DB), and it stores Data (so it is Storage). But it needs separate DB Server to work at full performance. How it works: DB Servers receives request for data. It then retries data from Exadata Storage Server, but data get initially filtered, so number of data transferred from Storage Server to DB Server is reduced. It allows much better overall performance.
&lt;br/&gt;
At least this is my understanding. I will go also to DemoGround to get direct look at this machine, and more detailed specification.
&lt;br/&gt;&lt;br/&gt;

Today I’ve also participated in few sessions.&lt;br/&gt;
&lt;span style="font-weight:bold;"&gt;Soup-to-Nuts RAD Development Using Oracle SQL Developer and Oracle Application Express&lt;/span&gt;
It was quick show how to create simple application using APEX and SQL Developer. It focused on modeling capabilities of SQL Dev, and integration between APEX and SQL Dev. It was shown, how to view APEX objects in SQL Dev, and how to leverage this integration. There was also presentation of new functionality in APEX to migrate Oracle Forms to APEX.
&lt;br/&gt;&lt;br/&gt;

&lt;span style="font-weight:bold;"&gt;Agile Database Testing Techniques (IOUG)&lt;/span&gt;
This was very interesting session giving practical inside on how to organize unit tests in DB, how to validate that upgrade scripts run successfully, and how to prepare DB environment for Daily Builds. Presenter shared his real world experience and this was the biggest value of this session.
&lt;br/&gt;&lt;br/&gt;

&lt;span style="font-weight:bold;"&gt;SQL Tuning Roundtable with the Experts&lt;/span&gt;
This one was rather boring, as topics and answers were almost exactly the same as on session “Inside Oracle Database 11g Optimizer: Removing the Mystery” that I was participating yesterday.
&lt;br/&gt;&lt;br/&gt;

Now I’m sitting in OCP Louge, and in few minutes I’m going for last session
&lt;span style="font-weight:bold;"&gt;Managing Very, Very Large XML Documents with Oracle XML Database&lt;/span&gt;
and then for The Appreciation Event.
&lt;br/&gt;&lt;br/&gt;
Cheers,
&lt;br/&gt;
Paweł
&lt;br/&gt;&lt;br/&gt;
BTW. This is my post # 100.&lt;br/&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Preparing for Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/09/preparing-for-oracle-openworld-2008.html"&gt;Preparing for Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Arriving San Francisco – OOW2008 day 1." href="http://pbarut.blogspot.com/2008/09/arriving-san-francisno-oow2008-day-1.html"&gt;Arriving San Francisco – OOW2008 day 1.&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 2 – Oracle Beehive" href="http://pbarut.blogspot.com/2008/09/oow2008-day-1-oracle-beehive.html"&gt;OOW2008 day 2 – Oracle Beehive&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 3" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3.html"&gt;OOW2008 day 3&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html"&gt;OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 5 – It’s A Wrap" href="http://pbarut.blogspot.com/2008/09/oow2008-day-5-its-wrap.html"&gt;OOW2008 day 5 – It’s A Wrap&lt;/a&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2414249852539756900?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2414249852539756900/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2414249852539756900' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2414249852539756900'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2414249852539756900'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html' title='OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-983553222007628276</id><published>2008-09-24T06:08:00.004+02:00</published><updated>2008-11-25T22:13:27.675+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>OOW2008 day 3</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br/&gt;
This day was quite good for me. I’ve finally overcome problems with jet-lag. 
&lt;br/&gt;&lt;br/&gt;
I’ve started day on session “Inside Oracle Database 11g Optimizer: Removing the Mystery”. It was very good session explaining how new features in optimizer works. It provided inside on Plan Profiles, improved bind variable picking, improved performance for statistics collection and new statistics for correlated columns.
&lt;br/&gt;&lt;br/&gt;
My next session was not exactly what I was expecting. “Global-Scale Web 2.0 Data Platforms: Sharding with Oracle Database”. I was expecting technical inside, but it mostly was marketing speech on “why Oracle is better then MySQL”.
Break between sessions I’ve used to ride on Cable Car:&lt;br/&gt;
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_6xECfZb_CD0/SNm9d8T9WAI/AAAAAAAAFac/ewLnkKuTSQ8/s1600-h/DSC_5352.JPG"&gt;&lt;img style="cursor:pointer; cursor:hand;" src="http://4.bp.blogspot.com/_6xECfZb_CD0/SNm9d8T9WAI/AAAAAAAAFac/ewLnkKuTSQ8/s400/DSC_5352.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5249435162780719106" /&gt;&lt;/a&gt;&lt;br/&gt;&lt;br/&gt;
I’ve ended day on session “Top 10 Things You Wanted to know about ASM”. As I were not using ASM yet, it was good overview of features, and best practices for using ASM.
Now, I’m going to rest to be prepared for next day, and big keynote by Larry Ellison.
&lt;br/&gt;&lt;br/&gt;
Cheers,&lt;br/&gt;
Paweł&lt;br/&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Preparing for Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/09/preparing-for-oracle-openworld-2008.html"&gt;Preparing for Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Arriving San Francisco – OOW2008 day 1." href="http://pbarut.blogspot.com/2008/09/arriving-san-francisno-oow2008-day-1.html"&gt;Arriving San Francisco – OOW2008 day 1.&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 2 – Oracle Beehive" href="http://pbarut.blogspot.com/2008/09/oow2008-day-1-oracle-beehive.html"&gt;OOW2008 day 2 – Oracle Beehive&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 3" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3.html"&gt;OOW2008 day 3&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html"&gt;OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 5 – It’s A Wrap" href="http://pbarut.blogspot.com/2008/09/oow2008-day-5-its-wrap.html"&gt;OOW2008 day 5 – It’s A Wrap&lt;/a&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-983553222007628276?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/983553222007628276/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=983553222007628276' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/983553222007628276'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/983553222007628276'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/09/oow2008-day-3.html' title='OOW2008 day 3'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://4.bp.blogspot.com/_6xECfZb_CD0/SNm9d8T9WAI/AAAAAAAAFac/ewLnkKuTSQ8/s72-c/DSC_5352.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1957981809525972975</id><published>2008-09-23T17:23:00.006+02:00</published><updated>2008-11-25T22:12:04.932+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='beehive'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>OOW2008 day 2 – Oracle Beehive</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br/&gt;
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_6xECfZb_CD0/SNkKiAaZDoI/AAAAAAAAFaM/AOba3FXzgZc/s1600-h/DSC_5306.JPG"&gt;&lt;img style="float:right; margin:0 0 10px 10px;cursor:pointer; cursor:hand;" src="http://1.bp.blogspot.com/_6xECfZb_CD0/SNkKiAaZDoI/AAAAAAAAFaM/AOba3FXzgZc/s400/DSC_5306.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5249238420019547778" /&gt;&lt;/a&gt;This day started with Keynote presented by Oracle President Charles Phillips. He spoke about Oracle acquisitions, and more complete portfolio of products that Oracle have now. What caught my attention most was announcement of new product, new collaboration platform Oracle Beehive. It joins features of email, calendar, document sharing, web conference and few more in one suite. What is most important those tools are open, so user can use ex. MS Outlook to access mails or calendar entries. Security is one of the key features. When you share document with others, they can see document in theirs workspace. They can even make local copy of this document. When document is deleted by original author, then all copies of the document become unusable for anyone. This is because all shared documents are encrypted and signed. While opening document there is validation of access rights for document. For me it seems as this is based on technology acquired from Stallent.
It seems that this product will try to get market from MS Sharepoint and IBM Lotus.&lt;br/&gt;&lt;br/&gt;

Today I took some time to see Exhibition Hall, and walk around the city. While walking I’ve found one interesting bus – I was Bus that was advertising Microsoft SQLServer:&lt;br/&gt;
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://4.bp.blogspot.com/_6xECfZb_CD0/SNkK37pd4SI/AAAAAAAAFaU/TgthKlRX91o/s1600-h/DSC_5318.JPG"&gt;&lt;img style="cursor:pointer; cursor:hand;" src="http://4.bp.blogspot.com/_6xECfZb_CD0/SNkK37pd4SI/AAAAAAAAFaU/TgthKlRX91o/s400/DSC_5318.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5249238796697723170" /&gt;&lt;/a&gt;
&lt;br/&gt;It looks pretty old :). Microsoft does not want to be absent in San Francisco during Oracle’s big conference.&lt;br/&gt;&lt;br/&gt;

I’ve also participated in few session on SOA (Service Oriented Architecture) and AIA (Applications Integration Architecture). Basically I wanted to have better understanding of Oracle offering in SOA area.
&lt;br/&gt;&lt;br/&gt;
Cheers,&lt;br/&gt;
Paweł&lt;br/&gt;&lt;br/&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Preparing for Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/09/preparing-for-oracle-openworld-2008.html"&gt;Preparing for Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Arriving San Francisco – OOW2008 day 1." href="http://pbarut.blogspot.com/2008/09/arriving-san-francisno-oow2008-day-1.html"&gt;Arriving San Francisco – OOW2008 day 1.&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 2 – Oracle Beehive" href="http://pbarut.blogspot.com/2008/09/oow2008-day-1-oracle-beehive.html"&gt;OOW2008 day 2 – Oracle Beehive&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 3" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3.html"&gt;OOW2008 day 3&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html"&gt;OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 5 – It’s A Wrap" href="http://pbarut.blogspot.com/2008/09/oow2008-day-5-its-wrap.html"&gt;OOW2008 day 5 – It’s A Wrap&lt;/a&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1957981809525972975?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1957981809525972975/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1957981809525972975' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1957981809525972975'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1957981809525972975'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/09/oow2008-day-1-oracle-beehive.html' title='OOW2008 day 2 – Oracle Beehive'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_6xECfZb_CD0/SNkKiAaZDoI/AAAAAAAAFaM/AOba3FXzgZc/s72-c/DSC_5306.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6644812268513776202</id><published>2008-09-22T02:41:00.007+02:00</published><updated>2008-11-25T22:11:17.383+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='storage'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Arriving San Francisco – OOW2008 day 1.</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br/&gt;
My trip to San Francisco went well. No delays, no problems with flight reservation – see &lt;a href="http://www.oracle-base.com/blog/2008/09/20/mor-frankfurt-news/"&gt;what happened to Tim&lt;/a&gt;. I had small problems with hotel reservation, but finally everything is fine – I’m in different hotel then I’ve reserved. I’m suffering little from jet-lag. I slept an hour or two in plane, and then I could not sleep during night. So I feel little tired. The weather in SF is great, especially when comparing to very cold and rainy weather in Krakow last week.
&lt;br/&gt;&lt;br/&gt;
My first experience of San Fracinsco is not very good. Seems to be not very friendly, and is definitely not of my style. I might change my mind when see more places in SF. But Oracle Conference is organized very well, so my attitude is improving :).
&lt;br/&gt;&lt;br/&gt;
For today, I’ve planned mostly session regarding Security and Identity management.
First of those session “Oracle Security Risk” was very good. Especially speaker Tanya Baccam from &lt;a href="http://www.sans.org/"&gt;SANS.org&lt;/a&gt; was impressive. Presentation was about common problems with security in web based and forms application that use Oracle DB as backend. One type of attack was new to me: CSRF – Cross Site Request Forgery.
&lt;br/&gt;&lt;br/&gt;
Next one was Security Roundtable – lot of questions from audience on variety of topics. Most hot one: applying CPU patches, Auditing, DB Valut, Encrypting data and transmissions.
&lt;br/&gt;&lt;br/&gt;
Then was Oracle Identity Management lead by &lt;a href="http://www.matttopper.com/"&gt;Matt Topper&lt;/a&gt;. Good overview of  identity products from Oracle stack.
&lt;br/&gt;&lt;br/&gt;
My last one session “Storage: A New Paradigm for Database” was also very good session. Ari Kaplan show now storage solutions can improve Backup/Restore times for database and decrease demand for storage space. He also presented new RAID-DP concept, and claims that it can provide better performance, with lower storage demand, and provide higher availability. This is something that I need to investigate in more details.
&lt;br/&gt;&lt;br/&gt;
For the evening I’m going to take part in Bloggers Meetup.
&lt;br/&gt;&lt;br/&gt;
Cheers,&lt;br/&gt;
Paweł&lt;br/&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Preparing for Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/09/preparing-for-oracle-openworld-2008.html"&gt;Preparing for Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Arriving San Francisco – OOW2008 day 1." href="http://pbarut.blogspot.com/2008/09/arriving-san-francisno-oow2008-day-1.html"&gt;Arriving San Francisco – OOW2008 day 1.&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 2 – Oracle Beehive" href="http://pbarut.blogspot.com/2008/09/oow2008-day-1-oracle-beehive.html"&gt;OOW2008 day 2 – Oracle Beehive&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 3" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3.html"&gt;OOW2008 day 3&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance" href="http://pbarut.blogspot.com/2008/09/oow2008-day-3-hp-oracle-exadata-server.html"&gt;OOW2008 day 4 – HP-Oracle Exadata Server Announcement = Extreme Performance&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="OOW2008 day 5 – It’s A Wrap" href="http://pbarut.blogspot.com/2008/09/oow2008-day-5-its-wrap.html"&gt;OOW2008 day 5 – It’s A Wrap&lt;/a&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6644812268513776202?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6644812268513776202/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6644812268513776202' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6644812268513776202'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6644812268513776202'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/09/arriving-san-francisno-oow2008-day-1.html' title='Arriving San Francisco – OOW2008 day 1.'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2310412554757052853</id><published>2008-09-13T11:41:00.003+02:00</published><updated>2008-09-13T12:38:58.454+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Preparing for Oracle OpenWorld 2008</title><content type='html'>&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://1.bp.blogspot.com/_6xECfZb_CD0/SMuLSzhMMqI/AAAAAAAAFaE/o9Jb0hCSsXE/s1600-h/OOW+Onsite+banner.JPG"&gt;&lt;img style="float:right; margin:0 10px 10px 0;cursor:pointer; cursor:hand;" src="http://1.bp.blogspot.com/_6xECfZb_CD0/SMuLSzhMMqI/AAAAAAAAFaE/o9Jb0hCSsXE/s400/OOW+Onsite+banner.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5245439346186400418" /&gt;&lt;/a&gt;
&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
It's just few days left to Oracle OpenWorld 2008. First of all my trip starts on Saturday 20th at 13:00 in Kraków, Poland. Then I switch planes in Munich, Germany, and land in San Francisco at 19:20. Just 6 hours ahead, but when I add 9 hours difference in time zones, that it adds up to over 15 hours travel. The worst thing will be adaptation to totally different timezone. I will stay in Americas Best Value Inn at Hallam Street - I hope this is in reasonable walking distance from Moscone Center. I've created an &lt;a title="map" href="http://maps.google.com/maps/ms?ie=UTF8&amp;amp;hl=en&amp;amp;msa=0&amp;amp;msid=112789957786157312975.000451821af69a70e8bf7&amp;amp;ll=37.783333,-122.401257&amp;amp;spn=0.044567,0.077248&amp;amp;z=14" id="a:fl"&gt;map&lt;/a&gt; on Google Maps - the street view feature is great - now I know how the hotel neighborhood looks like. I've also checked transportation services by &lt;a title="BART" href="http://www.bart.gov/schedules/quickplanner.aspx?orig=SFIA&amp;amp;dest=CIVC&amp;amp;type=departure&amp;amp;time=9%3A00+PM&amp;amp;date=9%2F20%2F2008" id="s4mm"&gt;BART&lt;/a&gt;. &lt;br&gt;
And the most important thing - &lt;a title="My OOW2008 Schedule" href="http://spreadsheets.google.com/pub?key=pHTrQsufqUNW-oAmOJdh6Lw" id="l0fk"&gt;My OOW2008 Schedule&lt;/a&gt;:&lt;br&gt;
&lt;iframe src="http://spreadsheets.google.com/pub?key=pHTrQsufqUNW-oAmOJdh6Lw" width="700" frameborder="0" height="300"&gt;&lt;/iframe&gt;&lt;br&gt;
I do not expect big changes in this schedule, but still, some smaller changes are possible. I could skip one or more sessions to see &lt;a title="Exhibition Hall" href="http://www.oracle.com/openworld/2008/exhibitor-center.html" id="v8nc"&gt;Exhibition Hall&lt;/a&gt; or go for &lt;a title="Unconference" href="http://wiki.oracle.com/page/Oracle+OpenWorld+Unconference" id="im4."&gt;Unconference&lt;/a&gt;.&lt;br&gt;
I'm also looking forward for meeting other Oracle Bloggers during &lt;a title="Blogger Meetup" href="http://www.oraclecommunity.net/events/event/show?id=1988559:Event:20142" id="gwm9"&gt;Blogger Meetup&lt;/a&gt; organized by &lt;a title="Eddie Awad" href="http://awads.net/wp/" id="n5vj"&gt;Eddie Awad&lt;/a&gt;.&lt;br&gt;
&lt;b&gt;Update:&lt;/b&gt; I forgot to mention about &lt;a href="http://www.oracle.com/openworld/2008/after-dark.html"&gt;After Dark at Oracle OpenWorld&lt;/a&gt; where are evening parties listed.
&lt;br&gt;&lt;br&gt;
See you in San Francisco,&lt;br id="oe53"&gt;
Paweł&lt;br id="fy0e"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html" id="htsi"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="One Year Blogging" href="http://pbarut.blogspot.com/2007/09/one-year-blogging.html" id="ai7x"&gt;One Year Blogging&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Blogger Beta Backup tool" href="http://pbarut.blogspot.com/2006/11/blogger-beta-backup-tool.html" id="nmh9"&gt;Blogger Beta Backup tool&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="UTL_MATCH - String Similarity in Oracle" href="http://pbarut.blogspot.com/2006/12/utlmatch-string-similarity-in-oracle.html" id="c.bg"&gt;UTL_MATCH - String Similarity in Oracle&lt;/a&gt; &lt;/li&gt;
&lt;li&gt;&lt;a title="Rolling Back the DDL" href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html" id="t3ez"&gt;Rolling Back the DDL&lt;/a&gt; &lt;/li&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2310412554757052853?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2310412554757052853/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2310412554757052853' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2310412554757052853'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2310412554757052853'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/09/preparing-for-oracle-openworld-2008.html' title='Preparing for Oracle OpenWorld 2008'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://1.bp.blogspot.com/_6xECfZb_CD0/SMuLSzhMMqI/AAAAAAAAFaE/o9Jb0hCSsXE/s72-c/OOW+Onsite+banner.JPG' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1399508944757739844</id><published>2008-08-13T20:59:00.001+02:00</published><updated>2008-08-14T10:59:21.228+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='error'/><category scheme='http://www.blogger.com/atom/ns#' term='dba'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>DB Link to Oracle 11g</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
As you know in Oracle 11g passwords are case sensitive by default. This applies to connecting via SQL*Plus or other client tools. And it also applies to database links between databases. So when you link from Oracle 10g to Oracle 11g create database link like this:&lt;br id="avjj"&gt;
&lt;blockquote id="y2fl"&gt;&lt;b id="r2yj"&gt;CREATE DATABASE LINK my_link&lt;br id="avjj0"&gt;
CONNECT TO remote_user IDENTIFIED BY "CaSe_SeNsItIvE_PaSsWoRd"&lt;br id="qkpg"&gt;
USING 'TNS_ID_11G';&lt;/b&gt;&lt;br id="b:ch"&gt;
&lt;/blockquote&gt;
Do not forget to enclose password by double-quote marks!
&lt;br&gt;When you do not set password this way, you will be getting: &lt;br id="r2yj0"&gt;
&lt;blockquote id="r2yj1"&gt;&lt;b id="r2yj2"&gt;ORA-01017: invalid username/password; logon denied.&lt;/b&gt;&lt;br id="r76l"&gt;
&lt;/blockquote&gt;
Hope this small tip will be useful for someone.&lt;br id="qkpg0"&gt;
&lt;br id="oe53"&gt;
Paweł&lt;br id="fy0e"&gt;
&lt;br id="fy0e0"&gt;
More on &lt;a title="Creating Database Links" href="http://download.oracle.com/docs/cd/B28359_01/server.111/b28286/statements_5005.htm#SQLRF01205" id="c8n:"&gt;Creating Database Links&lt;/a&gt;.&lt;br id="arum0"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br id="ag3o"&gt;
&lt;ul id="lrkd"&gt;
&lt;li id="lrkd0"&gt;&lt;a title="Using Named Parameters within SQL" href="http://pbarut.blogspot.com/2007/10/using-named-parameters-within-sql.html" id="ojn2"&gt;Using Named Parameters within SQL&lt;/a&gt; &lt;/li&gt;
&lt;li id="lrkd1"&gt;&lt;a title="Oracle 11g is released - my links" href="http://pbarut.blogspot.com/2007/08/oracle-11g-is-released-my-links.html" id="eaf1"&gt;Oracle 11g is released - my links&lt;/a&gt; &lt;/li&gt;
&lt;li id="lrkd2"&gt;&lt;a title="Table that cannot be deleted" href="http://pbarut.blogspot.com/2007/03/table-that-cannot-be-deleted.html" id="mcgb"&gt;Table that cannot be deleted&lt;/a&gt; &lt;/li&gt;
&lt;li id="lrkd3"&gt;&lt;a title="ORA-03297 on empty datafile" href="http://pbarut.blogspot.com/2007/01/ora-03297-on-empty-datafile.html" id="o855"&gt;ORA-03297 on empty datafile&lt;/a&gt; &lt;/li&gt;
&lt;li id="lrkd4"&gt;&lt;a title="Rolling Back the DDL" href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html" id="xp8x"&gt;Rolling Back the DDL&lt;/a&gt; &lt;/li&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1399508944757739844?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1399508944757739844/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1399508944757739844' title='19 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1399508944757739844'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1399508944757739844'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/08/db-link-to-oracle-11g.html' title='DB Link to Oracle 11g'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>19</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-95761385982870764</id><published>2008-08-04T23:09:00.002+02:00</published><updated>2008-12-10T23:58:15.886+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='software'/><category scheme='http://www.blogger.com/atom/ns#' term='photos'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>Lost Pictures - Recovered Pictures</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
This weekend I've spend great time with family, and we make lot of pictures. But when I've arrived home, and plugged camera to PC, it looked like this:&lt;img src="http://2.bp.blogspot.com/_6xECfZb_CD0/SJdwlTcfY1I/AAAAAAAAFXI/plTqywl4kq8/s400/broken_pictures.JPG" border="0" alt=""id="BLOGGER_PHOTO_ID_5230773278391362386" /&gt;&lt;br id="otmk"&gt;
All pictures seems gone ...&lt;br id="g9f9"&gt;
For us computer geeks data lost is not an option. I've started to look for tools that can help me recover those data. In such situation rule number one is: not allow to write anything on this storage. Any additional write could lead to total data lost. I've googl`ed for software that could help. I've found lot of software that does "FAT Recovery", "Recover Digital Camera", "Data Recovery" - most of them priced 49-200$. Well, not big money, but still quite many when you need to recover 50 pictures. And you never know, if this software is worth it, and will solve your problem.&lt;br id="f_cd"&gt;
Finally I've found really great software that I would like to recommend: &lt;a title="PC INSPECTOR™ smart recovery" href="http://www.pcinspector.de/Sites/smart_recovery/info.htm?language=1" id="ckvy"&gt;PC INSPECTOR™ smart recovery&lt;/a&gt;. It run very fast, and recovered almost all pictures. When looking into Camera counter and number of files, only one picture is missing. This software is freeware, but authors wants us to "Pay What You Want". And I've did it, as this software did his job perfectly.&lt;br id="v.g0"&gt;
Hope it help someone else to recover lost pictures.&lt;br id="q.fk"&gt;
&lt;br id="oe53"&gt;
Paweł&lt;br id="arum0"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br id="ag3o"&gt;
&lt;ul id="y_8."&gt;&lt;/ul&gt;
&lt;ul id="sxmg"&gt;
&lt;li id="sxmg0"&gt;&lt;a title="Oracle OpenWorld 2008" href="http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html" id="zzo7"&gt;Oracle OpenWorld 2008&lt;/a&gt; &lt;/li&gt;
&lt;li id="sxmg1"&gt;&lt;a title="Pictures on Google map" href="http://pbarut.blogspot.com/2007/07/pictures-on-google-map.html" id="niv8"&gt;Pictures on Google map&lt;/a&gt; &lt;/li&gt;
&lt;li id="sxmg2"&gt;&lt;a title="Rant: Great fun with Wii" href="http://pbarut.blogspot.com/2007/12/rant-great-fun-with-wii.html" id="cp9o"&gt;Rant: Great fun with Wii&lt;/a&gt; &lt;/li&gt;
&lt;li id="sxmg3"&gt;&lt;a title="13 – Happy or Unhappy Number?" href="http://pbarut.blogspot.com/2006/09/13-happy-or-unhappy-number.html" id="fofs"&gt;13 – Happy or Unhappy Number?&lt;/a&gt; &lt;/li&gt;
&lt;li id="sxmg4"&gt;&lt;a title="Autobackup of SPFILE and CONTROLFILE" href="http://pbarut.blogspot.com/2007/01/autobackup-of-spfile-and-controlfile.html" id="geug"&gt;Autobackup of SPFILE and CONTROLFILE&lt;/a&gt; &lt;/li&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-95761385982870764?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/95761385982870764/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=95761385982870764' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/95761385982870764'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/95761385982870764'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/08/lost-pictures-recovered-pictures.html' title='Lost Pictures - Recovered Pictures'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_6xECfZb_CD0/SJdwlTcfY1I/AAAAAAAAFXI/plTqywl4kq8/s72-c/broken_pictures.JPG' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8883017179768340949</id><published>2008-07-17T22:44:00.001+02:00</published><updated>2008-07-17T22:46:16.630+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='oow2008'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle OpenWorld 2008</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
It's only 2 month left to &lt;a title="Oracle OpenWorld 2008" href="http://www.oracle.com/openworld/2008/index.html" id="d1l8"&gt;Oracle OpenWorld 2008&lt;/a&gt;. Few news about this conference and my first time ever participation. Last week I've registered for &lt;a title="OOW2008 as Blogger" href="http://blogs.oracle.com/otn/2008/06/13/#a1335" id="xouv"&gt;OOW2008 as Blogger&lt;/a&gt;. Yesterday I've received confirmation email - I was accepted. I'm really looking forward to be in San Francisco and meet with all Oracle geeks, enthusiast and other bloggers.&lt;br id="tc-w"&gt;
I still need to apply for US Visa, and organize my trip. And of course &lt;a title="choose sessions" href="http://www28.cplan.com/cc208/catalog.jsp" id="cllz"&gt;choose sessions&lt;/a&gt; in which I would like to participate.&lt;br id="kiid"&gt;
&lt;br id="kiid0"&gt;
There is also one good news for people in Eastern Europe, Post Soviet Republics, Middle East &amp;amp; Asia. People from those countries can get discount on registration fee.&lt;br id="eukj"&gt;
&lt;blockquote id="eukj0"&gt;Attendees will need to enter &lt;b id="dp6s"&gt;EMKT&lt;/b&gt; as their   priority code during "Step 2" of the registration process. 
&lt;p id="eukj1"&gt;The countries from the EE, CIS &amp;amp;   MEA regions which qualify for the discount   are:&lt;/p&gt;
&lt;p id="eukj2"&gt;African
Operations (except South Africa), Albania, Armenia, Azerbaijan,
Belarus, Bosnia &amp;amp; Herzegovina, Bulgaria, Croatia, Czech Republic,
Cyprus, Estonia, FYR Macedonia, Georgia, Hungary, Iraq, Iran, Jordan,
Kazakhstan, Kyrgyzstan, Latvia, Lebanon, Lithuania, Malta, Moldova,
Montenegro, Oman, Palestine, Poland, Romania, Russia, Serbia, Slovakia,
Slovenia, Syria, Tajikistan, Turkey, Turkmenistan, Ukraine, Uzbekistan,
and Yemen.&lt;/p&gt;
&lt;/blockquote&gt;
                  
                  Do not wait. Register for Oracle OpenWorld 2008 !&lt;br id="arum"&gt;
&lt;br id="oe53"&gt;
Paweł&lt;br id="arum0"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br id="ag3o"&gt;
&lt;ul id="y_8."&gt;
&lt;li id="y_8.0"&gt;&lt;a title="One Year Blogging" href="http://pbarut.blogspot.com/2007/09/one-year-blogging.html" id="cbkr"&gt;One Year Blogging&lt;/a&gt; &lt;/li&gt;
&lt;li id="y_8.1"&gt;&lt;a title="I've been tagged 3 times; 8 things about me" href="http://pbarut.blogspot.com/2008/01/ive-been-tagged-3-times-8-things-about.html" id="fia2"&gt;I've been tagged 3 times; 8 things about me&lt;/a&gt; &lt;/li&gt;
&lt;li id="y_8.2"&gt;&lt;a title="Oracle 11g new features" href="http://pbarut.blogspot.com/2006/10/oracle-11g-new-features.html" id="twzg"&gt;Oracle 11g new features&lt;/a&gt;&lt;/li&gt;
&lt;li id="dhd2"&gt;&lt;a title="Oracle 11g new features, part 2" href="http://pbarut.blogspot.com/2006/10/oracle-11g-new-features-part-2.html" id="rbnf"&gt;Oracle 11g new features, part 2&lt;/a&gt; &lt;/li&gt;
&lt;a title="Oracle 11g new features, part 2" href="http://pbarut.blogspot.com/2006/10/oracle-11g-new-features-part-2.html" id="ek9t"&gt;&lt;/a&gt; 
&lt;li id="y_8.3"&gt;&lt;a title="Oracle Database 11g Release 2 is coming" href="http://pbarut.blogspot.com/2008/04/oracle-database-11g-release-2-is-coming.html" id="wshr"&gt;Oracle Database 11g Release 2 is coming&lt;/a&gt; &lt;/li&gt;
&lt;/ul&gt;
&lt;br id="kiid1"&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8883017179768340949?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8883017179768340949/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8883017179768340949' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8883017179768340949'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8883017179768340949'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/07/oracle-openworld-2008.html' title='Oracle OpenWorld 2008'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8148551470589293550</id><published>2008-05-17T11:55:00.000+02:00</published><updated>2008-05-17T11:57:12.421+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='error'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>ORA-00904: "XMLROOT": invalid identifier</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt;&lt;br id="qt6l"&gt;
Some time ago I've had noticed strange problem with XMLRoot function. I was installing application on production server and I've noticed that code:&lt;br id="gh980"&gt;
&lt;blockquote id="om_g0"&gt;SQL&amp;gt; select XMLRoot(xmltype('&amp;lt;a&amp;gt;a&amp;lt;/a&amp;gt;'))&lt;br id="cl:x0"&gt;
&amp;nbsp; 2&amp;nbsp; from dual;&lt;br id="om_g1"&gt;
&lt;/blockquote&gt;
gives error:&lt;br id="cl:x1"&gt;
&lt;blockquote id="suwk0"&gt;select XMLRoot(xmltype('&amp;lt;a&amp;gt;a&amp;lt;/a&amp;gt;'))&lt;br id="cl:x2"&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; *&lt;br id="cl:x3"&gt;
Error in line 1:&lt;br id="cl:x4"&gt;
ORA-00904: "XMLROOT": invalid identifier&lt;br id="om_g2"&gt;
&lt;/blockquote&gt;
WTF, &lt;span id="pnfl0"&gt;&lt;b id="tk4g0"&gt;it was running perfectly on development &lt;/b&gt;&lt;/span&gt;and test environment!&lt;br id="g3tr0"&gt;
Quick search revealed that XMLROOT is function in XDB schema, which was missing in production environment. I've just copies source code for function from test environment and I could proceed further.&lt;br id="d-vf0"&gt;
After some time, I've decided to check &lt;span id="shue0"&gt;&lt;b id="tk4g1"&gt;why this function was missing?&lt;/b&gt;&lt;/span&gt;&lt;br id="d-vf1"&gt;
Quick search showed that function is created by script ?\demo\schema\order_entry\xdbUtilities.sql&lt;br id="shue1"&gt;
Strange, well documented function is created &lt;span id="shue2"&gt;&lt;b id="tk4g2"&gt;only when you install demo schemas?&lt;/b&gt;&lt;/span&gt;&lt;span id="shue2"&gt; Seems that there should be another explanation.&lt;br id="bksz0"&gt;
Then I've found that in &lt;a title="documentation" href="http://download.oracle.com/docs/cd/B28359_01/server.111/b28286/functions233.htm#SQLRF06230" id="lr2u"&gt;documentation&lt;/a&gt; this function has 2 mandatory attributes, while my code has only one attribute. So there are 2 versions of XMLRoot function:&lt;br id="i1cq0"&gt;
&lt;/span&gt;
&lt;ol id="i1cq1"&gt;
&lt;li id="i1cq2"&gt;SQL function; see &lt;span id="shue2"&gt;&lt;a title="documentation" href="http://download.oracle.com/docs/cd/B28359_01/server.111/b28286/functions233.htm#SQLRF06230" id="lr2u"&gt;documentation&lt;/a&gt;&lt;/span&gt;&lt;/li&gt;
&lt;li id="i1cq3"&gt;&lt;span id="shue2"&gt;Simplified version created by demo in XDB schema - this version can be also used in PL/SQL&lt;/span&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;span id="uwpk0"&gt;&lt;br id="uwpk1"&gt;
&lt;b id="tk4g3"&gt;Conclusion:&lt;/b&gt;&lt;/span&gt; my original code &lt;span id="uwpk2"&gt;&lt;b id="tk4g4"&gt;should look like that&lt;/b&gt;&lt;/span&gt;:&lt;br id="z6v_0"&gt;
&lt;blockquote id="ez5j0"&gt;SQL&amp;gt; select XMLRoot(xmltype('&amp;lt;a&amp;gt;a&amp;lt;/a&amp;gt;')&lt;span id="ez5j1"&gt;&lt;b id="tk4g5"&gt;, version '1.0', standalone yes&lt;/b&gt;&lt;/span&gt;)&lt;br id="ez5j2"&gt;
&amp;nbsp; 2&amp;nbsp; from dual;&lt;br id="ez5j3"&gt;
&lt;br id="ez5j4"&gt;
XMLROOT(XMLTYPE('&amp;lt;A&amp;gt;A&amp;lt;/A&amp;gt;'),VERSION'1.0',STANDALONEYES)&lt;br id="ez5j5"&gt;
------------------------------------------------------------------------&lt;br id="ez5j6"&gt;
&lt;br id="ez5j7"&gt;
&amp;lt;?xml version="1.0" standalone="yes"?&amp;gt;&lt;br id="ez5j8"&gt;
&amp;lt;a&amp;gt;a&amp;lt;/a&amp;gt;&lt;br id="ez5j9"&gt;
&lt;/blockquote&gt;
This can run without XMLROOT function in XDB schema.&lt;br id="njv_0"&gt;
&lt;br id="njv_1"&gt;
Hope this will help someone to save some time.&lt;br id="njv_2"&gt;
Cheers,Paweł&lt;br id="z6v_1"&gt;
&lt;br id="pyix"&gt;
-- &lt;br id="rjx:"&gt;
Related Articles on Paweł Barut blog:&lt;br id="f-0t0"&gt;
&lt;ul id="f-0t1"&gt;
&lt;li id="f-0t2"&gt;&lt;a title="Useful links on Oracle XML DB" href="http://pbarut.blogspot.com/2008/02/useful-links-on-oracle-xml-db.html" id="wfzj"&gt;Useful links on Oracle XML DB&lt;/a&gt;&lt;/li&gt;
&lt;li id="f-0t3"&gt;&lt;a title="Solving ORA-22905: cannot access rows from a non-nested table item" href="http://pbarut.blogspot.com/2007/05/solving-ora-22905-cannot-access-rows.html" id="il1_"&gt;Solving ORA-22905: cannot access rows from a non-nested table item&lt;/a&gt;&lt;/li&gt;
&lt;li id="f-0t4"&gt;&lt;a title="Oracle XMLType: exctractvalue vs. extract" href="http://pbarut.blogspot.com/2007/01/oracle-xmltype-exctractvalue-vs-extract.html" id="p562"&gt;Oracle XMLType: exctractvalue vs. extract&lt;/a&gt;&lt;/li&gt;
&lt;li id="f-0t5"&gt;&lt;a title="Binding list variable" href="http://pbarut.blogspot.com/2006/10/binding-list-variable.html" id="e7_7"&gt;Binding list variable&lt;/a&gt;&lt;/li&gt;
&lt;li id="f-0t6"&gt;&lt;a title="Empty String IS NOT NULL?" href="http://pbarut.blogspot.com/2007/02/empty-string-is-not-null.html" id="amwp"&gt;Empty String IS NOT NULL?&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8148551470589293550?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8148551470589293550/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8148551470589293550' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8148551470589293550'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8148551470589293550'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/05/ora-00904-xmlroot-invalid-identifier.html' title='ORA-00904: &quot;XMLROOT&quot;: invalid identifier'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1282930488238759401</id><published>2008-04-20T15:40:00.001+02:00</published><updated>2008-04-20T15:45:59.298+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='dba'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle CPUApr2008 for DB: 10.2.0.4 patch set  and first install</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt; &lt;br id="qt6l"&gt;To my surprise CPUApr2008 is not available for latest patch-set of Oracle 10gR2 (10.2.0.4) that was released in first quarter 2008. In note that goes together with patch 6810189:&lt;br id="w4vz"&gt;&lt;blockquote id="ss7g"&gt;The following are the updated components of this patch set:&lt;br id="w-0m"&gt;&amp;nbsp; * Up to January 2008 CPU is included in this patch set&lt;br id="xy9_"&gt;...&lt;br id="h3ln"&gt;&lt;/blockquote&gt;Based on this I was expecting that CPUApr2008 will be also available for 10.2.0.4 patch-set. In note 552248.1 you will find then:&lt;br id="ibz."&gt;&lt;blockquote id="f85g"&gt;&lt;p id="jxuz" style="font-weight: bold;"&gt;1.3 Database 10.2.0.4 Patch Set&lt;/p&gt;&lt;p id="z300"&gt;The Database 10.2.0.4 Patch Set includes the CPUApr2008 content.&lt;/p&gt;&lt;/blockquote&gt;
&lt;p id="tl7r"&gt;So the CPUApt2008 was available to all at least &lt;span id="c8gr" style="font-weight: bold;"&gt;month before &lt;/span&gt;official release and &lt;span id="vxzk" style="font-weight: bold;"&gt;was included in 10.2.0.4 patch set&lt;/span&gt;! &lt;span id="x016" style="font-weight: bold;"&gt;Is this situation secure?&lt;/span&gt;&lt;br id="vj8g"&gt;&lt;/p&gt;&lt;br id="p05v"&gt;&lt;p id="tl7r"&gt;Anyway I had to install CPUApr2008. It's good that there is no need &lt;a title="to recompile views" href="http://pbarut.blogspot.com/2008/02/cpujan2008-one-thing-that-every-dba.html" id="c9n4"&gt;to recompile views&lt;/a&gt; this time. I've sucessfully installed it on test server, with minor problem. In installation log I've found one problem:&lt;br id="egmh"&gt;&lt;/p&gt;&lt;blockquote id="lvmv"&gt;&lt;p id="tl7r"&gt;BEGIN emd_maintenance.recompile_invalid_objects; END;&lt;br id="uc4y"&gt;&lt;br id="xm4y"&gt;*&lt;br id="k436"&gt;ERROR at line 1:&lt;br id="bk4k"&gt;ORA-04068: existing state of packages has been discarded&lt;br id="ogpn"&gt;ORA-04061: existing state of package body "SYSMAN.EMD_MAINTENANCE" has been&lt;br id="ef7r"&gt;invalidated&lt;br id="pw.s"&gt;ORA-06508: PL/SQL: could not find program unit being called:&lt;br id="d4vf"&gt;"SYSMAN.EMD_MAINTENANCE"&lt;br id="z0_b"&gt;ORA-06512: at line 1&lt;br id="evhd"&gt;&lt;/p&gt;&lt;/blockquote&gt;Hmm... After reconnecting, this commend run without errors:&lt;br id="gfou"&gt;&lt;blockquote id="o3bp"&gt;SQL&amp;gt; conn / as sysdba&lt;br id="texw"&gt;Connected.&lt;br id="xk_v"&gt;SQL&amp;gt; BEGIN sysman.emd_maintenance.recompile_invalid_objects; END;&lt;br id="b8l6"&gt;&lt;br id="e7cx"&gt;PL/SQL procedure successfully completed.&lt;br id="tas0"&gt;&lt;/blockquote&gt;After all, server runs ok, and I do not find any problems within applications running on this.&lt;br id="idzt"&gt;&lt;br id="y0:u"&gt;&lt;br id="q2_x"&gt;Cheers Paweł&lt;br id="hvod"&gt;&lt;br id="pyix"&gt;-- &lt;br id="rjx:"&gt;Related Articles on Paweł Barut blog:&lt;br id="gc_5"&gt;&lt;ul id="pp92"&gt;&lt;li id="k9:8"&gt;&lt;a title="CPUJan2008: One thing that every DBA should know about it." href="http://pbarut.blogspot.com/2008/02/cpujan2008-one-thing-that-every-dba.html" id="x_5a"&gt;CPUJan2008: One thing that every DBA should know about it.&lt;/a&gt; &lt;/li&gt;&lt;li id="yt9y"&gt;&lt;a title="Security: getting DBA rights quite easy" href="http://pbarut.blogspot.com/2006/12/security-getting-dba-rights-quite-easy.html" id="aqdp"&gt;Security: getting DBA rights quite easy&lt;/a&gt; &lt;/li&gt;&lt;li id="g751"&gt;&lt;a title="Comments in SQL*Plus" href="http://pbarut.blogspot.com/2007/10/comments-in-sqlplus.html" id="bpua"&gt;Comments in SQL*Plus&lt;/a&gt; &lt;/li&gt;&lt;li id="ubqg"&gt;&lt;a title="Extracting Data to Excel using only SQL*Plus" href="http://pbarut.blogspot.com/2007/07/extracting-data-to-excel-using-only.html" id="m1wz"&gt;Extracting Data to Excel using only SQL*Plus&lt;/a&gt; &lt;/li&gt;&lt;li id="r3c1"&gt;&lt;a title="RMAN TIP: Avoiding ORA-27211" href="http://pbarut.blogspot.com/2007/04/rman-tip-avoiding-ora-27211.html" id="g-yz"&gt;RMAN TIP: Avoiding ORA-27211&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1282930488238759401?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1282930488238759401/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1282930488238759401' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1282930488238759401'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1282930488238759401'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/04/oracle-cpuapr2008-for-db-10204-patch.html' title='Oracle CPUApr2008 for DB: 10.2.0.4 patch set  and first install'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1630903979952280195</id><published>2008-04-15T22:52:00.000+02:00</published><updated>2008-04-15T22:53:57.591+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle Database 11g Release 2 is coming</title><content type='html'>&lt;i id="xpff"&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i id="l4mv"&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt; &lt;br id="qt6l"&gt;      I've just received Oracle Partner Network newsletter with invitation to Oracle Database 11g Release 2 Roadshow. On this Roadshow Oracle is also going to find partners for beta testing. My guess: This year Oracle 11g R2 will be the main topic on Oracle Open World.&lt;br id="fjnc"&gt;Schedule of Roadshow in Europe:&lt;br id="sjug"&gt;&lt;ul id="fx.9"&gt;&lt;li id="mcor"&gt;May 12, 2008: UK, Reading&lt;/li&gt;&lt;li id="pyv4"&gt;May 13, 2008: Benelux, De Meern&lt;/li&gt;&lt;li id="tga1"&gt;May 14, 2008: Germany, Muenchen&lt;/li&gt;&lt;li id="bg6s"&gt;May 15, 2008: Italy, Milan&lt;/li&gt;&lt;li id="y7p:"&gt;May 16, 2008: Turkey, Istanbul&lt;/li&gt;&lt;li id="u1m9"&gt;May 19, 2008: Czech Republic, Prague&lt;/li&gt;&lt;li id="ia5q"&gt;May 20, 2008: Poland, Kraków&lt;/li&gt;&lt;li id="qlgb"&gt;May 21, 2008: Sweden, Stockholm&lt;/li&gt;&lt;li id="gg46"&gt;May 22, 2008: Spain, Madrid &lt;/li&gt;&lt;/ul&gt;If you are OPN member then you probably also get invitation.&lt;br id="ow75"&gt;I've registered. I hope to get confirmation soon. I do not expect many technical details. I rather expect marketing speech. For me most important would be to meet people that work on new DB version, and become beta tester for 11gR2.&lt;br id="y0:u"&gt;&lt;br id="q2_x"&gt;Cheers Paweł&lt;br id="hvod"&gt;&lt;br id="pyix"&gt;-- &lt;br id="rjx:"&gt;Related Articles on Paweł Barut blog:&lt;br id="gvkj"&gt;&lt;ul id="foke"&gt;&lt;li id="jb67"&gt;&lt;a title="Using Named Parameters within SQL" href="http://pbarut.blogspot.com/2007/10/using-named-parameters-within-sql.html" id="h_7-"&gt;Using Named Parameters within SQL&lt;/a&gt; &lt;/li&gt;&lt;li id="jz4i"&gt;&lt;a title="Testing new OCI8 (1.3.0 beta) for PHP with DRCP Support" href="http://pbarut.blogspot.com/2007/10/testing-new-oci8-130-beta-for-php-with.html" id="p6ql"&gt;Testing new OCI8 (1.3.0 beta) for PHP with DRCP Support&lt;/a&gt; &lt;/li&gt;&lt;li id="usvw"&gt;&lt;a title="DRCP: Database Resident Connection Pooling" href="http://pbarut.blogspot.com/2007/08/drcp-database-resident-connection.html" id="ug5y"&gt;DRCP: Database Resident Connection Pooling&lt;/a&gt; &lt;/li&gt;&lt;li id="d1ki"&gt;&lt;a title="Oracle 11g is released - my links" href="http://pbarut.blogspot.com/2007/08/oracle-11g-is-released-my-links.html" id="wm_v"&gt;Oracle 11g is released - my links&lt;/a&gt; &lt;/li&gt;&lt;li id="j9lz"&gt;&lt;a title="Solving ORA-22905: cannot access rows from a non-nested table item" href="http://pbarut.blogspot.com/2007/05/solving-ora-22905-cannot-access-rows.html" id="yv5j"&gt;Solving ORA-22905: cannot access rows from a non-nested table item&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1630903979952280195?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1630903979952280195/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1630903979952280195' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1630903979952280195'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1630903979952280195'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/04/oracle-database-11g-release-2-is-coming.html' title='Oracle Database 11g Release 2 is coming'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2367403130222391514</id><published>2008-03-24T18:34:00.001+01:00</published><updated>2008-12-10T23:58:16.089+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='dba'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Which Temporary Tablespace is used for sorts?</title><content type='html'>&lt;i&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt; &lt;br&gt;This time I will write about &lt;a href="http://pbarut.blogspot.com/2008/03/which-temporary-tablespace-is-used-for.html"&gt;"Which Temporary Tablespace is used for sorts"&lt;/a&gt; ?. I was not wondering about this much, as usually there is only one Temporary tablespace in DB. Lets assume situation, as show on picture:&lt;img style="float:right; margin:0 0 10px 10px;cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_6xECfZb_CD0/R-bCFU2sNaI/AAAAAAAAEo4/O-pSPBXaiCY/s400/user_temporary_tbs.gif" border="0" alt=""id="BLOGGER_PHOTO_ID_5181041818089567650" /&gt;&lt;ul&gt;&lt;li&gt;User A&lt;/li&gt;&lt;ul&gt;&lt;li&gt;Assigned to Temporary Tablespace TEMP_A&lt;/li&gt;&lt;li&gt;has table TA&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li&gt;User B&lt;/li&gt;&lt;ul&gt;&lt;li&gt;Assigned to Temporary Tablespace TEMP_B&lt;/li&gt;&lt;li&gt;has table TB&lt;/li&gt;&lt;li&gt;owns procedure PB (definer rights)&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;li&gt;Both users has access rights for all above object (Select on Tables and Execute on Procedure)&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;So let's discuss some situations:&lt;br&gt;&lt;ol&gt;&lt;li&gt;User A runs query on tables TA or TB (or any other) - when disk sort is needed then tablespace TEMP_A is used&lt;/li&gt;&lt;li&gt;&lt;span style="font-weight: bold;"&gt;User A&lt;/span&gt; executes procedure PB. Procedure PB opens cursor on table TB (or TA or any other). If disk sort is required then tablespace &lt;span style="font-weight: bold;"&gt;TEMP_B is used&lt;/span&gt;.&lt;br&gt;&lt;/li&gt;&lt;/ol&gt;For me it was bit surprising. Especially that I did not find anywhere in Oracle documentation description for this behaviour:&lt;br&gt;&lt;blockquote&gt;&lt;span style="font-weight: bold; font-style: italic;"&gt;TEMPORARY TABLESPACE Clause&lt;/span&gt;&lt;br style="font-style: italic;"&gt;&lt;span style="font-style: italic;"&gt;Specify the tablespace or tablespace group for the user's temporary segments.&lt;/span&gt;&lt;br&gt;&lt;/blockquote&gt;I was expecting that all sort segments will be created in tablespace that is assigned to that user. I was hopping to solve one of my issues that way. But it occurred that, &lt;span style="font-weight: bold;"&gt;sort segment is created by user B, because procedure PB uses user B rights&lt;/span&gt;. It is reasonable, as this is consistent with granting access to objects, and temporary objects are treated the same way as permanent ones. On the other hand select is run for user A - shouldn't TEMP_A be used in all cases? What is your opinion on that?&lt;br&gt;&lt;br&gt;Cheers Paweł&lt;br&gt;&lt;br&gt;-- &lt;br&gt;Related Articles on Paweł Barut blog:&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a title="How to shrink Oracle Context Index" href="http://pbarut.blogspot.com/2008/01/how-to-shrink-oracle-context-index.html" id="simo"&gt;How to shrink Oracle Context Index&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Using Named Parameters within SQL" href="http://pbarut.blogspot.com/2007/10/using-named-parameters-within-sql.html" id="i195"&gt;Using Named Parameters within SQL&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Alternative Syntax for Insert" href="http://pbarut.blogspot.com/2007/09/alternative-syntax-for-insert.html" id="p7sk"&gt;Alternative Syntax for Insert&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Extracting Data to Excel using only SQL*Plus" href="http://pbarut.blogspot.com/2007/07/extracting-data-to-excel-using-only.html" id="ktym"&gt;Extracting Data to Excel using only SQL*Plus&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Rows to single string or aggregating strings" href="http://pbarut.blogspot.com/2007/06/rows-to-single-string-or-aggregating.html" id="vnn6"&gt;Rows to single string or aggregating strings&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2367403130222391514?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2367403130222391514/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2367403130222391514' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2367403130222391514'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2367403130222391514'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/03/which-temporary-tablespace-is-used-for.html' title='Which Temporary Tablespace is used for sorts?'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_6xECfZb_CD0/R-bCFU2sNaI/AAAAAAAAEo4/O-pSPBXaiCY/s72-c/user_temporary_tbs.gif' height='72' width='72'/><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-198303977525696446</id><published>2008-03-09T19:24:00.000+01:00</published><updated>2008-03-09T19:26:21.551+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='google'/><title type='text'>Horrible practice of storing users passwords</title><content type='html'>&lt;i&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt; &lt;br&gt;I've read today &lt;a title="terrifying article" href="http://www.codinghorror.com/blog/archives/001072.html" id="ku:e"&gt;terrifying article&lt;/a&gt; about un-ethical storage of users password. It is often common practice that users passwords are stored unencrypted in database. But this case is even more dreadful. It about software, &lt;a title="G-Archiver" href="http://www.brothersoft.com/g-archiver-58027.html" id="gn49"&gt;G-Archiver&lt;/a&gt;, that is available to everyone. If you ever used this software, you should change your G-mail password right now.&lt;br&gt;So what is the problem:&lt;br&gt;&lt;ul&gt;&lt;li&gt;G-Archiver has build in user-name and password for one of g-mail accounts.&lt;/li&gt;&lt;li&gt;Whenever someone uses G-Archiver and provides his credentials for g-mail, user-name and password is send to author of this software&lt;/li&gt;&lt;li&gt;Additionally, any one who finds out the user-name and password stored in G-Archiver, can get passwords of thousand of previous users.&lt;/li&gt;&lt;/ul&gt;&lt;a title="Go and read" href="http://www.codinghorror.com/blog/archives/001072.html" id="lcgk"&gt;Go and read&lt;/a&gt;. Hope there are not too many of software that works like this one. It is really terrifying, that some people are so irresponsible. It could be well planed action to collect gmail users and passwords, or it could be just lack of imagination what are the consequences. I would like to believe that it was the second one.&lt;br&gt;&lt;br&gt;But also big corporations do not care for security enough. It is common practice, that users password is stored internally as plain text. It can be easily found out by using "I forgot my password" feature. If in return you will get email with your original password, then it is a crappy web side. And you should never reuse password passed to such web side as this is big risk for you. Take a look at &lt;a title="Password Security: It’s Not That Hard (But You Still Can’t Get It Right)" href="http://ronrothman.com/public/leftbraned/password-security-its-not-that-hard-but-you-still-cant-get-it-right" id="yzjv"&gt;Password Security: It’s Not That Hard (But You Still Can’t Get It Right)&lt;/a&gt; for further explanation and examples.&lt;br&gt;&lt;br&gt;Cheers Paweł&lt;br&gt;&lt;br&gt;-- &lt;br&gt;Related Articles on Paweł Barut blog:&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a title="Security: getting DBA rights quite easy" href="http://pbarut.blogspot.com/2006/12/security-getting-dba-rights-quite-easy.html" id="vs9g"&gt;Security: getting DBA rights quite easy&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="„Do not use Linux, please, pirate our software” - Microsoft" href="http://pbarut.blogspot.com/2007/03/do-not-use-linux-please-pirate-our.html" id="u0ro"&gt;„Do not use Linux, please, pirate our software” - Microsoft&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Spam, Spam filters, Being Spammer, Being Filtered-out ..." href="http://pbarut.blogspot.com/2008/02/spam-spam-filters-being-spammer-being.html" id="kq8l"&gt;Spam, Spam filters, Being Spammer, Being Filtered-out ...&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Do not trust Google Maps" href="http://pbarut.blogspot.com/2007/12/do-not-trust-google-maps.html" id="d-kc"&gt;Do not trust Google Maps&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-198303977525696446?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/198303977525696446/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=198303977525696446' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/198303977525696446'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/198303977525696446'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/03/horrible-practice-of-storing-users.html' title='Horrible practice of storing users passwords'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4395932442283867913</id><published>2008-02-18T23:17:00.000+01:00</published><updated>2008-02-18T23:18:44.164+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='links'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Useful links on Oracle XML DB</title><content type='html'>&lt;i&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt; &lt;br&gt;Here is bunch of useful links related to Oracle XML DB and handling XML data in Oracle PL/SQL. It's mostly for my own reference, but I hope it will be useful for others too.&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a title="How do i store the counts of all tables" href="http://laurentschneider.com/wordpress/2007/04/how-do-i-store-the-counts-of-all-tables.html" id="shge"&gt;How do i store the counts of all tables&lt;/a&gt; by Laurent Schneider&lt;/li&gt;&lt;li&gt;&lt;a title="Converting Between XML and Oracle Objects" href="http://blogs.ittoolbox.com/oracle/guide/archives/minitip-13-converting-between-xml-and-oracle-objects-19085" id="omzr"&gt;Converting Between XML and Oracle Objects&lt;/a&gt; by Lewis Cunningham&lt;br&gt;&lt;/li&gt;&lt;li&gt;&lt;a title="Problems Calling .Net Web Services from UTL_DBWS" href="http://beautifulwaste.blogspot.com/2007/04/problems-calling-net-web-services-from.html" id="nzmb"&gt;Problems Calling .Net Web Services from UTL_DBWS&lt;/a&gt; by Stellan&lt;/li&gt;&lt;li&gt;&lt;a title="First Tests of 11g Native Web Services" href="http://tardate.blogspot.com/2007/08/first-tests-of-11g-native-web-services.html" id="f3rn"&gt;First Tests of 11g Native Web Services&lt;/a&gt; and &lt;a title="Revisiting 11g Native Web Services" href="http://tardate.blogspot.com/2007/08/revisiting-11g-native-web-services.html" id="g9pn"&gt;Revisiting 11g Native Web Services&lt;/a&gt; by Paul Gallagher&lt;/li&gt;&lt;li&gt;&lt;a title="Oracle 11g Security - XMLDB is here to stay…" href="http://www.liberidu.com/blog/?p=250" id="v9g0"&gt;Oracle 11g Security - XMLDB is here to stay…&lt;/a&gt; by Marco Gralike&lt;/li&gt;&lt;li&gt;&lt;a title="HOWTO: Create XMLType Table for Binary XML Usage" href="http://www.liberidu.com/blog/?p=250" id="oms."&gt;HOWTO: Create XMLType Table for Binary XML Usage&lt;/a&gt; by Marco Gralike&lt;/li&gt;&lt;li&gt;&lt;a title="HOWTO: Saving XML data directly to disk" href="http://www.liberidu.com/blog/?p=365" id="nbdh"&gt;HOWTO: Saving XML data directly to disk&lt;/a&gt; by Marco Gralike&lt;/li&gt;&lt;li&gt;&lt;a title="select from a comma-separated string" href="http://laurentschneider.com/wordpress/2007/05/select-from-a-comma-separated-string.html" id="p9_2"&gt;select from a comma-separated string&lt;/a&gt; by Laurent Schneider. BTW. Note that I've demonstrated &lt;a title="this technique" href="http://pbarut.blogspot.com/2006/10/binding-list-variable.html" id="wzva"&gt;this technique&lt;/a&gt; 7 month earlier :)&lt;/li&gt;&lt;/ul&gt;&lt;br&gt;Cheers Paweł&lt;br&gt;&lt;br&gt;-- &lt;br&gt;Related Articles on Paweł Barut blog:&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a title="Solving ORA-22905: cannot access rows from a non-nested table item" href="http://pbarut.blogspot.com/2007/05/solving-ora-22905-cannot-access-rows.html" id="axux"&gt;Solving ORA-22905: cannot access rows from a non-nested table item&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Binding list variable" href="http://pbarut.blogspot.com/2006/10/binding-list-variable.html" id="pfgt"&gt;Binding list variable&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Oracle XMLType: exctractvalue vs. extract" href="http://pbarut.blogspot.com/2007/01/oracle-xmltype-exctractvalue-vs-extract.html" id="rfp_"&gt;Oracle XMLType: exctractvalue vs. extract&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="ORA-30625 and XMLType" href="http://pbarut.blogspot.com/2006/11/ora-30625-and-xmltype.html" id="j2tg"&gt;ORA-30625 and XMLType&lt;/a&gt; &lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4395932442283867913?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4395932442283867913/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4395932442283867913' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4395932442283867913'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4395932442283867913'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/02/useful-links-on-oracle-xml-db.html' title='Useful links on Oracle XML DB'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1702760848666490915</id><published>2008-02-11T22:54:00.000+01:00</published><updated>2008-02-11T22:55:58.233+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='patch'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>CPUJan2008: One thing that every DBA should know about it.</title><content type='html'>&lt;i&gt;Written by &lt;/i&gt;&lt;a title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;&lt;i&gt;Paweł Barut&lt;/i&gt;&lt;/a&gt; &lt;br&gt;While reading documentation for latest Oracle security patch CPUJan2008 for database I've noticed one new required step. This step is: Recompile Views. One whould say that it's nothing strange, but to run this script database have to be started in UPGRADE MODE. For non-RAC installations it's not big issue, as anyway you have to plan downtime. But Oracle suggest that this recompilation can take 30 minutes:&lt;br&gt;&lt;blockquote&gt;"In one internal Oracle 
test with approximately 2000 views and 4000 objects, the total execution time 
for &lt;code&gt;view_recompile_jan2008cpu.sql&lt;/code&gt; and &lt;code&gt;utlrp.sql&lt;/code&gt; was 
about 30 minutes."&lt;br&gt;&lt;/blockquote&gt;Practically in my case it took no more than 5 minutes, so it's not big deal.&lt;br&gt;But it could be problem for RAC installations, that used when CPU is applied on one node, then &lt;span style="font-family: Courier New;"&gt;catcpu.sql&lt;/span&gt; is run, then second node is being patched. So normally DB will be all the time available. But if it's needed to start database in UPGRADE mode it means that downtime is required. According to documentation it's not required to run view recompilation script during paching process. This script can be run after,&lt;br&gt;&lt;blockquote&gt;"however, the CPU installation will not be complete until the view 
recompilation is completed."&lt;br&gt;&lt;/blockquote&gt;You can ommit this step only if:&lt;ul&gt;&lt;li&gt;
&lt;p&gt;Databases was created with Release 11.1.0.6 or later&lt;/p&gt;
&lt;/li&gt;&lt;li&gt;
&lt;p&gt;Databases was created with any release (for example,&amp;nbsp;&lt;a href="http://10.2.0.3/"&gt;&lt;/a&gt;10.2.0.3, 10.1.0.5, or 9.2.0.8) &lt;span&gt;after&lt;/span&gt; CPUJan2008 or a later CPU has been 
applied&lt;/p&gt;&lt;/li&gt;&lt;/ul&gt;&lt;p&gt;I hope it also means that after CPUJan2008 was applied you will not have to run this script after next CPU came out (CPUApr2008, etc).&lt;br&gt;&lt;/p&gt;&lt;br&gt;Cheers Paweł&lt;br&gt;&lt;br&gt;-- &lt;br&gt;Related Articles on Paweł Barut blog:&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a title="Security: getting DBA rights quite easy" href="http://pbarut.blogspot.com/2006/12/security-getting-dba-rights-quite-easy.html" id="ei6s"&gt;Security: getting DBA rights quite easy&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="CPUApr2007 and Interim patch 3 for 10.2.0.3 on Windows" href="http://pbarut.blogspot.com/2007/04/cpuapr2007-and-interim-patch-3-for.html" id="mz4b"&gt;CPUApr2007 and Interim patch 3 for 10.2.0.3 on Windows&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Applying Oracle 10.2.0.3 patch" href="http://pbarut.blogspot.com/2006/12/applying-oracle-10203-patch.html" id="chou"&gt;Applying Oracle 10.2.0.3 patch&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Autobackup of SPFILE and CONTROLFILE" href="http://pbarut.blogspot.com/2007/01/autobackup-of-spfile-and-controlfile.html" id="gz6l"&gt;Autobackup of SPFILE and CONTROLFILE&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="Blogger Beta Backup tool" href="http://pbarut.blogspot.com/2006/11/blogger-beta-backup-tool.html" id="uq4m"&gt;Blogger Beta Backup tool&lt;/a&gt; &lt;/li&gt;&lt;/ul&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1702760848666490915?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1702760848666490915/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1702760848666490915' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1702760848666490915'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1702760848666490915'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/02/cpujan2008-one-thing-that-every-dba.html' title='CPUJan2008: One thing that every DBA should know about it.'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1763035594287465323</id><published>2008-02-03T18:46:00.001+01:00</published><updated>2008-02-03T18:47:56.868+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='spam'/><category scheme='http://www.blogger.com/atom/ns#' term='mail'/><title type='text'>Spam, Spam filters, Being Spammer, Being Filtered-out ...</title><content type='html'>&lt;span style="font-style: italic;"&gt;Written by &lt;/span&gt;&lt;a style="font-style: italic;" title="Paweł Barut" href="http://pbarut.blogspot.com/" id="f.1t"&gt;Paweł Barut&lt;/a&gt;&lt;span style="font-style: italic;"&gt; &lt;/span&gt;&lt;br&gt;      My thoughts about Spam. Some time agou I wrote about &lt;a title="spam in comments" href="http://pbarut.blogspot.com/2007/10/ive-got-spammed-in-comments.html" id="c8ma"&gt;spam in comments&lt;/a&gt; on my blog, but this time it will be about email spam. This is something that from time to time irritates me a lot. Spam is something that nobody wants to see in his mails. And to solve this problem there are many spam filters, IP Block lists and other solutions. But none of them is 100% accurate. And this is what causes problems. Spam filers should be solving problems, but many times creates new ones.&lt;br&gt;In ideal situation spam filter eliminates 100% of spam, and passes 100% of emails that are expected by users. But it's not true. I will now show example situations, that lead me to conclusion, that spam filter are useless.&lt;br&gt;&lt;b&gt;Situation 1.&lt;/b&gt;&lt;br&gt;Spam filter did not recognized spam mail, and I have to manually figure out that this is spam. So I need to one more click to delete message.&lt;br&gt;&lt;b&gt;Situation 2.&lt;/b&gt;&lt;br&gt;Spam filter deletes mail that was intended for me. This was false alarm as it wasn't spam.&lt;br&gt;&lt;b&gt;Situation 3.&lt;/b&gt;&lt;br&gt;I've send email to customer/friend. His spam filter blocked it. I did not received any delivery failure message.&lt;br&gt;&lt;br&gt;In my opinion situation 2 and 3 are very dangerous and I would like to avoid any of those situations. In my opinion those situations makes spam filters useless. It is especially dangerous if this block is done by service provider, and when you cannot see list of spam being filtered out. This is what really annoys my and makes me angry. In fact it makes whole email system unreliable (I do not want to say useless), as you never know if you recipient get your email or not.&lt;br&gt;&lt;br&gt;I do not know what is solution for this. I can see few options, but none of them is perfect:&lt;br&gt;&lt;ol&gt;&lt;li&gt;Each and every email should be signed digitally by sender, and additionally by his service provider. Spam filers should be able to verify this and honor such signing, and not consider this to be spam. Of course spammers could find way to sign theirs mail too, and vanish this approach.&lt;br&gt;&lt;/li&gt;&lt;li&gt;Everybody should use "return receipt" to confirm mail delivery. Well, quite simple, but personally I never allow my mailer to send confirmations, as I do not want to reveal when I've read mail.&lt;br&gt;&lt;/li&gt;&lt;li&gt;Make mail system payable. So for every mail you send you have to pay small amount of money. $0.01 per email should not be problem for real email users, but could cost fortune for spammers. For this money service providers should ensure that your mail will reach recipient.&lt;/li&gt;&lt;li&gt;Use &lt;a title="captcha" href="http://en.wikipedia.org/wiki/Captcha" id="j:mu"&gt;captcha&lt;/a&gt;  to validate that email is send by real user. I could work as this: when spam filter suspects spam, it sends back email to sender with link to web page on which user will have to provide answer to captcha to make his mail pass throu spam filter.&lt;br&gt;&lt;/li&gt;&lt;/ol&gt;&lt;br&gt;At the end I would like to ask you: &lt;span style="font-weight: bold;"&gt;How do you deal with spam?&lt;/span&gt;&lt;br&gt;&lt;br&gt;Cheers Paweł&lt;br&gt;&lt;br&gt;-- &lt;br&gt;Related Articles on Paweł Barut blog:&lt;br&gt;&lt;ul&gt;&lt;li&gt;&lt;a title="I've got spammed (in comments)" href="http://pbarut.blogspot.com/2007/10/ive-got-spammed-in-comments.html" id="zgre"&gt;I've got spammed (in comments)&lt;/a&gt;&lt;br&gt;&lt;/li&gt;&lt;li&gt;&lt;a title="&amp;quot;Do not use Linux, please, pirate our software&amp;quot; - Microsoft" href="http://pbarut.blogspot.com/2007/03/do-not-use-linux-please-pirate-our.html" id="sqv5"&gt;"Do not use Linux, please, pirate our software" - Microsoft&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="13 – Happy or Unhappy Number?" href="http://pbarut.blogspot.com/2006/09/13-happy-or-unhappy-number.html" id="e6-h"&gt;13 – Happy or Unhappy Number?&lt;/a&gt; &lt;/li&gt;&lt;li&gt;&lt;a title="I've been tagged 3 times; 8 things about me" href="http://pbarut.blogspot.com/2008/01/ive-been-tagged-3-times-8-things-about.html" id="f1k0"&gt;I've been tagged 3 times; 8 things about me&lt;/a&gt; &lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1763035594287465323?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1763035594287465323/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1763035594287465323' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1763035594287465323'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1763035594287465323'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/02/spam-spam-filters-being-spammer-being.html' title='Spam, Spam filters, Being Spammer, Being Filtered-out ...'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5703160804722156253</id><published>2008-01-23T21:50:00.000+01:00</published><updated>2008-01-23T21:52:06.623+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ctx'/><category scheme='http://www.blogger.com/atom/ns#' term='dba'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>How to shrink Oracle Context Index</title><content type='html'>On of databases I've found that one of Context Indexes is getting bigger and bigger everyday. It was around 5-10% grow per day for table DR$MY_TEXT_I$I which contains tokens(word). No of records indexed was almost the same, but index grown was unexpectedly big. It was due fact, that quite many rows were modified every day, and it caused re-indexing those rows during index synchronization (CTX_DDL.SYNC_INDEX). So I've decided to reclaim this space.&lt;br&gt;&lt;h3&gt;Method 1.&lt;/h3&gt;This was my first though:&lt;br&gt;&lt;ul&gt;&lt;li&gt;Drop Index ... /Create Index ...&lt;/li&gt;&lt;li&gt;or Alter Index ... Rebuild&lt;/li&gt;&lt;/ul&gt;But those methods have some disadvantages:&lt;br&gt;&lt;ul&gt;&lt;li&gt;Users cannot perform text searches during this operation,&lt;/li&gt;&lt;li&gt;It does not solve problem for longer time, as index will still grow ...&lt;/li&gt;&lt;/ul&gt;So I had to find root cause and eliminate it.&lt;br&gt;&lt;h3&gt;Method 2.&lt;/h3&gt;While looking for root cause I've find out, that Index has never been optimized, so it kept old (obsolete) data. My solution was:&lt;br&gt;SQL&amp;gt; exec ctx_ddl.optimize_index('MY_TEXT_I', 'FULL', 120);&lt;br&gt;SQL&amp;gt; alter table DR$MY_TEXT_I$I enable row movement;&lt;br&gt;SQL&amp;gt; alter table DR$MY_TEXT_I$I shrink space cascade;&lt;br&gt;      &lt;br&gt;With this method table DR$MY_TEXT_I$I took 30% of its original size.&lt;br&gt;So let me explain why this worked. With ctx_ddl.optimize_index context index was internally optimized. It means information about old documents were completely deleted and index was internally minimized. Remember - third parameter limits time (in minutes) allowed for optimization. If it is really big index it can take hours. But you can run this optimization many times, until your index will be fully optimized.&lt;br&gt;Then I've just shrunk table (&lt;span style="font-style: italic;"&gt;shrink space cascade&lt;/span&gt;). But this operation requires to enable row movement on table first.&lt;br&gt;
&lt;br&gt;But this was one time operation. To avoid this problem in future I've scheduled job to run ctx_ddl.optimize_index on regular basis. Now this table has grown a little, but is no longer growing so fast.&lt;br&gt;&lt;br&gt;Foot note:&lt;br&gt;&lt;ul&gt;&lt;li&gt;It was tested on Oracle EE 10gR2 (10.2.0.3),&lt;/li&gt;&lt;li&gt;I'm not sure if row movement is supported by Oracle for Context Index table DR$&amp;lt;index&amp;gt;$I. It worked for me and I did not experience any problems since turning it on.&lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5703160804722156253?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5703160804722156253/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5703160804722156253' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5703160804722156253'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5703160804722156253'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/01/how-to-shrink-oracle-context-index.html' title='How to shrink Oracle Context Index'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6879040138118224686</id><published>2008-01-12T17:17:00.000+01:00</published><updated>2008-01-12T17:22:09.598+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='about'/><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><title type='text'>I've been tagged 3 times; 8 things about me</title><content type='html'>Few busy days without any blog reading and after I've gone through my feeds it occurred that I've been tagged 3 times:&lt;br&gt;&lt;ol&gt;&lt;li&gt;By &lt;a title="Eddie Awad" href="http://awads.net/wp/2008/01/09/8-things-you-may-not-know-about-this-blogger/" id="u62u"&gt;Eddie Awad&lt;/a&gt; &lt;/li&gt;&lt;li&gt;By &lt;a title="H.Tonguç YILMAZ" href="http://tonguc.wordpress.com/2008/01/10/i-am-tagged-also-so-here-are-8-things-about-me/" id="vr7z"&gt;H.Tonguç YILMAZ&lt;/a&gt; &lt;br&gt; &lt;/li&gt;&lt;li&gt;By &lt;a title="Jorrit Nijssen" href="http://jornica.blogspot.com/2008/01/tagged.html" id="uhcg"&gt;Jorrit Nijssen (Jornica)&lt;/a&gt; &lt;br&gt;&lt;/li&gt;&lt;/ol&gt;Thanks You for tagging.&lt;br&gt;Now I feel that I really need to write something about me:&lt;br&gt;&lt;ol&gt;&lt;li&gt;I was born and grow up in &lt;a title="Krosno" href="http://www.krosno.pl/" id="a5u_"&gt;Krosno&lt;/a&gt; in south-east Poland (see &lt;a title="satelite picture" href="http://maps.google.com/maps?t=h&amp;amp;hl=en&amp;amp;ie=UTF8&amp;amp;ll=49.692879,21.756191&amp;amp;spn=0.136807,0.32135&amp;amp;z=12&amp;amp;om=1" id="w91g"&gt;satellite picture&lt;/a&gt;),&lt;/li&gt;&lt;li&gt;I 15th when &lt;a title="Communism fall down" href="http://en.wikipedia.org/wiki/Fall_of_communism" id="d1bq"&gt;Communism fall down&lt;/a&gt; in Poland. At this moment Poland is member of &lt;a title="Schengen Agreement" href="http://en.wikipedia.org/wiki/Schengen_Agreement" id="qe31"&gt;Schengen Agreement&lt;/a&gt;, and I can travel around Europe without passport. Lot of changes in last 19 years,&lt;/li&gt;&lt;li&gt;I'm &lt;a title="Thawte" href="https://www.thawte.com/" id="t:9h"&gt;Thawte&lt;/a&gt; &lt;a title="Web of Trust" href="https://www.thawte.com/secure-email/web-of-trust-wot/index.html?click=main-nav-products-wot" id="ilc."&gt;Web of Trust&lt;/a&gt; &lt;a title="Notary" href="http://barut.info/thawte.php" id="fmkd"&gt;Notary&lt;/a&gt;,&lt;br&gt;&lt;/li&gt;&lt;li&gt;In 1993 I took 2nd place in Nation Contest in Programming for College Students. Unfortunately I was 6 month too old to take part in international final :(&lt;/li&gt;&lt;li&gt;In 1990 I've sold my first program; small DB written in Clipper. I did not think that this program will be used for so many years. In 1999 I had to do some changes to support year 2000,&lt;/li&gt;&lt;li&gt;My first program was written in Basic and was run on &lt;a title="PSP-80" href="http://pl.wikipedia.org/wiki/PSP-80" id="wjur"&gt;PSP-80&lt;/a&gt; (page in Polish)&lt;br&gt;&lt;/li&gt;&lt;li&gt;I'm married and we have 2 daughters (6 and 2 years old),&lt;/li&gt;&lt;li&gt;My favourite TV show is &lt;a title="Top Gear" href="http://www.bbc.co.uk/topgear/" id="surp"&gt;Top Gear&lt;/a&gt; with &lt;a title="Jeremy Clarkson" href="http://en.wikipedia.org/wiki/Jeremy_Clarkson" id="o-_m"&gt;Jeremy Clarkson&lt;/a&gt; , &lt;a title="Richard Hammond" href="http://en.wikipedia.org/wiki/Richard_Hammond" id="cd8n"&gt;Richard Hammond&lt;/a&gt; and &lt;a title="James May" href="http://en.wikipedia.org/wiki/James_May" id="y0je"&gt;James May&lt;/a&gt;.&lt;br&gt;&lt;/li&gt;&lt;/ol&gt;I will not invite anyone directly as I do not want to &lt;a title="accused of spam" href="http://awads.net/wp/2008/01/10/i-am-a-spammer-and-so-are-you-if-you-played-the-tag-game/" id="m250"&gt;accused of spam&lt;/a&gt;. All my readers that have blogs are welcome to post 8 things about themselves.&lt;br&gt;&lt;br&gt;Cheers,&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6879040138118224686?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6879040138118224686/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6879040138118224686' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6879040138118224686'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6879040138118224686'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2008/01/ive-been-tagged-3-times-8-things-about.html' title='I&apos;ve been tagged 3 times; 8 things about me'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-7423064762461152140</id><published>2007-12-05T18:23:00.000+01:00</published><updated>2008-12-10T23:58:16.271+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='maps'/><category scheme='http://www.blogger.com/atom/ns#' term='google'/><title type='text'>Do not trust Google Maps</title><content type='html'>Ok, Might be title is too strong, but you should not trust Google Maps when searching for streets in Krosno, Poland (city where I was born). Here is sample, try to search for "Lwowska, 38-400 Krosno, Poland" and you get:
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_6xECfZb_CD0/R1bqcD8V7mI/AAAAAAAADyU/afzQbzfH02w/s1600-h/google_maps.jpg"&gt;&lt;img style="cursor: pointer;" src="http://2.bp.blogspot.com/_6xECfZb_CD0/R1bqcD8V7mI/AAAAAAAADyU/afzQbzfH02w/s400/google_maps.jpg" alt="" id="BLOGGER_PHOTO_ID_5140553792505638498" border="0" /&gt;&lt;/a&gt;&lt;br/&gt;Search is working correctly, but names on street do not match reality. Instead of "Lwowska" street is "Jana Lenarta". Another example is "Platynowa" instead of "Podkarpacka". It seems that all street names are messed up on map.
Hope they fix it soon.
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-7423064762461152140?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/7423064762461152140/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=7423064762461152140' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7423064762461152140'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7423064762461152140'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/12/do-not-trust-google-maps.html' title='Do not trust Google Maps'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_6xECfZb_CD0/R1bqcD8V7mI/AAAAAAAADyU/afzQbzfH02w/s72-c/google_maps.jpg' height='72' width='72'/><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1276973733572315342</id><published>2007-12-02T11:48:00.000+01:00</published><updated>2007-12-02T11:49:59.289+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='fun'/><title type='text'>Rant: Great fun with Wii</title><content type='html'>I'm not a computer game player, but Nintendo Wii really impressed me. I was with a visit to my friend and he showed me his new gadget. We started to play for a while, and time passed by. It's really addictive. The best thing is that you do not seat at computer and use joystick or keyboard, but you stand up and move whole body to play. It really gives pleasure, and we have good time. If you do not know Wii yet check this &lt;a title="Wii commercial" href="http://wii.nintendo.com/wiicommercials_full.jsp" id="kjfz"&gt;Wii commercial&lt;/a&gt;.&lt;br&gt;&lt;br&gt;Have fun&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1276973733572315342?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1276973733572315342/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1276973733572315342' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1276973733572315342'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1276973733572315342'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/12/rant-great-fun-with-wii.html' title='Rant: Great fun with Wii'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4265245935042528069</id><published>2007-11-21T22:20:00.000+01:00</published><updated>2007-11-21T22:22:56.152+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='drcp'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>More on PHP with DRCP support</title><content type='html'>I was asked to compare DRCP to SHARED server connections. I've also promised to &lt;a title="give some more statistics" href="http://pbarut.blogspot.com/2007/10/testing-new-oci8-130-beta-for-php-with.html" id="v385"&gt;give some more statistics&lt;/a&gt; and comparisons for DRCP and standard connectivity. &lt;br&gt;&lt;/span&gt;First few results to compare to SHARED server as asked in comments to my previous post:

&lt;table border="1" bordercolor="#000000" cellpadding="4" cellspacing="0" width="100%"&gt;
 &lt;thead&gt;
  &lt;tr valign="top"&gt;
    &lt;th&gt;
      
        &lt;span lang="en-US"&gt;Version&lt;/span&gt;
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Description
      
    &lt;/th&gt;
    &lt;th&gt;
      
        # Requests
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Average
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Median
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Standard Deviation
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Throughput
      
    &lt;/th&gt;
    &lt;th&gt;
      
        &lt;br&gt;
      
    &lt;/th&gt;
  &lt;/tr&gt;
  &lt;/thead&gt; &lt;tbody&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        1
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_connect DEDICATED server
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        Not tested
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        2
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect DEDICATED server
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        84
      
    &lt;/td&gt;
    &lt;td&gt;
      
        63
      
    &lt;/td&gt;
    &lt;td&gt;
      
        116
      
    &lt;/td&gt;
    &lt;td&gt;
      
        4077
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        3 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        oci_connect SHARED server
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200&lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        280&lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        264&lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        150&lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1290&lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        
      
    &lt;br&gt;&lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        4 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect SHARED server
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        82
      
    &lt;/td&gt;
    &lt;td&gt;
      
        78 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        93 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        3965 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        5 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        oci_connect with DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        104
      
    &lt;/td&gt;
    &lt;td&gt;
      
        94
      
    &lt;/td&gt;
    &lt;td&gt;
      
        45
      
    &lt;/td&gt;
    &lt;td&gt;
      
        3265
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        6 &lt;br&gt;&lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect with DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        78
      
    &lt;/td&gt;
    &lt;td&gt;
      
        78
      
    &lt;/td&gt;
    &lt;td&gt;
      
        23
      
    &lt;/td&gt;
    &lt;td&gt;
      
        4396
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

  In this case SHARED server is configured to use 4 dispatchers and max process = 1000.&lt;br&gt;&lt;span lang="en-US"&gt;&lt;br&gt; &lt;/span&gt;
&lt;br&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4265245935042528069?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4265245935042528069/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4265245935042528069' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4265245935042528069'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4265245935042528069'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/11/more-on-php-with-drcp-support.html' title='More on PHP with DRCP support'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2925275130884860286</id><published>2007-10-27T18:53:00.000+02:00</published><updated>2008-12-10T23:58:16.394+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='drcp'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Testing new OCI8 (1.3.0 beta) for PHP with DRCP Support</title><content type='html'>I've seen Christopher Jones announcement on availability of
  &lt;a href="http://blogs.oracle.com/opal/2007/10/09#a224" id="v42_" title="beta OCI8 extension for PHP with support for DRCP"&gt;beta
  OCI8 extension for PHP with support for DRCP&lt;/a&gt;. I've decided to give it a
  try. On my test machine running OEL5 I've installed latest PHP 5.4.2 and then
  replaced OCI8 sources with &lt;span lang="en-US"&gt;new
  &lt;/span&gt;&lt;a href="http://pecl.php.net/package/oci8%20" id="f4a9" title="OCI8 1.3.0 beta release"&gt;OCI8
  1.3.0 beta release&lt;/a&gt;&lt;span lang="en-US"&gt;.&lt;/span&gt;


  I've configured PHP:
&lt;br&gt;
&lt;span style="font-style: italic;"&gt;
  ./configure --with-oci8=$ORACLE_HOME --with-apxs2=/usr/sbin/apxs
  --with-config-file-path=/etc/httpd/conf --enable-sigchild --without-sqlite
  --without-mysql&lt;/span&gt;
&lt;br&gt;
  compiled it and installed. Everything went fine, and on sample page I've
  displayed phpinfo():
  &lt;br&gt;
  &lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://2.bp.blogspot.com/_6xECfZb_CD0/RyNtxx_dcnI/AAAAAAAADtk/ntfPvcz-334/s1600-h/oci8_1.gif"&gt;&lt;img style="cursor:pointer; cursor:hand;" src="http://2.bp.blogspot.com/_6xECfZb_CD0/RyNtxx_dcnI/AAAAAAAADtk/ntfPvcz-334/s400/oci8_1.gif" border="0" alt=""id="BLOGGER_PHOTO_ID_5126061502878282354" /&gt;&lt;/a&gt;
  &lt;br&gt;
  I've changed php.ini to enable Database Resident Connection Pooling:
  &lt;pre&gt;oci8.connection_class="TESTPOOL"&lt;/pre&gt;
  and tested that it is used in PHP.&lt;br&gt;
  Then I've decided to test and compare performance of different methods of connection to Oracle from PHP. I've created simple PHP
  page, that connects to Oracle, execute simple query that returns one row, and
  inserts one row to another table. I've prepared test script for Apache JMeter
  against this page.&lt;br&gt;Test specification:

&lt;ul&gt;
  &lt;li&gt;Run on single processor machine
    
  &lt;/li&gt;
  &lt;li&gt;
    
      Oracle and Apache+PHP run in VMware
    
  &lt;/li&gt;
  &lt;li&gt;
    
      DRCP setup to have max 4 processes (3 processes effectively used,
      4&lt;sup&gt;th&lt;/sup&gt; for authentication only)
    
  &lt;/li&gt;
  &lt;li&gt;
    
      6 simultaneous users opening the same web page 200 times
    
  &lt;/li&gt;
  &lt;li&gt;
    
      4 versions of PHP script were used: &lt;br&gt;&lt;/li&gt;&lt;/ul&gt;&lt;ol&gt;&lt;ol&gt;&lt;li&gt;oci_connect used to connect to Oracle without using DRCP (Database
      Resident Connection Pooling)– in this case new connection is created for
      every request from web browser. Connection is then closed at the end of
      script &lt;br&gt;&lt;/li&gt;&lt;li&gt;oci_pconnect used to connect to Oracle without using DRCP – in this
      case new connection is created for every apache process that is responding
      to request from web browser. Connection is then closed at the end of
      script &lt;br&gt;&lt;/li&gt;&lt;li&gt;oci_connect used to connect to Oracle with using DRCP (Database
      Resident Connection Pooling)– in this case for every request connection is
      obtained from pool and given back to pool at the end of script, seems that
      in this case only process is reused (PURITY=NEW), while session is not (see my &lt;a title="observations when using SQL*Plus" href="http://pbarut.blogspot.com/2007/09/oracle-11g-drcp-functionality-test.html" id="uwou"&gt;observations when using SQL*Plus&lt;/a&gt; ) &lt;br&gt;&lt;/li&gt;&lt;li&gt;oci_pconnect used to connect to Oracle with using DRCP (Database
      Resident Connection Pooling)– in this case for every request connection is
      obtained from pool and given back to pool at the end of script. But in
      this case full potential of DRCP is used (PURITY=SELF)
    
  &lt;/li&gt;&lt;/ol&gt;&lt;/ol&gt;&lt;ul&gt;
&lt;/ul&gt;

  Here are the results:

&lt;table border="1" bordercolor="#000000" cellpadding="4" cellspacing="0" width="100%"&gt;
  &lt;thead&gt;
  &lt;tr valign="top"&gt;
    &lt;th&gt;
      
        &lt;span lang="en-US"&gt;Version&lt;/span&gt;
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Description
      
    &lt;/th&gt;
    &lt;th&gt;
      
        # Requests
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Average
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Median
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Standard Deviation
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Throughput
      
    &lt;/th&gt;
    &lt;th&gt;
      
        &lt;br&gt;
      
    &lt;/th&gt;
  &lt;/tr&gt;
  &lt;/thead&gt; &lt;tbody&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        1
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_connect without DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        989
      
    &lt;/td&gt;
    &lt;td&gt;
      
        875
      
    &lt;/td&gt;
    &lt;td&gt;
      
        828
      
    &lt;/td&gt;
    &lt;td&gt;
      
        359
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        2
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect without DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        123
      
    &lt;/td&gt;
    &lt;td&gt;
      
        94
      
    &lt;/td&gt;
    &lt;td&gt;
      
        187
      
    &lt;/td&gt;
    &lt;td&gt;
      
        2505
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        3
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_connect with DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        117
      
    &lt;/td&gt;
    &lt;td&gt;
      
        94
      
    &lt;/td&gt;
    &lt;td&gt;
      
        115
      
    &lt;/td&gt;
    &lt;td&gt;
      
        2907
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        4
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect with DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        82
      
    &lt;/td&gt;
    &lt;td&gt;
      
        78
      
    &lt;/td&gt;
    &lt;td&gt;
      
        30
      
    &lt;/td&gt;
    &lt;td&gt;
      
        4060
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

  &lt;br&gt;


  I must say that I'm positively impressed by performance achieved by version 3
  where oci_pconnect with DRCP was used. I expected that performance for version
  2,3,4 will be very similar. But I've observed 60% increase in Throughput and
  33% shorter response times when comparing version 2 and 4 (oci_pconnect with
  and without DRCP).


  I've changed one setting for my test in JMeter: I've turned on Keep-Alive for
  http transfer and here are the results:

&lt;table border="1" bordercolor="#000000" cellpadding="4" cellspacing="0" width="100%"&gt;
 &lt;thead&gt;
  &lt;tr valign="top"&gt;
    &lt;th&gt;
      
        &lt;span lang="en-US"&gt;Version&lt;/span&gt;
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Description
      
    &lt;/th&gt;
    &lt;th&gt;
      
        # Requests
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Average
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Median
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Standard Deviation
      
    &lt;/th&gt;
    &lt;th&gt;
      
        Throughput
      
    &lt;/th&gt;
    &lt;th&gt;
      
        &lt;br&gt;
      
    &lt;/th&gt;
  &lt;/tr&gt;
  &lt;/thead&gt; &lt;tbody&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        1
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_connect without DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
    &lt;td&gt;
      
        Not tested
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        2
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect without DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        84
      
    &lt;/td&gt;
    &lt;td&gt;
      
        63
      
    &lt;/td&gt;
    &lt;td&gt;
      
        116
      
    &lt;/td&gt;
    &lt;td&gt;
      
        4077
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        3
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_connect with DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        104
      
    &lt;/td&gt;
    &lt;td&gt;
      
        94
      
    &lt;/td&gt;
    &lt;td&gt;
      
        45
      
    &lt;/td&gt;
    &lt;td&gt;
      
        3265
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr valign="top"&gt;
    &lt;td&gt;
      
        4
      
    &lt;/td&gt;
    &lt;td&gt;
      
        oci_pconnect with DRCP
      
    &lt;/td&gt;
    &lt;td&gt;
      
        1200
      
    &lt;/td&gt;
    &lt;td&gt;
      
        78
      
    &lt;/td&gt;
    &lt;td&gt;
      
        78
      
    &lt;/td&gt;
    &lt;td&gt;
      
        23
      
    &lt;/td&gt;
    &lt;td&gt;
      
        4396
      
    &lt;/td&gt;
    &lt;td&gt;
      
        &lt;br&gt;
      
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;

  In this case I've observed less differences on Throughput and Response times
  between version 2 and 4. This is because with Keep-Alive causes that the same
  apache processes are used for requests coming from the same web browser. As
  connection is kept open, reduces time to establish connections between clients
  (web browsers) to apache server. Thats why we can see higher throughput.
  Additionally for oci_pconnect without DRCP less amount of sessions are
  created. Without Keep-Alive apache opened much more sessions, as it had to
  create more processes and every process had to connect to Oracle.


  Lets summarize my observations:
&lt;ol&gt;
  &lt;li&gt;
    
      oci_pconnect with DRCP works stable in both cases (with and without
      Keep-Alive) giving maximun throughput and very low standard deviation,
    
  &lt;/li&gt;
  &lt;li&gt;
    
      oci_pconnect with DRCP has high standard deviation what means that there
      are lot of request with response time much higher then average,
    
  &lt;/li&gt;
  &lt;li&gt;
    
      In both cases connecting to Oracle with use of DRCP performed better than
      without.
    
  &lt;/li&gt;
&lt;/ol&gt;

  &lt;span lang="en-US"&gt;Next time I'll try to go into extremes to see how DRCP
  behaves. &lt;/span&gt;
&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2925275130884860286?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2925275130884860286/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2925275130884860286' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2925275130884860286'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2925275130884860286'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/10/testing-new-oci8-130-beta-for-php-with.html' title='Testing new OCI8 (1.3.0 beta) for PHP with DRCP Support'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://2.bp.blogspot.com/_6xECfZb_CD0/RyNtxx_dcnI/AAAAAAAADtk/ntfPvcz-334/s72-c/oci8_1.gif' height='72' width='72'/><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1117349913226503177</id><published>2007-10-26T22:36:00.000+02:00</published><updated>2007-10-26T22:39:25.408+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><title type='text'>I've got spammed (in comments)</title><content type='html'>Due to quite massive spam I'm receiving today in comments I had to turn on word verification for comment posting. Hope it will protect me from spam for future. And sorry for inconvenience when commenting,
&lt;br&gt;&lt;br&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1117349913226503177?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1117349913226503177/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1117349913226503177' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1117349913226503177'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1117349913226503177'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/10/ive-got-spammed-in-comments.html' title='I&apos;ve got spammed (in comments)'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5758303096490612203</id><published>2007-10-14T13:59:00.000+02:00</published><updated>2007-10-14T14:10:56.969+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Using Named Parameters within SQL</title><content type='html'>One of the Oracle 11g new feature that I like is ability to use Named Parameter
syntax in functions calls inside SQL. For example it is possible to run such
query:
&lt;pre&gt;select DBMS_METADATA.get_xml(&lt;br/&gt;          &lt;b&gt;object_type     =&amp;gt;&lt;/b&gt; object_type,&lt;br/&gt;          &lt;b&gt;name            =&amp;gt;&lt;/b&gt; object_name) &lt;br/&gt;     from user_objects&lt;br/&gt;where object_type in ('TABLE', 'VIEW');&lt;/pre&gt;
It was not possible in previous Oracle versions (before 11g). It was only
possible to specify parameters by position:
&lt;pre&gt;select DBMS_METADATA.get_xml(object_type, object_name) from user_objects&lt;br/&gt;where object_type in ('TABLE', 'VIEW');&lt;/pre&gt;
This is great feature as now SQL is more compatible with PL/SQL. And Named
Parameters syntax is my favorite method of calling functions, as it gives me
direct knowledge what value is assigned to parameters. Specifying parameters by
position requires to remember sequence of parameters in function definition.
Additionally named parameters syntax allows programmer to skip any of parameter that has default
value, or to change order of parameters in function call. It is also possible to
mix those 2 notations in single statement:
&lt;pre&gt;select DBMS_METADATA.get_xml(object_type, name =&amp;gt; object_name) from user_objects&lt;br/&gt;where object_type in ('TABLE', 'VIEW');&lt;/pre&gt;
Hope you like it&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5758303096490612203?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5758303096490612203/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5758303096490612203' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5758303096490612203'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5758303096490612203'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/10/using-named-parameters-within-sql.html' title='Using Named Parameters within SQL'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8064115801939278557</id><published>2007-10-09T20:16:00.000+02:00</published><updated>2007-10-09T20:19:55.174+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sql plus'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Comments in SQL*Plus</title><content type='html'>&lt;a href="http://awads.net/wp/2007/10/09/beware-of-comments-in-sql/" id="u1c8" title="This Warning from Eddie Awad"&gt;This
Warning from Eddie Awad&lt;/a&gt; remind me of problem with comments I've had some
time ago. I've prepared an script that was intended to run in sqlplus. Then I've
extensively tested it, and as a last step, I've commented it. And ... did not
test again. When this script was run on production caused errors. The problem
was in the way that sqlplus interpret comments.&lt;br/&gt;
Example:
&lt;pre&gt;SQL&amp;gt; select * from dual;

D
-
X&lt;/pre&gt;
runs fine, while this:
&lt;pre&gt;SQL&amp;gt; select * from dual; -- some comments&lt;/pre&gt;
stops at second line waiting for input:
&lt;pre&gt;SQL&amp;gt; select * from dual; -- some comment
&amp;nbsp; 2&amp;nbsp;&lt;/pre&gt;
It was really unpleasant experience.&lt;br/&gt;
&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8064115801939278557?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8064115801939278557/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8064115801939278557' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8064115801939278557'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8064115801939278557'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/10/comments-in-sqlplus.html' title='Comments in SQL*Plus'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5747322783422663544</id><published>2007-09-28T20:25:00.000+02:00</published><updated>2007-09-28T20:27:53.261+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='drcp'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>More on Oracle 11g DRCP</title><content type='html'>Due to comments from Sreekumar Seshadri and Krishna Mohan Itikarlapalli from
Oracle, I've corrected my previous post on
&lt;a href="http://pbarut.blogspot.com/2007/09/oracle-11g-drcp-functionality-test.html" id="fttt" title="DRCP Functionality"&gt;DRCP
Functionality&lt;/a&gt;. I must own up that I've omitted reading chapter on
&lt;a href="http://download.oracle.com/docs/cd/B28359_01/appdev.111/b28395/oci09adv.htm#CHDBIBBF" id="q_wp" title="DRCP in OCI Programmers Guide"&gt;DRCP
in OCI Programmers Guide&lt;/a&gt;. Based on name "&lt;b&gt;Database Resident&lt;/b&gt; Connection
Pooling" I implied that it's only required to configure it at Database Server
Side. In Fact it is partially true, because if you want to take advantage of
Connection pooling it's needed to change client code too. There are 3 levels of
benefits of DRCP and OCI enhancements in Oracle 11g:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    Configuring DRCP at DB Side without any change in Application. In this case
    only processes are pooled, and every time new connection is made, new
    session is created. This is what I've observed in
    &lt;a href="http://pbarut.blogspot.com/2007/09/oracle-11g-drcp-functionality-test.html" id="v0wa" title="previous post"&gt;previous
    post&lt;/a&gt; when I was using SQL*plus.
  &lt;/li&gt;
  &lt;li&gt;
    and 3. need changes in Application in code that connect to DB. I will just
    quote OCI Programmers Guide:&lt;br/&gt;
    &lt;blockquote&gt;
      &lt;ul&gt;
        &lt;li&gt;
          &lt;p&gt;
            &lt;i&gt;Applications that use &lt;/i&gt;&lt;code&gt;&lt;i&gt;OCISessionGet()&lt;/i&gt;&lt;/code&gt;&lt;i&gt; outside of an OCISessionPool,
            and specify the connection class and set &lt;/i&gt;&lt;code&gt;&lt;i&gt;purity=SELF&lt;/i&gt;&lt;/code&gt;&lt;i&gt; will be able
            to reuse both DRCP pooled server processes and sessions. However,
            following an &lt;/i&gt;&lt;code&gt;&lt;i&gt;OCISessionRelease()&lt;/i&gt;&lt;/code&gt;&lt;i&gt;, OCI will terminate the connection to the
            connection broker. On the next &lt;/i&gt;&lt;code&gt;&lt;i&gt;OCISessionGet()&lt;/i&gt;&lt;/code&gt;&lt;i&gt; call, the application
            will reconnect to the broker. Once it reconnects, the DRCP will
            assign a pooled server (and session) belonging to the connection
            class specified. Reconnecting, however, incurs the cost of
            connection establishment and re-authentication. Such applications
            achieve better sharing of DRCP resources (processes and sessions)
            but do not get the benefit of caching connections to the connection
            broker.&lt;/i&gt;
          &lt;/p&gt;
        &lt;/li&gt;
        &lt;li&gt;
          &lt;p&gt;
            &lt;i&gt;Applications that use OCISessionPool APIs and specify the
            connection class and set &lt;/i&gt;&lt;code&gt;&lt;i&gt;purity=SELF&lt;/i&gt;&lt;/code&gt;&lt;i&gt; make full use of the Database
            Resident Connection Pool functionality through reuse of both the
            pooled server process and the associated session and also getting
            the benefit of cached connections to the connection broker. Cached
            connections do not incur the cost of re-authentication on &lt;/i&gt;&lt;code&gt;&lt;i&gt;OCISessionGet()&lt;/i&gt;&lt;/code&gt;&lt;i&gt;.&lt;/i&gt;
          &lt;/p&gt;
        &lt;/li&gt;
      &lt;/ul&gt;
    &lt;/blockquote&gt;
  &lt;/li&gt;
&lt;/ol&gt;
So to really test DRCP I need to write some code to test it.&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5747322783422663544?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5747322783422663544/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5747322783422663544' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5747322783422663544'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5747322783422663544'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/09/more-on-oracle-11g-drcp.html' title='More on Oracle 11g DRCP'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5152850375513143313</id><published>2007-09-18T22:22:00.000+02:00</published><updated>2007-09-28T20:05:40.323+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='drcp'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle 11g DRCP: Functionality Test</title><content type='html'>This post is continuation of my series of post about
&lt;a href="http://pbarut.blogspot.com/2007/08/oracle-11g-drcp-database-resident.html" id="c2ck" title="Database Resident Connection Pooling"&gt;Database
Resident Connection Pooling&lt;/a&gt;.&lt;br/&gt;
Let start with session and processes. My test shows that Pooled Servers are
shown in v$session view only when there is user connected, that means session is
busy. For inactive servers only process in v$process view is reported. To
identify this processes we can run query like that:&lt;br/&gt;
&lt;pre&gt;select * from v$process&lt;br/&gt;where program like '%(L0%)';&lt;/pre&gt;
If our Connection pooling is started, at least one process will be reported.
This is &lt;s&gt;so called Connection Broker&lt;/s&gt; &lt;u&gt;process&lt;/u&gt; that is authenticating connections and
assigning them to another server for processing. According to my tests
&lt;s&gt;Connection Broker&lt;/s&gt; &lt;u&gt;this process&lt;/u&gt; usually have highest number in brackets (ex. L003 if you set
up max number of processes to 4). To see busy servers run this query:&lt;br/&gt;
&lt;pre&gt;select * from v$session&lt;br/&gt;where program like '%(L0%)';&lt;/pre&gt;
Note that Connection Broker is never reported in v$session view.&lt;br/&gt;
&lt;br/&gt;
In next test I've tested if global variables in packages are stored between
connections. My test confirms that packages are always initialized after new
connection is taken from pool. That's very good, and is what I was expecting.
This is advantage over traditional connection pooling at client side like in
Java, where environment is totally shared between consecutive use of the same
connection. &lt;u&gt;(This is true when only process if reused, when PURITY=NEW)&lt;/u&gt;&lt;br/&gt;
&lt;br/&gt;
My next test was concerning usage of context. I've created sample CONTEXT,
initialized it in session and reconnected. I've ensured that session was
assigned to the same process (pooled session) and read context. My test also
confirmed that context is reinitialized between connections. In traditional
connection pooling it will not happen. Also when using PHP and persistent
connection you have to take care of clearing global variables and context after
acquiring session from pool (or before giving it back to pool). Database
Resident Connection Pooling will make programmers life easier, at least on that
field. &lt;u&gt;(This is true when only process if reused, when PURITY=NEW)&lt;/u&gt;&lt;br/&gt;
&lt;br/&gt;
My last test for today was performance test. Test was run on rather poor desktop
machine with single processor.&lt;br/&gt;
&lt;table border="1"&gt;
  &lt;tbody&gt;
  &lt;tr&gt;
    &lt;th&gt;
      Testcase
    &lt;/th&gt;
    &lt;th&gt;
      Normal&lt;br/&gt;
      Connection
    &lt;/th&gt;
    &lt;th&gt;
      Pooled&lt;br/&gt;
      Connection
    &lt;/th&gt;
    &lt;th&gt;
      %Improvement
    &lt;/th&gt;
  &lt;/tr&gt;
  &lt;tr&gt;
    &lt;td&gt;
      Connect&lt;br/&gt;
      and Disconnect&lt;br/&gt;
      1000 times&lt;br/&gt;
    &lt;/td&gt;
    &lt;td&gt;
      226 sec
    &lt;/td&gt;
    &lt;td&gt;
      154 sec
    &lt;/td&gt;
    &lt;td&gt;
      31%
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;tr&gt;
    &lt;td&gt;
      Connect,&lt;br/&gt;
      Insert one row,&lt;br/&gt;
      Disconnect&lt;br/&gt;
      1000 times&lt;br/&gt;
    &lt;/td&gt;
    &lt;td&gt;
      309 sec
    &lt;/td&gt;
    &lt;td&gt;
      178 sec
    &lt;/td&gt;
    &lt;td&gt;
      42%
    &lt;/td&gt;
  &lt;/tr&gt;
  &lt;/tbody&gt;
&lt;/table&gt;
This results are very promising. First we see 30% improvement of time to connect
to DB. What is more important we can see 40% less time on repeating the same
simple statement after establishing each connection. The only explanation is
that Pooled connection can reuse already parsed statement. That is good news if
we think about scalability.&lt;br/&gt;
&lt;br/&gt;
You may be also interested in
&lt;a href="http://www.oracle.com/technology/tech/oci/pdf/oracledrcp11g.pdf" id="n_3u" title="Oracle Official Whitepaper on DRCP"&gt;Oracle
Official White-paper on DRCP&lt;/a&gt;.&lt;br/&gt;
&lt;br/&gt;
At the end I would like to thank
&lt;a href="http://blogs.oracle.com/opal/" id="hfou" title="Christopher Jones"&gt;Christopher
Jones&lt;/a&gt; as he was involved in DRCP development. I've mailed with him few times
last year about problems with PHP-Oracle connectivity and lack of connection
pooling.&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5152850375513143313?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5152850375513143313/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5152850375513143313' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5152850375513143313'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5152850375513143313'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/09/oracle-11g-drcp-functionality-test.html' title='Oracle 11g DRCP: Functionality Test'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-9085951372513521806</id><published>2007-09-16T13:20:00.000+02:00</published><updated>2007-09-16T13:21:30.206+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><title type='text'>Blog roll reorganization</title><content type='html'>Today i've reorganized my blogroll. Until now I was reading news using &lt;a href="http://OraNA.info"&gt;OraNA.info&lt;/a&gt; maintained by &lt;a href="http://awads.net/wp/"&gt;Eddie Awad&lt;/a&gt;. But there is too many post that are out of my interest. So i've decided to subscribe to feeds from some of them. Here is full list:
&lt;a href="http://www.oracle-developer.net/"&gt;Adrian Bilington&lt;/a&gt;,  
&lt;a href="http://www.oracloid.com/"&gt;Alex Gorbachev&lt;/a&gt;,  
&lt;a href="http://positivesharing.com/"&gt;Alexander Kjerulf - CHO&lt;/a&gt;, 
&lt;a href="http://blog.red-database-security.com/"&gt;Alexander Kornbrust&lt;/a&gt;,  
&lt;a href="http://blogs.oracle.com/alison/"&gt;Alison Holloway&lt;/a&gt;,  
&lt;a href="http://technology.amis.nl/blog/"&gt;AMIS Blog&lt;/a&gt;,  
&lt;a href="http://www.bloggingaboutoracle.org/"&gt;Blogging about Oracle&lt;/a&gt;,  
&lt;a href="http://carlback.blogspot.com/"&gt;Carl Backstrom&lt;/a&gt;,  
&lt;a href="http://prodlife.wordpress.com/"&gt;Chen Shapira&lt;/a&gt;, 
&lt;a href="http://blogs.oracle.com/opal/"&gt;Christopher Jones&lt;/a&gt;,  
&lt;a href="http://coskan.wordpress.com/"&gt;Coskan Gundogar&lt;/a&gt;,  
&lt;a href="http://headrush.typepad.com/creating_passionate_users/"&gt;Creating Passionate Users&lt;/a&gt;,  
&lt;a href="http://dgielis.blogspot.com/"&gt;Dimitri Gielis&lt;/a&gt;,  
&lt;a href="http://orastory.wordpress.com/"&gt;Dominic Brooks&lt;/a&gt;,  
&lt;a href="http://ora.seiler.us/"&gt;Don Seiler&lt;/a&gt;, 
&lt;a href="http://awads.net/wp/"&gt;Eddie Awad&lt;/a&gt;,  
&lt;a href="http://esemrick.blogspot.com/"&gt;Eric S. Emrick&lt;/a&gt;,  
&lt;a href="http://www.escapefromcubiclenation.com/get_a_life_blog/"&gt;Escape from Cubicle Nation&lt;/a&gt;,  
&lt;a href="http://igor-db.blogspot.com/"&gt;Gary Myers&lt;/a&gt;,  
&lt;a href="http://tonguc.wordpress.com/"&gt;H.Tonguç Yilmaz&lt;/a&gt;,  
&lt;a href="http://www.dizwell.com/prod/blog"&gt;Howard Rogers - Dizwell&lt;/a&gt;, 
&lt;a href="http://oramossoracle.blogspot.com/"&gt;Jeff Moss&lt;/a&gt;,  
&lt;a href="http://www.ardentperf.com/"&gt;Jeremy Schneider&lt;/a&gt;,  
&lt;a href="http://jonathanlewis.wordpress.com/"&gt;Jonathan Lewis&lt;/a&gt;,  
&lt;a href="http://jornica.blogspot.com/"&gt;Jorrit Nijssen&lt;/a&gt;,  
&lt;a href="http://kevinclosson.wordpress.com/"&gt;Kevin Closson&lt;/a&gt;,  
&lt;a href="http://laurentschneider.com/"&gt;Laurent Schneider&lt;/a&gt;, 
&lt;a href="http://blogs.ittoolbox.com/oracle/guide"&gt;Lewis Cunningham&lt;/a&gt;,  
&lt;a href="http://sysdba.wordpress.com/"&gt;Lutz Hartmann&lt;/a&gt;,  
&lt;a href="http://www.liberidu.com/blog/"&gt;Marco Gralike&lt;/a&gt;,  
&lt;a href="http://www.orawin.info/services/"&gt;Niall Litchfield&lt;/a&gt;,  
&lt;a href="http://oraqa.com/"&gt;OraQA&lt;/a&gt;,  
&lt;a href="http://bar-solutions.com/wordpress/"&gt;Patch&lt;/a&gt;, 
&lt;a href="http://inside-apex.blogspot.com/"&gt;Patrick Wolf&lt;/a&gt;,  
&lt;a href="http://blog.penelopetrunk.com/"&gt;Penelope Trunk&lt;/a&gt;,  
&lt;a href="http://www.pythian.com/blogs/"&gt;Pythian Group&lt;/a&gt;,  
&lt;a href="http://robertbaillie.blogspot.com/"&gt;Robert Baillie&lt;/a&gt;,  
&lt;a href="http://jaffardba.blogspot.com/"&gt;Sayed Jaffar Hussain&lt;/a&gt;,  
&lt;a href="http://feuerthoughts.blogspot.com/"&gt;Steven Feuerstein&lt;/a&gt;, 
&lt;a href="http://www.oraclealchemist.com/index.php"&gt;Steven Karam&lt;/a&gt;,  
&lt;a href="http://blog.tanelpoder.com/"&gt;Tanel Poder&lt;/a&gt;,  
&lt;a href="http://www.oracle-base.com/blog/"&gt;Tim Hall&lt;/a&gt;,  
&lt;a href="http://tkyte.blogspot.com/"&gt;Tom Kyte&lt;/a&gt;,  
&lt;a href="http://oraclebizint.wordpress.com/"&gt;Venkatakrishnan J&lt;/a&gt;,  
&lt;a href="http://oracletoday.blogspot.com/"&gt;YAS&lt;/a&gt;.
&lt;br /&gt;&lt;br /&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-9085951372513521806?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/9085951372513521806/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=9085951372513521806' title='8 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9085951372513521806'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9085951372513521806'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/09/blog-roll-reorganization.html' title='Blog roll reorganization'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>8</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-7146209979367028212</id><published>2007-09-13T21:45:00.000+02:00</published><updated>2007-09-13T21:47:14.572+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Operating on XMLType containing &amp; (Ampersands)</title><content type='html'>I was reading today Lewis post on
&lt;a href="http://blogs.ittoolbox.com/oracle/guide/archives/how-to-deal-with-oracle-xml-and-ampersands-in-xml-documents-18949" id="un55" title='How to Deal With Oracle XML and Ampersands ("&amp;amp;") in XML Documents'&gt;How
to Deal With Oracle XML and Ampersands ("&amp;amp;") in XML Documents&lt;/a&gt;.
Personally I prefer different way. I use XMLElement function to generate XML
documents. In my opinion this is more elegant way. The sample from Lewis post
will look like that:&lt;br/&gt;
&lt;pre&gt;set define off&lt;br/&gt;declare&lt;br/&gt;&amp;nbsp; v_xml xmltype;&lt;br/&gt;begin&lt;br/&gt;  select xmlelement("ROWSET", &lt;br/&gt;           xmlelement("ROW", &lt;br/&gt;             xmlelement("COLA", 'lewis&amp;amp;me')))&lt;br/&gt;    into v_xml &lt;br/&gt;    from dual;&lt;br/&gt;end;&lt;br/&gt;/&lt;/pre&gt;
Disadvantage of this method is that you have to use SQL. But in most cases it's
used while retrieving data from database, so it should not be a problem. Some
time ago
&lt;a href="http://pbarut.blogspot.com/2006/11/links-2006-11-20.html" id="du_8" title="I was proposing"&gt;I
was proposing&lt;/a&gt; to read document
&lt;a href="http://www.oracle.com/technology/tech/xml/xmldb/Current/TWP_Mastering_XML_Generation.pdf"&gt;Mastering
XML Generation in Oracle Database 10g Release 2&lt;/a&gt;. It is really good source of
knowledge on XML manipulation inside Oracle database.&lt;br/&gt;
If you want to extract correctly ampersands and other special characters like
&lt;b&gt;&amp;lt;&lt;/b&gt; and &lt;b&gt;&amp;gt;&lt;/b&gt; from XML document I suggest to read my post on
&lt;a href="http://pbarut.blogspot.com/2007/01/oracle-xmltype-exctractvalue-vs-extract.html" id="zr2t" title="differences between extract and extractvalue"&gt;differences
between extract and extractvalue&lt;/a&gt; functions. If you want to manually convert
&lt;b&gt;&amp;amp;amp;&lt;/b&gt; to &lt;b&gt;&amp;amp;&lt;/b&gt; you can use function dbms_xmlgen.convert with
second parameter set to 1:&lt;br/&gt;
&lt;pre&gt;SQL&amp;gt; select dbms_xmlgen.convert('me&amp;amp;amp;lewis', 1) from dual;&lt;br/&gt;
me&amp;amp;lewis&lt;/pre&gt;
&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-7146209979367028212?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/7146209979367028212/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=7146209979367028212' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7146209979367028212'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7146209979367028212'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/09/operating-on-xmltype-containing.html' title='Operating on XMLType containing &amp; (Ampersands)'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8842202516201827794</id><published>2007-09-05T22:05:00.000+02:00</published><updated>2007-09-05T22:06:59.061+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Alternative Syntax for Insert</title><content type='html'>Alternative Syntax for Insert&lt;br/&gt;
&lt;br/&gt;
Let me show my idea of SQL improvement, that I would like to see. Traditional
insert works like that:
&lt;pre&gt;insert into table_a&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; (column_1, column_2, column_3, column_4)&lt;br/&gt;&amp;nbsp; values&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; (value_1, value_2, value_3, value_4);&lt;/pre&gt;
What I would like to have is something like that:
&lt;pre&gt;insert into table_a&lt;br/&gt;&amp;nbsp;&amp;nbsp; set column_1 = value_1&lt;br/&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; ,column_2 = value_2&lt;br/&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; ,column_3 = value_3&lt;br/&gt;&amp;nbsp;&amp;nbsp; &amp;nbsp;&amp;nbsp; ,column_4 = value_4;&lt;/pre&gt;
With this syntax code would be easier to maintain. Especially, when you have to
add or delete, or find error in insert to table with many columns. Biggest
advantage of this would be close relationship between column name and value that
will be set for that column. In INSERT that we know it column name and value are
quite far from each other, so even for table with 10 columns it might be hard to
find corresponding entries.&lt;br/&gt;
In PL/SQL there is an workaround to get similar solution:
&lt;pre&gt;declare&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; v_row table_a%rowtype;&lt;br/&gt;begin&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; v_row.column_1 := value_1;&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; v_row.column_2 := value_2;&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; v_row.column_3 := value_3;&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; v_row.column_4 := value_4;&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp; insert into table_a values v_row;&lt;br/&gt;end;&lt;/pre&gt;
But it's PL/SQL not pure SQL. I really would like to have this syntax in next
Oracle release...&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8842202516201827794?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8842202516201827794/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8842202516201827794' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8842202516201827794'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8842202516201827794'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/09/alternative-syntax-for-insert.html' title='Alternative Syntax for Insert'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-682358856907908028</id><published>2007-09-04T19:22:00.000+02:00</published><updated>2007-09-04T19:23:51.927+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='about'/><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><title type='text'>One Year Blogging</title><content type='html'>It's one year since I started blogging. It's time for some statistics and
summary. During last year:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    I've published 69 posts - it's 1 post every 6 days (on average)
  &lt;/li&gt;
  &lt;li&gt;
    51 post are about Oracle (74%)
  &lt;/li&gt;
  &lt;li&gt;
    Over 29200 page views
  &lt;/li&gt;
  &lt;li&gt;
    84% of traffic comes from Google
  &lt;/li&gt;
  &lt;li&gt;
    35% of traffic is from US, Next on list are: UK (8%), India (7%), Germany
    (5%) and Poland (4%)
  &lt;/li&gt;
&lt;/ol&gt;
Top 10 of most often visited pages:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/10/oracle-11g-new-features.html"&gt;Oracle
    11g new features&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/02/restore-controlfile-andor-spfile-from.html"&gt;Restore
    CONTROLFILE and/or SPFILE from autobackup&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/01/ora-03297-on-empty-datafile.html"&gt;ORA-03297
    on empty datafile&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/11/ora-30625-and-xmltype.html"&gt;ORA-30625
    and XMLType&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/09/visual-sourcesafe-invalid-dos-path.html"&gt;Visual
    SourceSafe - Invalid DOS Path&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/02/empty-string-is-not-null.html"&gt;Empty
    String IS NOT NULL?&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/01/oracle-xmltype-exctractvalue-vs-extract.html"&gt;Oracle
    XMLType: exctractvalue vs. extract&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/12/applying-oracle-10203-patch.html"&gt;Applying
    Oracle 10.2.0.3 patch&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/11/xmltype-and-namespace-problem.html"&gt;XMLType
    and Namespace problem&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/12/utlmatch-string-similarity-in-oracle.html"&gt;UTL_MATCH
    - String Similarity in Oracle&lt;/a&gt;
  &lt;/li&gt;
&lt;/ol&gt;
Most commented posts:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/09/visual-sourcesafe-invalid-dos-path.html"&gt;Visual
    SourceSafe - Invalid DOS Path&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/03/yet-another-tokenizer-in-oracle.html" id="bvdb"&gt;Yet
    another tokenizer in Oracle&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/06/log-buffer-48.html" id="h0jw" title="Log Buffer #48"&gt;Log
    Buffer #48&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/10/what-tool-do-you-use-to-make-blog.html" id="jdc2" title="What tool do you use to make blog backup?"&gt;What
    tool do you use to make blog backup?&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html" id="tby-" title="Rolling Back the DDL"&gt;Rolling
    Back the DDL&lt;/a&gt;
  &lt;/li&gt;
&lt;/ol&gt;
And finally post that I think are valuable but not so often seen or commented:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/05/moving-domain-index-to-another.html" id="xr4z" title="Moving domain index to another tablespace"&gt;Moving
    domain index to another tablespace&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/03/monitor-progress-of-long-running.html" id="tnig" title="Monitor progress of long running processes"&gt;Monitor
    progress of long running processes&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/07/extracting-data-to-excel-using-only.html" id="my_n" title="Extracting Data to Excel using only SQL*Plus"&gt;Extracting
    Data to Excel using only SQL*Plus&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/06/rows-to-single-string-or-aggregating.html" id="a0az" title="Rows to single string or aggregating strings"&gt;Rows
    to single string or aggregating strings&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/09/flashback-table-and-materialized-view.html" id="eec_"&gt;Flashback
    Table and Materialized View – not working together&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/10/group-comparison-conditions.html"&gt;Group
    Comparison Conditions&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/10/search-oracle-blogs.html"&gt;Search
    Oracle Blogs&lt;/a&gt; - I was before Eddie with this idea; but Eddie has more
    readers...
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/10/binding-list-variable.html"&gt;Binding
    list variable&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2006/11/blogger-beta-backup-tool.html" id="zly1" title="Blogger Beta Backup tool"&gt;Blogger
    Beta Backup tool&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/03/movingadding-control-file-when-using.html" id="abwm" title="Moving/Adding Control file when using SPFile"&gt;Moving/Adding
    Control file when using SPFile&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://pbarut.blogspot.com/2007/03/table-that-cannot-be-deleted.html" id="pzn0" title="Table that cannot be deleted"&gt;Table
    that cannot be deleted&lt;/a&gt;
  &lt;/li&gt;
&lt;/ol&gt;
I hope that in next months I will find time and good subjects to blog about.&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-682358856907908028?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/682358856907908028/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=682358856907908028' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/682358856907908028'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/682358856907908028'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/09/one-year-blogging.html' title='One Year Blogging'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3652026970455896241</id><published>2007-08-31T23:52:00.000+02:00</published><updated>2007-08-31T23:56:31.932+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='drcp'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='linux'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle 11g DRCP: Database Resident Connection Pooling - second attempt</title><content type='html'>In my last post I wrote about unsuccessful attempt to check functionality of
&lt;a href="http://pbarut.blogspot.com/2007/08/drcp-database-resident-connection.html" id="t1gj" title="DRCP: Database Resident Connection Pooling"&gt;DRCP:
Database Resident Connection Pooling&lt;/a&gt;. Now it's time for success story :) The
problem with previous situation was, that Oracle was not fully functional. And
that was because I manually set, that i have all proper versions of linux
packages, what was not true.&lt;br/&gt;
Now I've
installed&amp;nbsp;&lt;a href="http://www.oracle.com/technologies/linux/index.html" id="ujux" title="Oracle Enterprise Linux v 5.0"&gt;Oracle
Enterprise Linux v 5.0&lt;/a&gt; and Oracle 11g over it, with some help of
&lt;a href="http://www.oracle-base.com/articles/11g/OracleDB11gR1InstallationOnEnterpriseLinux4and5.php" id="yrge" title="Tim instructions"&gt;Tim
instructions&lt;/a&gt;.&lt;br/&gt;
I've added entry in TNSNAMES.ORA on linux box:
&lt;pre&gt;DB11GPOOL =&lt;br/&gt;  (DESCRIPTION =&lt;br/&gt;    (ADDRESS_LIST =&lt;br/&gt;      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.194.111)(PORT = 1521))&lt;br/&gt;    )&lt;br/&gt;    (CONNECT_DATA =&lt;br/&gt;      (SERVICE_NAME = DB11G)&lt;b&gt;(SERVER=POOLED)&lt;/b&gt;&lt;br/&gt;    )&lt;br/&gt;  )&lt;/pre&gt;
And tried to connect to pool&lt;br/&gt;
&lt;pre&gt;[oracle@localhost admin]$ sqlplus pooltest/pool@db11gpool&lt;br/&gt;SQL*Plus: Release 11.1.0.6.0 - Production on Wed Aug 29 01:44:53 2007&lt;br/&gt;Copyright (c) 1982, 2007, Oracle.&amp;nbsp; All rights reserved.&lt;br/&gt;ERROR:&lt;br/&gt;ORA-12520: TNS:listener could not find available handler for requested type of server&lt;/pre&gt;
&lt;br/&gt;
So I've started connection pooling (as SYS at Oracle):
&lt;pre&gt;exec DBMS_CONNECTION_POOL.START_POOL();&lt;/pre&gt;
And tried again:
&lt;pre&gt;[oracle@localhost admin]$ sqlplus pooltest/pool@db11gpool&lt;br/&gt;SQL*Plus: Release 11.1.0.6.0 - Production on Wed Aug 29 02:02:37 2007&lt;br/&gt;Copyright (c) 1982, 2007, Oracle.&amp;nbsp; All rights reserved.&lt;br/&gt;Connected to:&lt;br/&gt;Oracle Database 11g Enterprise Edition Release 11.1.0.6.0 - Production&lt;br/&gt;With the Partitioning, OLAP, Data Mining and Real Application Testing options&lt;br/&gt;SQL&amp;gt; select 1 from dual;&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;br/&gt;----------&lt;br/&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1&lt;/pre&gt;
This time successful login.&lt;br/&gt;
Now I've left this session untouched for some time (more then 300 second -
default time-out for pool)
&lt;pre&gt;SQL&amp;gt; select 1 from dual;&lt;br/&gt;select 1 from dual&lt;br/&gt;*&lt;br/&gt;ERROR at line 1:&lt;br/&gt;ORA-03113: end-of-file on communication channel&lt;br/&gt;Process ID: 2821&lt;br/&gt;Session ID: 125 Serial number: 21&lt;/pre&gt;
&lt;br/&gt;
As you can see, session was timed-out by pool, and disconnected.&lt;br/&gt;
Ok, lets change parameters for pool to observer behaviour, when max number of
session is reached.&lt;br/&gt;
Execute it as SYS:
&lt;pre&gt;begin&lt;br/&gt;&amp;nbsp;DBMS_CONNECTION_POOL.ALTER_PARAM ('','MINSIZE','1');&lt;br/&gt;&amp;nbsp;DBMS_CONNECTION_POOL.ALTER_PARAM ('','MAXSIZE','4');&lt;br/&gt;end;&lt;br/&gt;/&lt;/pre&gt;
After I set it, I'was able to have &lt;span style="FONT-WEIGHT:bold"&gt;3 (not 4)
&lt;/span&gt;simultaneous sessions using Connection pool. Whenever I start 4-th or
5-th session &lt;span style="FONT-WEIGHT:bold"&gt;it is waiting for connection&lt;/span&gt;.
You do not get any error, session just hung up. When one of active session is
released (closed or timed-out) then one of waiting sessions is being connected.
When I was looking for explanation, I found out one that in view V$CPOOL_STATS:&lt;br/&gt;
&lt;ul&gt;
  &lt;li&gt;
    &lt;span style="FONT-WEIGHT:bold"&gt;NUM_OPEN_SERVERS=4&lt;/span&gt; - Total number of
    busy and free servers in the pool (including authentication servers)&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;span style="FONT-WEIGHT:bold"&gt;NUM_BUSY_SERVERS=3&lt;/span&gt; - Total number of
    busy servers in the pool (not including authentication servers)&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;span style="FONT-WEIGHT:bold"&gt;NUM_AUTH_SERVERS=1&lt;/span&gt; - Number of
    authentication servers in the pool&lt;br/&gt;
  &lt;/li&gt;
&lt;/ul&gt;
So, we have to have at least 1 authentication server in our pool. We should be
aware of this when we setup small number of MAXSIZE of pool.&lt;br/&gt;
When I first read about database connection pooling I was thinking that when you
start using all connections in pool, than next attempt to connect will open new
normal session. But it will not be good. Mechanism of queues is better, because
client will not overload database server. Might be it's not good for clients, as
they might wait long time. On the other hand in well written application
sessions should be short and closed immediately when no more needed in request.&lt;br/&gt;
More tests of DRCP in next posts...
&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3652026970455896241?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3652026970455896241/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3652026970455896241' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3652026970455896241'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3652026970455896241'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/08/oracle-11g-drcp-database-resident.html' title='Oracle 11g DRCP: Database Resident Connection Pooling - second attempt'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8640449314477582037</id><published>2007-08-27T23:15:00.000+02:00</published><updated>2007-08-31T23:58:45.963+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='drcp'/><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>DRCP: Database Resident Connection Pooling</title><content type='html'>Finally I've found time and managed to install Oracle 11g. I did it on Fedora
Core 5 run in VMWare Server on Windows 2K Pro.&lt;br/&gt;
My first attempt was to install it on Fedora Core 6 but I didn't succeed, and
even I managed to corrupt VM totally. My second try was to create new VM with
FC5. I've applied all available updates, and tried to install Oracle 11g. Oracle
gave warning that some packages do not match requirements, but after manually
marking check-box it proceeded and installed successfully. And seems to be fully
functional. Do not try this for production DB :)&lt;br/&gt;
After that I've spend lot of time trying to connect to this DB from my Windows
box. I was reconfiguring VM Network setting, FC Network setting many times
without any sign of progress. Finally I found out that it can be firewall that
is causing problem. It was really silly that I spend so much time to solve so
simple problem...&lt;br/&gt;
Any way my Oracle 11g is up and running, so I started to test one of th features
that are
&lt;a href="http://pbarut.blogspot.com/2007/07/oracle-11g-announced-features-preview.html" id="b7ff" title="in my interest"&gt;in
my interest&lt;/a&gt;: DRCP: Database Resident Connection Pooling.&lt;br/&gt;
I've enables DRCP:&lt;br/&gt;
&lt;pre&gt;SQL&amp;gt; EXECUTE DBMS_CONNECTION_POOL.START_POOL();&lt;br/&gt;PL/SQL procedure successfully completed.&lt;/pre&gt;
And created sample user for tests:
&lt;pre&gt;SQL&amp;gt; create user pooltest identified by pool ;&lt;br/&gt;User created.&lt;br/&gt;SQL&amp;gt; grant connect to pooltest;&lt;br/&gt;Grant succeeded.&lt;/pre&gt;
I've added entry in TNSNAMES.ORA on Windows box:
&lt;pre&gt;DB11GPOOL =&lt;br/&gt;  (DESCRIPTION =&lt;br/&gt;    (ADDRESS_LIST =&lt;br/&gt;      (ADDRESS = (PROTOCOL = TCP)(HOST = 192.168.194.111)(PORT = 1521))&lt;br/&gt;    )&lt;br/&gt;    (CONNECT_DATA =&lt;br/&gt;      (SERVICE_NAME = DB11G)&lt;b&gt;(SERVER=POOLED)&lt;/b&gt;
    )
  )&lt;/pre&gt;
And tried to connect using POOLED server:
&lt;pre&gt;c:\Temp&amp;gt;sqlplus pooltest/pool@db11gpool&lt;br/&gt;&lt;br/&gt;SQL*Plus: Release 10.2.0.2.0 - Production on Mon Aug 27 22:30:08 2007&lt;br/&gt;&lt;br/&gt;Copyright (c) 1982, 2005, Oracle.  All Rights Reserved.&lt;br/&gt;&lt;br/&gt;ERROR:&lt;br/&gt;ORA-56606: DRCP: Client version doesnot support the feature&lt;/pre&gt;
So, DRCP needs proper client version to work. It's not a good news, as I thought
that this will not require any changes at client side :(&lt;br/&gt;
I have to make my test on single box, or install Oracle on one more box (VM).
Ok, first try from the same box where DB installed:
&lt;pre&gt;[oracle@vm111 admin]$ sqlplus pooltest/pool@db11gpool&lt;br/&gt;
SQL*Plus: Release 11.1.0.6.0 - Production on Mon Aug 27 22:41:51 2007&lt;br/&gt;
Copyright (c) 1982, 2007, Oracle.&amp;nbsp; All rights reserved.&lt;br/&gt;
Aborted&lt;/pre&gt;
Seems that I have to dig little more more to make it working.&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł
&lt;br/&gt;&lt;br/&gt;&lt;span style="font-weight:bold;"&gt;UPDATE&lt;/span&gt;: Success story on DRCP in &lt;a href="http://pbarut.blogspot.com/2007/08/oracle-11g-drcp-database-resident.html"&gt;next post&lt;/a&gt;.&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8640449314477582037?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8640449314477582037/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8640449314477582037' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8640449314477582037'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8640449314477582037'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/08/drcp-database-resident-connection.html' title='DRCP: Database Resident Connection Pooling'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3143517054613712327</id><published>2007-08-24T08:54:00.000+02:00</published><updated>2007-08-24T08:58:31.154+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='fun'/><title type='text'>It's feature not a bug ;)</title><content type='html'>Friend of mine send me an link to funny picture:&lt;br/&gt;
&lt;img src="http://blogs.pcworld.com/tipsandtweaks/archives/feature.jpg" border="0" alt="" /&gt;
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3143517054613712327?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3143517054613712327/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3143517054613712327' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3143517054613712327'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3143517054613712327'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/08/its-feature-not-bug.html' title='It&apos;s feature not a bug ;)'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3535314093110373257</id><published>2007-08-18T13:18:00.000+02:00</published><updated>2007-08-18T13:20:33.386+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='links'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle 11g is released - my links</title><content type='html'>As you probably know,
  &lt;a href="http://www.oracle.com/technology/software/products/database/index.html" id="bifr" title="Oracle 11g"&gt;Oracle
  11g&lt;/a&gt; is released - now only for linux x86. I've already downloaded it, but
  had no time to install and play with it. Anyway I've decided to make summary
  of bloggers post on 11g for my future reference:
&lt;ul&gt;
  &lt;li&gt;
    &lt;a href="http://www.oracle.com/technology/documentation/database.html" id="e.d-" title="Oracle 11g Documentation"&gt;Oracle
    11g Documentation&lt;/a&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://www.dizwell.com/prod/node/936" id="c9xd" title="Oracle 11g new parameters"&gt;Oracle
    11g new parameters&lt;/a&gt; by Howard Rogers "dizwell"
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://www.dizwell.com/prod/node/938" id="fya6" title="Oracle 11g new parameters part 2"&gt;Oracle
    11g new parameters part 2&lt;/a&gt; by dizwell
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://www.dizwell.com/prod/node/942" id="yw0d" title="Oracle 11g new parameters part 3"&gt;Oracle
    11g new parameters part 3&lt;/a&gt; by dizwell
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://oracletoday.blogspot.com/2007/08/bind-variable-peeking-in-11g.html" id="r88i" title="Bind variable peeking in 11g"&gt;Bind
    variable peeking in 11g&lt;/a&gt; by Yas
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://oracletoday.blogspot.com/2007/08/invisible-indexes-in-11g.html" id="pfmj" title="Invisible Indexes"&gt;Invisible
    Indexes&lt;/a&gt; by Yas
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://www.liberidu.com/blog/?p=246" id="uo0." title="Security for XMLDB (DBMS_NETWORK_ACL_ADMIN)"&gt;Security
    for XMLDB (DBMS_NETWORK_ACL_ADMIN)&lt;/a&gt; by Marco Gralike
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://tardate.blogspot.com/2007/08/first-tests-of-11g-native-web-services.html" id="pen-" title="11g Native Web Services"&gt;11g
    Native Web Services&lt;/a&gt; by Paul Gallagher (Tardate)
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://technology.amis.nl/blog/?p=2354" id="brvv" title="FOLLOWS Clause in Create Trigger Statement"&gt;FOLLOWS
    Clause in Create Trigger Statement&lt;/a&gt; by Jurgen Kemmelings
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://technology.amis.nl/blog/?p=2270" id="otsd" title="New PL/SQL Compiler Warning in Oracle 11g"&gt;New
    PL/SQL Compiler Warning in Oracle 11g&lt;/a&gt; by Jurgen Kemmelings&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://julian.dyke.users.btopenworld.com/com/Internals/Oracle11_1/Oracle11_1.html" id="anzc" title="Oracle 10.2 versus 11.1"&gt;Oracle
    10.2 versus 11.1&lt;/a&gt; by Julian Dyke
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://kevinclosson.wordpress.com/2007/07/12/oracle11g-wheres-my-alert-log/" id="uraj" title="Oracle11g: Where’s My Alert Log?"&gt;Oracle11g:
    Where’s My Alert Log?&lt;/a&gt; by Kevin Closson
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://www.oracle-base.com/articles/11g/OracleDB11gR1InstallationOnEnterpriseLinux4and5.php" id="pa8u" title="Oracle Database 11g Release 1 (11.1) Installation On Enterprise Linux 4.5 and 5.0"&gt;Oracle
    Database 11g Release 1 (11.1) Installation On Enterprise Linux 4.5 and
    5.0&lt;/a&gt; by Tim Hall&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    &lt;a href="http://www.oracle-base.com/articles/11g/OracleDB11gR1RACInstallationOnLinuxUsingNFS.php" id="w:zl" title="Oracle 11g Release 1 RAC On Linux Using NFS"&gt;Oracle
    11g Release 1 RAC On Linux Using NFS&lt;/a&gt; by Tim Hall&lt;br/&gt;
  &lt;/li&gt;
&lt;/ul&gt;
&lt;br/&gt;
There is much more posts about Oracle 11g but those listed above got by
attention.&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3535314093110373257?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3535314093110373257/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3535314093110373257' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3535314093110373257'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3535314093110373257'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/08/oracle-11g-is-released-my-links.html' title='Oracle 11g is released - my links'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-32196918285235806</id><published>2007-07-26T19:36:00.000+02:00</published><updated>2007-07-26T19:40:22.510+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='picasa'/><category scheme='http://www.blogger.com/atom/ns#' term='photos'/><category scheme='http://www.blogger.com/atom/ns#' term='google'/><title type='text'>Pictures on Google map</title><content type='html'>Few days ago I wrote about idea to integrate
&lt;a href="http://pbarut.blogspot.com/2007/07/after-vacations-tagging-photos-with-geo.html" title="Google Maps and Picasa"&gt;Google
Maps and Picasa&lt;/a&gt; pictures in the way that you can see pictures on map. Today
I've discovered that it is already done in very similar way. When you go to
&lt;a href="http://maps.google.com" title="maps.google.com"&gt;maps.google.com&lt;/a&gt;
there is an new tab My Maps. Then you can check "Photos from
&lt;a href="http://www.panoramio.com/" title="panoramio"&gt;Panoramio&lt;/a&gt;" and you can
scroll and pane map to see pictures from different places. Really cool feature.
I'm looking forward for same functionality with Google Picasa. BTW,
&lt;a href="http://www.panoramio.com/blog/google-agrees-to-acquire-panoramio/" title="Panoramio was bought by Google"&gt;Panoramio
was (will be) bought by Google&lt;/a&gt; in May 2007. I wonder if they integrate it
with Picasa ...&lt;br/&gt;
Have Fun with pictures&lt;br/&gt;
&lt;br/&gt;
&lt;a href="http://picasaweb.google.com/pawel.barut/BuGariaCzerwiec2007/photo#5084459768784110242"&gt;&lt;img src="http://lh4.google.com/pawel.barut/Ro-hOJkkQqI/AAAAAAAACVk/kBLcFDw50wA/s400/DSC_1750.JPG"/&gt;&lt;/a&gt;&lt;br/&gt;
&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-32196918285235806?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/32196918285235806/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=32196918285235806' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/32196918285235806'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/32196918285235806'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/07/pictures-on-google-map.html' title='Pictures on Google map'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3101539675478694229</id><published>2007-07-11T20:15:00.000+02:00</published><updated>2007-07-11T20:29:50.275+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='flashback'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle 11g Announced: Features Preview</title><content type='html'>&lt;a href="http://www.oracle.com/corporate/press/2007_jul/database-11g.html" title="Oracle 11g was today announced"&gt;Oracle
11g was today announced&lt;/a&gt;. As an engineer I'm interested in new features of
11g release. I was already writing about this
&lt;a href="http://pbarut.blogspot.com/2006/10/oracle-11g-new-features.html" title="Oracle 11g new features"&gt;here&lt;/a&gt;
and
&lt;a href="http://pbarut.blogspot.com/2006/10/oracle-11g-new-features-part-2.html" title="Oracle 11g new features"&gt;here&lt;/a&gt;.
But this were just my thoughts based on others relations from Oracle Open World
2006.&lt;br/&gt;
Now official list of Oracle 11g new features is
&lt;a href="http://www.oracle.com/technology/products/database/oracle11g/pdf/database-11g-new-features-whitepaper.pdf" title="published"&gt;published&lt;/a&gt;.
&lt;a href="http://www.oracle.com/technology/products/database/oracle11g/index.html" title="Here is page"&gt;Here
is page&lt;/a&gt; that contains more technical information on Oracle 11g.&lt;br/&gt;
Based on new features list I choose some that are very useful in project that
I'm work now on, and I see them as important:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    Binary XML storage and XML path indexing for schema-less XML documents&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    Result caches: improves speed of repeated execution of queries and function
    calls that access read-only or read-mostly data.&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    Database Resident Connection Pooling: enables faster connections to the
    database for application, that do not provide connection pooling (ex. PHP).&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    Faster triggers, including more-efficient invocations of per-row triggers
  &lt;/li&gt;
  &lt;li&gt;
    Faster simple SQL operations
  &lt;/li&gt;
  &lt;li&gt;
    SecureFiles: ti's new solution for storing large objects (LOBs) and
    datatypes such as XML
  &lt;/li&gt;
  &lt;li&gt;
    Automatic compilation for PL/SQL and Java in the database: new “native”
    compilation of PL/SQL that do not need C compiler.&lt;br/&gt;
  &lt;/li&gt;
&lt;/ol&gt;
&lt;br/&gt;
New features that look interesting, and I want to play with them:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    Semantic Technologies: native support for Resource Description Framework
    (RDF) and Web Ontology Language (OWL) standards,
  &lt;/li&gt;
  &lt;li&gt;
    Oracle Spatial enhancements: Richer, more-interactive map application
    development
  &lt;/li&gt;
  &lt;li&gt;
    New partitioning capabilities:&lt;br/&gt;
    - Partitioning by parent/child references,&lt;br/&gt;
    - Partitioning by virtual columns,&lt;br/&gt;
    - More composite partitioning options, including range/range, list/range,
    list/hash, and list/list,&lt;br/&gt;
    - Interval partitioning, which allows you to automatically create new
    partitions based on intervals, such as every month or every day,&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    Oracle Flashback Data Archive: enables fast query access to old versions of
    the data.
  &lt;/li&gt;
  &lt;li&gt;
    Expanded support for standards, such as XML Query (XQuery) 1.0 and service-oriented architecture (SOA)
  &lt;/li&gt;
&lt;/ol&gt;
&lt;br/&gt;
I'm waiting for Oracle 11g to be available for download...&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3101539675478694229?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3101539675478694229/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3101539675478694229' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3101539675478694229'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3101539675478694229'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/07/oracle-11g-announced-features-preview.html' title='Oracle 11g Announced: Features Preview'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2918682875399027996</id><published>2007-07-09T19:21:00.000+02:00</published><updated>2007-07-09T19:23:21.200+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='excel'/><category scheme='http://www.blogger.com/atom/ns#' term='sql plus'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Extracting Data to Excel using only SQL*Plus</title><content type='html'>Lately I had to quickly extract some data from Oracle DB to Excel. There are a
lot of tools that can do that, ex. Toad or SQL Developer, but I had only access
to SQL*Plus. Additionally I was on Windows machine and database was in UTF8. And
extracted data was also using many different languages.&lt;br/&gt;
Here are steps I used to archive my goal:&lt;br/&gt;
&lt;ol&gt;
  &lt;li&gt;
    start command line (CMD)
  &lt;/li&gt;
  &lt;li&gt;
    set NLS_LANG variable&lt;br/&gt;
    &lt;pre&gt;set NLS_LANG=.UTF8&lt;/pre&gt;
  &lt;/li&gt;
  &lt;li&gt;
    start sqlplus and log to database&lt;br/&gt;
    &lt;pre&gt;sqlplus user/pwd@db&lt;/pre&gt;
  &lt;/li&gt;
  &lt;li&gt;
    set long line size and avoid paging&lt;br/&gt;
    &lt;pre&gt;SQL&amp;gt; set linesize 4000&lt;br/&gt;SQL&amp;gt; set pagesize 0&lt;/pre&gt;
  &lt;/li&gt;
  &lt;li&gt;
    set markup html in sqlplus&lt;br/&gt;
    &lt;pre&gt;SQL&amp;gt; set markup html on spool on&lt;/pre&gt;
    &lt;br/&gt;
    It is important to use &lt;span style="FONT-WEIGHT:bold"&gt;spool on&lt;/span&gt;
    clause, as it adds html header to spool file when spooling is started
  &lt;/li&gt;
  &lt;li&gt;
    start spooling&lt;br/&gt;
    &lt;pre&gt;SQL&amp;amp;gt; spool a.html&lt;/pre&gt;
  &lt;/li&gt;
  &lt;li&gt;
    run your query&lt;br/&gt;
  &lt;/li&gt;
  &lt;li&gt;
    turn off spooling&lt;br/&gt;
    &lt;pre&gt;SQL&amp;amp;gt; spool off&lt;/pre&gt;
  &lt;/li&gt;
  &lt;li&gt;
    open file in Excel
  &lt;/li&gt;
&lt;/ol&gt;
I've tested this procedure on Oracle 10g R2 (10.2.0.1 and 10.2.0.3) and Excel
2003&lt;br/&gt;
&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2918682875399027996?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2918682875399027996/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2918682875399027996' title='10 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2918682875399027996'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2918682875399027996'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/07/extracting-data-to-excel-using-only.html' title='Extracting Data to Excel using only SQL*Plus'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>10</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8659090372483052751</id><published>2007-07-07T23:16:00.000+02:00</published><updated>2007-07-07T23:24:53.824+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='maps'/><category scheme='http://www.blogger.com/atom/ns#' term='picasa'/><category scheme='http://www.blogger.com/atom/ns#' term='photos'/><category scheme='http://www.blogger.com/atom/ns#' term='google'/><title type='text'>After Vacations: Tagging Photos with Geo Location</title><content type='html'>Welcome back after my vacations. This time nothing about Oracle, but about
  some idea that was in my mind for few years and now is life: Google Picasa has
  new functionality:
  &lt;a href="http://googleblog.blogspot.com/2007/06/put-your-photos-on-map-and-picasa-on.html" title="putting pictures on maps"&gt;putting
  pictures on maps&lt;/a&gt;. I'm using Picasa to share pictures with friends and
  family for more than year now. And often I was asked: where did you take this
  picture? Now I can tag pictures with Geo coordinates and then are shown on
  map. Take a look at
  &lt;a href="http://picasaweb.google.com/pawel.barut" title="my public galleries"&gt;my
  public galleries&lt;/a&gt; on picasa, especially latest one with some
  &lt;a href="http://picasaweb.google.com/pawel.barut/BuGariaCzerwiec2007" title="pictures from my vacations"&gt;pictures
  from my vacations&lt;/a&gt;.&lt;br/&gt;
  There are still some features that I would like to see;When playing with
  google maps I would like to have option to show pictures from specific place.
  Pictures from public galleries could be presented. There might be an copyright
  issue, but it could be solved easily: users will have option to allow (or not)
  to publish pictures this way.&lt;br/&gt;
And I must buy Camera with build in GPS receiver to simplify mapping pictures...
&lt;br/&gt;
&lt;a href="http://picasaweb.google.com/pawel.barut/BuGariaCzerwiec2007/photo#5084459906223063954"&gt;&lt;img src="http://lh4.google.com/pawel.barut/Ro-hWJkkQ5I/AAAAAAAACXc/LTeIrxrtYY8/s400/DSC_1909.JPG" /&gt;&lt;/a&gt;
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8659090372483052751?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8659090372483052751/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8659090372483052751' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8659090372483052751'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8659090372483052751'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/07/after-vacations-tagging-photos-with-geo.html' title='After Vacations: Tagging Photos with Geo Location'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5158635630237738678</id><published>2007-06-11T20:16:00.000+02:00</published><updated>2007-06-11T20:17:22.447+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sql plus'/><category scheme='http://www.blogger.com/atom/ns#' term='photos'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Dynamically set name of spool file in SQL*Plus</title><content type='html'>Small tip for today. Often there is a need  to set name of spool file based on current time and might by also database you are connected to. It's often needed when script is run as scheduled task and there is a need to generate files with different names. So here is an solution for using date:
&lt;pre&gt;define logname=date
column clogname new_value logname
select 'prefix_'||to_char(sysdate, 'yyyymmdd') clogname from dual;
spool '&amp;amp;logname'&lt;/pre&gt;
If there is a need to have also name of database included into filename then it can be read from global_name view:
&lt;pre&gt;define logname=date
column clogname new_value logname
select 'prefix_'||substr(global_name,1,
 decode(dot,0,length(global_name),dot-1))||
 to_char(sysdate, 'yyyymmdd') clogname
from (select global_name, instr(global_name, '.') dot from global_name);
spool '&amp;amp;logname'&lt;/pre&gt;
Hope you find it useful.&lt;br&gt;
I would also like to share an photo I made in Rome in February this year &lt;br&gt;&lt;img src="http://www.barut.info/gal/rzym3/rome_italy_61.jpg" width="600" alt="Rome, Colosseum, Feb 2007"/&gt;&lt;br/&gt;To see more pictures you are welcome to follow &lt;a href="http://www.barut.info/rome_07_01.php"&gt;Rome 1&lt;/a&gt;, &lt;a href="http://www.barut.info/rome_07_02.php"&gt;Rome 2&lt;/a&gt;, &lt;a href="http://www.barut.info/rome_07_03.php"&gt;Rome 3&lt;/a&gt;
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5158635630237738678?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5158635630237738678/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5158635630237738678' title='5 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5158635630237738678'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5158635630237738678'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/06/dynamically-set-name-of-spool-file-in.html' title='Dynamically set name of spool file in SQL*Plus'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>5</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6319827240691067797</id><published>2007-06-08T16:54:00.000+02:00</published><updated>2007-06-11T18:30:56.254+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><category scheme='http://www.blogger.com/atom/ns#' term='log buffer'/><title type='text'>Log Buffer #48</title><content type='html'>Welcome to 48 edition of
&lt;a href="http://www.pythian.com/blogs/about-log-buffer" title="Log Buffer"&gt;Log
Buffer&lt;/a&gt;. While I read Log Buffer regularly for many months already it's first
time I do review of databases blogosphere. Thanks to &lt;b&gt;Dave Edwards&lt;/b&gt; from
&lt;a href="http://www.pythian.com/" title="Pythian"&gt;Pythian&lt;/a&gt; for inviting me.&lt;br/&gt;
&lt;br/&gt;
This edition will be mostly related to development tools, techniques and
environments for database applications. Let start with
&lt;a href="http://inside-apex.blogspot.com/" title="Inside Oracle APEX"&gt;Inside
Oracle APEX&lt;/a&gt; where &lt;b&gt;Patrick Wolf&lt;/b&gt; presents
&lt;a href="http://inside-apex.blogspot.com/2007/06/power-of-oracle-apex-repository.html" title="internals of APEX Repository"&gt;internals
of APEX Repository&lt;/a&gt;. In turn
&lt;b&gt;&lt;a href="http://dgielis.blogspot.com/" title="Dimitri Gielis"&gt;Dimitri
Gielis&lt;/a&gt;&lt;/b&gt; is discussing how to
&lt;a href="http://dgielis.blogspot.com/2007/06/reuse-oracle-apex-components.html" title="reuse APEX components"&gt;reuse
Oracle APEX components&lt;/a&gt; effectively. If you still do not know what APEX is,
you can begin with
&lt;a href="http://www.bloggingaboutoracle.org/archives/oracle-application-express%e2%80%94what%e2%80%99s-it-all-about" title="Oracle Application Express—What’s it All About?"&gt;Oracle
Application Express—What’s it All About?&lt;/a&gt; by &lt;b&gt;Peter Lorenzen&lt;/b&gt;.&lt;br/&gt;
&lt;b&gt;&lt;br/&gt;
Jonathan Bruce&lt;/b&gt; at his
&lt;a href="http://jonathanbruceconnects.com/jonathan_bruce/" title="Weblog"&gt;Weblog&lt;/a&gt;
is reviewing and recommending
&lt;a href="http://jonathanbruceconnects.com/jonathan_bruce/2007/06/for_adonet_oracle_connectivity.html" title="DataDirect Connect  for ADO.NET Oracle"&gt;DataDirect
Connect for ADO.NET Oracle&lt;/a&gt; provider for Visual Studio.&lt;br/&gt;
&lt;b&gt; Anton Scheffer&lt;/b&gt; from
&lt;a href="http://technology.amis.nl/blog/" title="AMIS"&gt;AMIS&lt;/a&gt; is
&lt;a href="http://technology.amis.nl/blog/?p=2066" title="solving Sudoku with single SQL"&gt;solving
Sudoku with single SQL&lt;/a&gt; statement using MODEL Clause; really impressive
method, I must find time to experiment with MODEL clause as it seems to be very
powerful.&lt;br/&gt;
&lt;br/&gt;
Linear Algebra is not commonly known feature of Oracle database. &lt;b&gt;Marcos M.
Campos&lt;/b&gt; on
&lt;a href="http://oracledmt.blogspot.com/" title="Oracle Data Mining and Analytics"&gt;Oracle
Data Mining and Analytics&lt;/a&gt; is presenting how it can be used for
&lt;a href="http://oracledmt.blogspot.com/2007/06/way-cooler-pca-and-visualization-linear.html" title="Principal Components Analysis and Visualization"&gt;Principal
Components Analysis and Visualization&lt;/a&gt;. Unfortunately complexity of examples
rather will not help with wider usage of UTL_NLA package.&lt;br/&gt;
&lt;b&gt;&lt;br/&gt;
Jonathan Lewis&lt;/b&gt; on his
&lt;a href="http://jonathanlewis.wordpress.com/" title="Oracle Scratchpad"&gt;Oracle
Scratchpad&lt;/a&gt; presents differences in new (Oracle 10g) and old
&lt;a href="http://jonathanlewis.wordpress.com/2007/06/03/sorting/" title="sorting"&gt;sorting&lt;/a&gt;
algorithm. Difference is visible only for those who were using side effect of
sorting by ROWID in previous oracle releases.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;Jorrit Nijssen&lt;/b&gt; alias
&lt;a href="http://jornica.blogspot.com/" title="Jornica"&gt;Jornica&lt;/a&gt; issued an
warning on using
&lt;a href="http://jornica.blogspot.com/2007/05/returning-into-clause-and-post.html" title="after statement trigger and returning clause"&gt;after
statement trigger and returning clause&lt;/a&gt; together as there is an side effect.&lt;br/&gt;
&lt;br/&gt;
For many of Oracle DBAs it might be weird idea: &lt;b&gt;Kevin Closson&lt;/b&gt; is
proposing to install
&lt;a href="http://kevinclosson.wordpress.com/2007/06/05/oracle-over-nfs-i-need-more-monitoring-tools-a-bonded-nic-roller-coaster/" title="Oracle over NFS"&gt;Oracle
over NFS&lt;/a&gt;. He states that it's cheaper, simpler and will be even better with
upcoming Oracle 11g. By the way
&lt;a href="http://awads.net/wp/2007/06/06/oracle-database-11g-to-launch-on-july-11/" title="Oracle 11g will be launched on 11th"&gt;Oracle
11g will be launched on 11th of July&lt;/a&gt; according to &lt;b&gt;Eddie Awad&lt;/b&gt;. This
announcement made big rumour in Oracle blogosphere and &lt;b&gt;Lutz Hartmann&lt;/b&gt; is
now documenting new feature of
&lt;a href="http://sysdba.wordpress.com/2007/06/07/how-to-adjust-the-threshold-for-statistics-to-become-stale-in-oracle-11g/" title="collecting statistics in 11g"&gt;collecting
statistics in 11g&lt;/a&gt;.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;Laurent Schneider&lt;/b&gt; is discussing
&lt;a href="http://laurentschneider.com/wordpress/2007/06/column-qualification-best-practice.html" title="Best Practices for Aliasing columns"&gt;Best
Practices for Aliasing columns&lt;/a&gt; in SQL queries. &lt;b&gt;Dominic Delmolino&lt;/b&gt; on
&lt;a href="http://www.oraclemusings.com/" title="Oracle Musigns"&gt;Oracle
Musigns&lt;/a&gt; suggest another method: uniquely
&lt;a href="http://www.oraclemusings.com/?p=64" title="name columns"&gt;name
columns&lt;/a&gt;. Also &lt;b&gt;Steven Feuerstein&lt;/b&gt; on Toad World shows good practice:
"&lt;a href="http://www.toadworld.com/Community/ExpertsBlog/tabid/67/EntryID/88/Default.aspx" title="Don't put COMMIT; in you code!"&gt;Don't
put COMMIT; in you code!&lt;/a&gt;".&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;&lt;a href="http://kevinclosson.wordpress.com/2007/06/06/blogging-er-uh-bashing-oracle-for-fun-not-profit-got-cheezburger/" title="Kevin Closson"&gt;Kevin
Closson&lt;/a&gt;&lt;/b&gt; and
&lt;b&gt;&lt;a href="http://oracledoug.com/serendipity/index.php?/archives/1280-blogs.oracle.com,-Oracle-Ace,-OTN,-does-any-of-it-matter.html" title="Doug Burns"&gt;Doug
Burns&lt;/a&gt;&lt;/b&gt; discuses what is the role of Oracle, OTN, Technorati and readers
for bloggers community.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;Jeff&lt;/b&gt; of his
&lt;a href="http://weblogs.sqlteam.com/jeffs/Default.aspx" title="Jeff' SQL Server Weblog"&gt;Jeff'
SQL Server Weblog&lt;/a&gt; that
&lt;a href="http://weblogs.sqlteam.com/jeffs/archive/2007/06/05/60223.aspx" title="Database Design should not be made based on desired output"&gt;database
design should not be made due to desired output&lt;/a&gt;. "&lt;i&gt;We often see bad
designs submitted at SQLTeam.com with the justification of that design being the
client wanted it that way! ... you need to demonstrate to them that even when
storing the data properly, we can *still* create a View which returns those
exact results, making them happy&lt;/i&gt;".&lt;br/&gt;
&lt;br/&gt;
&lt;a href="http://datageekgal.blogspot.com/2007/06/data-quality-where-to-validate.html" title="Data Quality: Where to Validate?"&gt;Data
Quality: Where to Validate?&lt;/a&gt; &lt;b&gt;Beth&lt;/b&gt; on
&lt;a href="http://datageekgal.blogspot.com/" title="Confessions of a database geek"&gt;Confessions
of a database geek&lt;/a&gt; is reviewing levels where validation should occur also
giving some recommendations.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;Roland Bouman&lt;/b&gt; shows
&lt;a href="http://www.oreillynet.com/databases/blog/2007/06/what_mysql_can_do_to_enter_the.html" title="What MySQL can do to enter the off-line Web"&gt;What
MySQL can do to enter the off-line Web&lt;/a&gt;. In my opinion the idea of using Web
applications offline will be very hot in nearest future.&lt;br/&gt;
&lt;b&gt;Peter Zaitsev&lt;/b&gt; is discussing an issue with degraded
&lt;a href="http://www.mysqlperformanceblog.com/2007/06/06/mysql-4-to-mysql-5-upgrade-performance-regressions/" title="performance after upgrading MySQL 4 to MySQL 5"&gt;performance
after upgrading MySQL 4 to MySQL 5&lt;/a&gt;. He also presents some workaround for
that problem.&lt;br/&gt;
&lt;b&gt;Paul McCullagh&lt;/b&gt; on
&lt;a href="http://pbxt.blogspot.com/" title="PrimeBase XT"&gt;PrimeBase XT&lt;/a&gt; shows
how to manipulate
&lt;a href="http://pbxt.blogspot.com/2007/06/geting-blob-out-of-database-with-blob.html" title="BLOB in MySAL using BLOB Streaming Engine"&gt;BLOBs
in MySQL using BLOB Streaming Engine&lt;/a&gt;.&lt;br/&gt;
&lt;b&gt;Ronald Bradford&lt;/b&gt; on
&lt;a href="http://blog.arabx.com.au/" title="Technical Notes and Articles of Interest"&gt;Technical
Notes and Articles of Interest&lt;/a&gt; reviews
&lt;a href="http://blog.arabx.com.au/?p=718" title="Clustering solution for MySQL"&gt;Clustering
solution for MySQL&lt;/a&gt; database.&lt;br/&gt;
&lt;b&gt;Kevin Burton&lt;/b&gt; is predicting
&lt;a href="http://feedblog.org/2007/06/06/mysql-and-the-the-death-of-raid/" title="end of RAIDs"&gt;end
of RAIDs&lt;/a&gt; . Instead he proposes to use many instances of MySQL with
replication mechanism.&lt;br/&gt;
&lt;b&gt;&lt;a href="http://www.xaprb.com/blog/" title="Xaprb"&gt;Xaprb&lt;/a&gt;&lt;/b&gt; announced
release of
&lt;a href="http://www.xaprb.com/blog/2007/06/06/mysql-archiver-091-released/" title="MySQL Archiver 0.9.1 tool"&gt;MySQL
Archiver 0.9.1 tool&lt;/a&gt; to archive content of critical OLTP tables.&lt;br/&gt;
&lt;b&gt;&lt;br/&gt;
JonC&lt;/b&gt; is answering most common
&lt;a href="http://www.cybersite.com.au/node/107" title="Security Questions Applied to MySQL"&gt;Security
Questions Applied to MySQL&lt;/a&gt; and pointing that biggest challenge is to deal
with human errors. &lt;b&gt;Alex Kornbrust&lt;/b&gt; is presenting
&lt;a href="http://blog.red-database-security.com/2007/06/04/oracle-password-sniffer-thc-orakel/" title="THC Orakel new tooll to Sniffer Oracle Passwords"&gt;THC
Orakel new tool to Sniffer Oracle Passwords&lt;/a&gt;. He also points few errors in
white-paper that is accompanying the tool.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;Mark Rittman&lt;/b&gt; is on vacations leaving us with lot of
&lt;a href="http://www.rittmanmead.com/2007/06/03/bi-articles-and-links/" title="BI Articles and Links"&gt;BI
Articles and Links&lt;/a&gt; to read.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt; Steve Jones&lt;/b&gt; on
&lt;a href="http://blogs.sqlservercentral.com/blogs/" title="SQL Musings"&gt;SQL
Musings&lt;/a&gt; talks over
&lt;a href="http://blogs.sqlservercentral.com/blogs/steve_jones/archive/2007/06/05/1756.aspx" title="High Avaliability of SQL Server"&gt;High
Availability of SQL Server&lt;/a&gt;.
&lt;b&gt;&lt;a href="http://blogs.msdn.com/euanga/default.aspx" title="Euan Garden"&gt;Euan
Garden&lt;/a&gt;&lt;/b&gt; on his blog announces interesting
&lt;a href="http://blogs.msdn.com/euanga/archive/2007/06/04/sql-server-2008-web-casts.aspx" title="Web Casts about new features of SQL Server 2008"&gt;Web
Casts about new features of SQL Server 2008&lt;/a&gt;. While &lt;b&gt;Jamie Thomson&lt;/b&gt; show
how
&lt;a href="http://blogs.conchango.com/jamiethomson/archive/2007/06/04/Katmai_3A00_-T_2D00_SQL-Grouping-sets.aspx" title="Group by Grouping sets"&gt;Group
by Grouping Sets&lt;/a&gt; will work in Katmai: SQL Sever 2008.&lt;br/&gt;
&lt;br/&gt;
&lt;b&gt;&lt;a href="http://www.ittoolbox.com/profiles/josh_berkus" title="Josh Berkus"&gt;Josh
Berkus&lt;/a&gt;&lt;/b&gt; is reporting on
&lt;a href="http://blogs.ittoolbox.com/database/soup/archives/jpug-2007-report-16736" title="JPUG 2007 PostgreSQL Conference"&gt;JPUG
2007 PostgreSQL Conference&lt;/a&gt; and his keynote on "PostgreSQL Today and
Tomorrow". "&lt;i&gt;This was the most challenging conference for me so far since the
entire conference was in Japanese, a language of which I have no
comprehension&lt;/i&gt;."&lt;br/&gt;
&lt;br/&gt;
At the and some news from my country. &lt;b&gt;Jakub Pawlowski&lt;/b&gt; is summarizing
&lt;a href="http://kuba.zilp.pl/?id=141" title="XV PLOUG (Polish Oracle Users Group) Seminary"&gt;XV
PLOUG (Polish Oracle Users Group) Seminary&lt;/a&gt; - "Oracle Application Server 10g
R3: applications, productivity, security, reliability."&lt;br/&gt;
That's all for today. Wait for next Log Buffer on June 15th presented by
&lt;b&gt;&lt;a href="http://coskan.wordpress.com/" title="Coskan Gundogar’s"&gt;Coskan
Gundogar&lt;/a&gt;&lt;/b&gt;.&lt;br/&gt;
&lt;br/&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6319827240691067797?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6319827240691067797/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6319827240691067797' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6319827240691067797'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6319827240691067797'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/06/log-buffer-48.html' title='Log Buffer #48'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6041107722626609676</id><published>2007-06-04T23:50:00.000+02:00</published><updated>2007-06-05T08:31:25.203+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Rows to single string or aggregating strings</title><content type='html'>In oracle there is no build-in group function that will concatenate strings,  just like max summarizes all numbers. But there is quite easy way to do that in pure SQL. Assume we want to have get as an query result list of tables and column. But we want all columns to be concatenated and comma separated. Result should look 

&lt;table border='1' width='95%' align='center' summary='Script output'&gt;
&lt;tr&gt;
&lt;th scope="col" width="15%"&gt;
TABLE_NAME
&lt;/th&gt;
&lt;th scope="col"&gt;
COLUMN_LIST
&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_LABELS
&lt;/td&gt;
&lt;td&gt;
BLL_BLG_ID, BLL_LABEL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_COMMENTS
&lt;/td&gt;
&lt;td&gt;
BLC_BLG_ID, BLC_IDENTIFIER, BLC_PUBLISHED_TEXT, BLC_PUBLISHED, BLC_UPDATED_TEXT, BLC_UPDATED, BLC_CONTENT, BLC_URL, BLC_AUTHOR, BLC_AUTHOR_URI
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_POSTS
&lt;/td&gt;
&lt;td&gt;
BLG_ID, BLG_IDENTIFIER, BLG_TITLE, BLG_PUBLISHED_TEXT, BLG_PUBLISHED, BLG_UPDATED_TEXT, BLG_UPDATED, BLG_CONTENT, BLG_URL, BLG_BGH_ID, BLG_ENTRY
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOGS
&lt;/td&gt;
&lt;td&gt;
BGH_ID, BGH_NAME, BGH_FEED_URL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
FEED_CACHE
&lt;/td&gt;
&lt;td&gt;
CCH_URL, CCH_TIME, CCH_VALUE
&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;
Lets start with hierarchical query to build "tree" for each table. The only one branch of this tree will start with first column and end with last one. SYS_CONNECT_BY_PATH gives as option to track that branch:
&lt;pre&gt;SQL&amp;gt; select table_name, 
  2        SYS_CONNECT_BY_PATH(column_name,  ',') column_list
  3  from user_tab_columns
  4  start with column_id = 1
  5  connect by table_name = prior table_name
  6             and column_id = prior column_id +1
  7  ;
&lt;/pre&gt;
&lt;table border='1' width='95%' align='center' summary='Script output'&gt;
&lt;tr&gt;
&lt;th scope="col"&gt;
TABLE_NAME
&lt;/th&gt;
&lt;th scope="col"&gt;
COLUMN_LIST
&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOGS
&lt;/td&gt;
&lt;td&gt;
, BGH_ID
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOGS
&lt;/td&gt;
&lt;td&gt;
, BGH_ID, BGH_NAME
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOGS
&lt;/td&gt;
&lt;td&gt;
, BGH_ID, BGH_NAME, BGH_FEED_URL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
...
&lt;/td&gt;
&lt;td&gt;
...
&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;
Then I just take max path and truncating leading comma gives me expected result:

&lt;pre&gt;SQL&amp;gt; select table_name, 
  2        ltrim(max(SYS_CONNECT_BY_PATH(column_name,  ',')), ',') column_list
  3  from user_tab_columns
  4  start with column_id = 1
  5  connect by table_name = prior table_name
  6             and column_id = prior column_id +1
  7  group by table_name;
&lt;/pre&gt;
&lt;table border='1' width='95%' align='center' summary='Script output'&gt;
&lt;tr&gt;
&lt;th scope="col"&gt;
TABLE_NAME
&lt;/th&gt;
&lt;th scope="col"&gt;
COLUMN_LIST
&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_LABELS
&lt;/td&gt;
&lt;td&gt;
BLL_BLG_ID, BLL_LABEL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_COMMENTS
&lt;/td&gt;
&lt;td&gt;
BLC_BLG_ID, BLC_IDENTIFIER, BLC_PUBLISHED_TEXT, BLC_PUBLISHED, BLC_UPDATED_TEXT, 
BLC_UPDATED, BLC_CONTENT, BLC_URL, BLC_AUTHOR, BLC_AUTHOR_URI
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_POSTS
&lt;/td&gt;
&lt;td&gt;
BLG_ID, BLG_IDENTIFIER, BLG_TITLE, BLG_PUBLISHED_TEXT, BLG_PUBLISHED, 
BLG_UPDATED_TEXT, BLG_UPDATED, BLG_CONTENT, BLG_URL, BLG_BGH_ID, BLG_ENTRY
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOGS
&lt;/td&gt;
&lt;td&gt;
BGH_ID, BGH_NAME, BGH_FEED_URL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
FEED_CACHE
&lt;/td&gt;
&lt;td&gt;
CCH_URL, CCH_TIME, CCH_VALUE
&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;
Function Max works becouse if one string (ex.: "abc") is an prefix of the second one (ex: "abc123") than this second one is threated as bigger. I must warn that it might be not true for all NLS settings.
&lt;br&gt;
&lt;br&gt;
But what if we want columns to be ordered alphabetically? Than we have to use Row_Number function to calculate column position in table and make same changes to SQL:
&lt;pre&gt;SQL&amp;gt; select table_name, 
  2        ltrim(max(SYS_CONNECT_BY_PATH(column_name,  ',')), ',') column_list
  3  from (select table_name,  column_name,  ROW_NUMBER() OVER (partition by table_name ORDER BY column_name) AS curr  from user_tab_columns)
  4  start with curr = 1
  5  connect by table_name = prior table_name
  6             and curr = prior curr +1
  7  group by table_name;
&lt;/pre&gt;
&lt;table border='1' width='95%' align='center' summary='Script output'&gt;
&lt;tr&gt;
&lt;th scope="col"&gt;
TABLE_NAME
&lt;/th&gt;
&lt;th scope="col"&gt;
COLUMN_LIST
&lt;/th&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_LABELS
&lt;/td&gt;
&lt;td&gt;
BLL_BLG_ID, BLL_LABEL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_COMMENTS
&lt;/td&gt;
&lt;td&gt;
BLC_AUTHOR, BLC_AUTHOR_URI, BLC_BLG_ID, BLC_CONTENT, BLC_IDENTIFIER, BLC_PUBLISHED, 
BLC_PUBLISHED_TEXT, BLC_UPDATED, BLC_UPDATED_TEXT, BLC_URL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOG_POSTS
&lt;/td&gt;
&lt;td&gt;
BLG_BGH_ID, BLG_CONTENT, BLG_ENTRY, BLG_ID, BLG_IDENTIFIER, BLG_PUBLISHED, 
BLG_PUBLISHED_TEXT, BLG_TITLE, BLG_UPDATED, BLG_UPDATED_TEXT, BLG_URL
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
BLOGS
&lt;/td&gt;
&lt;td&gt;
BGH_FEED_URL, BGH_ID, BGH_NAME
&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;
FEED_CACHE
&lt;/td&gt;
&lt;td&gt;
CCH_TIME, CCH_URL, CCH_VALUE
&lt;/td&gt;
&lt;/tr&gt;
&lt;/table&gt;


Hope you will find it useful and fun.
&lt;br&gt;All samples where run on Oracle 10gR2 XE 10.2.0.1.
&lt;br&gt;Schema used in this sample is described in &lt;a href="http://pbarut.blogspot.com/2006/11/blogger-beta-backup-tool.html"&gt;Blogger Backup tool&lt;/a&gt; entry.
&lt;br&gt;&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6041107722626609676?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6041107722626609676/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6041107722626609676' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6041107722626609676'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6041107722626609676'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/06/rows-to-single-string-or-aggregating.html' title='Rows to single string or aggregating strings'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2026887472494130</id><published>2007-05-28T23:32:00.000+02:00</published><updated>2007-05-29T22:15:45.684+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='about'/><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle Blog Aggregators and Bloggers Community</title><content type='html'>Today I've noticed that my blog became aggregated on official &lt;a href="http://blogs.oracle.com/"&gt;Oracle Blogs&lt;/a&gt; site. For me it is really good news as it can bring me more readers. My blog is also aggregated at &lt;a href="http://orana.info/"&gt;OraNA.info&lt;/a&gt; by Eddie Awad (Oracle blogger of the year 2006) and on &lt;a href="http://www.orablogs.com/orablogs/"&gt;orablogs.com&lt;/a&gt; by Brian Duff (Oracle employee). Unfortunately I cannot find any of my post on &lt;a href="http://otnsemanticweb.oracle.com/"&gt;OTN Semantic Web&lt;/a&gt;. I hope it will change in near future, as this is still beta release...
&lt;br/&gt;For me it seems that latest discussions about Oracle Bloggers community have positive impact. Official list of Oracle blogs not maintained by Oracle employees is more complete now. Also &lt;a href="http://www.pythian.com/"&gt;The Pythian Group&lt;/a&gt; is doing great job for Oracle community by publishing series of &lt;a href="http://www.pythian.com/blogs/about-log-buffer"&gt;Log Buffer&lt;/a&gt;.

&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2026887472494130?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2026887472494130/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2026887472494130' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2026887472494130'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2026887472494130'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/05/oracle-blog-aggregators-and-bloggers.html' title='Oracle Blog Aggregators and Bloggers Community'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5490238235678279545</id><published>2007-05-28T23:14:00.000+02:00</published><updated>2007-05-28T23:18:22.996+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Solving ORA-22905: cannot access rows from a non-nested table item</title><content type='html'>Some time ago i wrote about &lt;a href="http://pbarut.blogspot.com/2006/10/binding-list-variable.html"&gt;Binding list variable&lt;/a&gt;. In fact it is conversion of string to rows. My example works fine in SQL but when used in PL/SQL it might cause error &lt;span style="font-weight:bold;"&gt;ORA-22905: cannot access rows from a non-nested table item&lt;/span&gt;. I do know what are the necessary conditions for this error, as it does not always happen in PL/SQL. I faced it usually for quite complicated queries. To overcome this problem I just cast binding variable to varchar2 as shown below:
&lt;pre&gt;  procedure test_proc(p_list in varchar2)
  is
  begin
    for r in (select items.extract('/l/text()').getStringVal() item
              from table(xmlSequence(
                extract(XMLType('&lt;all&gt;&lt;l&gt;'||
                  replace(&lt;b&gt;cast (p_list as varchar2(4000))&lt;/b&gt;,
                          ',','&lt;/l&gt;&lt;l&gt;')||'&lt;/l&gt;&lt;/all&gt;')
                      ,'/all/l'))) items) loop
      null;
    end loop;
  end;&lt;/pre&gt;
It worked for me in all situations where I faced ORA-22905 on Oracle 10gR2 (10.2.0.3)
&lt;br/&gt;&lt;br/&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5490238235678279545?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5490238235678279545/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5490238235678279545' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5490238235678279545'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5490238235678279545'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/05/solving-ora-22905-cannot-access-rows.html' title='Solving ORA-22905: cannot access rows from a non-nested table item'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3980298830497335300</id><published>2007-05-22T22:10:00.000+02:00</published><updated>2007-05-22T22:30:48.009+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><category scheme='http://www.blogger.com/atom/ns#' term='links'/><title type='text'>OraNA.info upgraded</title><content type='html'>&lt;a href="http://awads.net/wp/2007/05/22/infinite-scrolling-at-oranainfo-and-new-oracle-bloggers-group"&gt;Eddie Awad just announced&lt;/a&gt; that he has improved functionality of &lt;a href="http://orana.info/"&gt;Oracle Blogs aggregator OraNA.info&lt;/a&gt;. Now it shows post from long history, not only last 20. It is now really usable.&lt;br/&gt;
And if you are Oracle Blogger, go and join &lt;a href="http://groups.google.com/group/OraBloggers"&gt;OraBloggers group on Google groups&lt;/a&gt;.
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3980298830497335300?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3980298830497335300/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3980298830497335300' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3980298830497335300'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3980298830497335300'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/05/oranainfo-upgraded.html' title='OraNA.info upgraded'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-983919685226409987</id><published>2007-05-21T19:30:00.000+02:00</published><updated>2007-05-21T19:39:07.533+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='php'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Zend Core for Oracle v 2.0.1</title><content type='html'>Zend has announced new version of &lt;a href="http://www.zend.com/products/zend_core/zend_core_for_oracle"&gt;Zend Core for Oracle&lt;/a&gt;.

&lt;p&gt;Key features contained in all Zend Core V2.0 releases include:

&lt;ul&gt;&lt;li&gt;    Improved Windows Performance and Reliability – Up to 200-300%&lt;/li&gt;&lt;li&gt;    PHP 5.2.1 enhanced with several key security and bug fixes&lt;/li&gt;&lt;li&gt;    Unified "stack" installer - Bundled copies of Apache and MySQL for quick and easy install and configuration&lt;/li&gt;&lt;li&gt;    Bundled Zend Framework for fast and easy application development&lt;/li&gt;&lt;li&gt;    Universal Database Support - drivers provided for most popular databases.&lt;/li&gt;&lt;li&gt;    Mac OS X Support&lt;/li&gt;&lt;li&gt;    Zend Core Updater - Automatically download Zend Network updates&lt;/li&gt;&lt;/ul&gt;
&lt;/p&gt;Give it a try...&lt;br&gt;&lt;br&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-983919685226409987?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/983919685226409987/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=983919685226409987' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/983919685226409987'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/983919685226409987'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/05/zend-core-for-oracle-v-201.html' title='Zend Core for Oracle v 2.0.1'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-7379270035820459474</id><published>2007-05-20T12:19:00.000+02:00</published><updated>2007-05-20T12:26:07.746+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='dba'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Moving domain index to another tablespace</title><content type='html'>It seems to be very easy task that can be accomplished using rebuild option:
&lt;pre&gt;ALTER INDEX MY_INDEX REBUILD 
TABLESPACE NEW_TBS;&lt;/pre&gt;
We can even do it online for most indexes:
&lt;pre&gt;ALTER INDEX MY_INDEX REBUILD 
TABLESPACE NEW_TBS ONLINE;&lt;/pre&gt;
But trying this for domain index (ex. Spatial Index) causes error:
&lt;pre&gt;ALTER INDEX MY_GEOMETRY rebuild tablespace users;
ORA-29871: invalid alter option for a domain index&lt;/pre&gt;
What is the reson and how to overcome this? Domain index is in fact set of other objects. For spatial index it is table (MDRT_*). Spatial Index can be moved quite easy with
&lt;pre&gt;ALTER INDEX MY_GEOMETRY 
REBUILD PARAMETERS('TABLESPACE=NEW_TBS');&lt;/pre&gt;
Oracle Text CONTEXT index is set of tables:
&lt;ul&gt;&lt;li&gt;DR$[index_name]$I&lt;/li&gt;
&lt;li&gt;DR$[index_name]$K&lt;/li&gt;
&lt;li&gt;DR$[index_name]$N&lt;/li&gt;
&lt;li&gt;DR$[index_name]$R&lt;/li&gt;
&lt;/ul&gt;
Unfortunately to move context index you have to drop and recreate text index. But first storage parameters have to be defined:
&lt;pre&gt;begin
   ctx_ddl.create_preference('MY_TEXT_STORE', 'BASIC_STORAGE');
   ctx_ddl.set_attribute('MY_TEXT_STORE', 'I_TABLE_CLAUSE',
       'tablespace NEW_TBS');
   ctx_ddl.set_attribute('MY_TEXT_STORE', 'K_TABLE_CLAUSE',
       'tablespace NEW_TBS');
   ctx_ddl.set_attribute('MY_TEXT_STORE', 'R_TABLE_CLAUSE',
       'tablespace NEW_TBS');
   ctx_ddl.set_attribute('MY_TEXT_STORE', 'N_TABLE_CLAUSE',
       'tablespace NEW_TBS');
   ctx_ddl.set_attribute('MY_TEXT_STORE', 'I_INDEX_CLAUSE',
       'tablespace NEW_TBS COMPRESS 2');
   ctx_ddl.set_attribute('MY_TEXT_STORE', 'P_TABLE_CLAUSE',
       'tablespace NEW_TBS');
end;
/&lt;/pre&gt;and then just drop and create index with changed parameters
&lt;pre&gt;create index MY_TEXT_I on MY_TAB(text_column) 
indextype is ctxsys.context parameters(
'storage MY_TEXT_STORE');
&lt;/pre&gt;
For more information go to &lt;a href="http://download-uk.oracle.com/docs/cd/B19306_01/text.102/b14217/toc.htm"&gt;Oracle Text Application Developer's Guide&lt;/a&gt;
&lt;br&gt;&lt;br&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-7379270035820459474?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/7379270035820459474/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=7379270035820459474' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7379270035820459474'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7379270035820459474'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/05/moving-domain-index-to-another.html' title='Moving domain index to another tablespace'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6024760112952806472</id><published>2007-04-19T00:05:00.000+02:00</published><updated>2007-04-19T00:07:01.318+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='rman'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>RMAN TIP: Avoiding ORA-27211</title><content type='html'>I'm using RMAN to backup only to disk. Usualy when I have to delete obsolete backup I run command:
&lt;pre&gt;delete obsolete device type disk;&lt;/pre&gt;
It is anoying to type &lt;b&gt;device type disk&lt;/b&gt; every time, but 
&lt;pre&gt;delete obsolete;&lt;/pre&gt; causes:
&lt;pre&gt;RMAN-03002: failure of delete command at 09/12/2005 08:44:27
ORA-19554: error allocating device, device type: SBT_TAPE, device name:
ORA-27211: Failed to load Media Management Library&lt;/pre&gt;
The reason is that some time ago I was testing backups to tape. There is simple solution:
&lt;pre&gt;Configure CHANNEL device type 'SBT_TAPE' clear;&lt;/pre&gt;
It will remove information about tape device configuration, so all commands will use default device: disk.
&lt;br&gt;&lt;br&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6024760112952806472?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6024760112952806472/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6024760112952806472' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6024760112952806472'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6024760112952806472'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/04/rman-tip-avoiding-ora-27211.html' title='RMAN TIP: Avoiding ORA-27211'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5258894067095592402</id><published>2007-04-18T13:16:00.000+02:00</published><updated>2007-04-18T13:33:58.644+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='patch'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>CPUApr2007 and Interim patch 3 for 10.2.0.3 on Windows</title><content type='html'>On Monday I've downloaded Interim patch 3 (5916257) for 10.2.0.3 on Windows released on 13th April. Today I've downloaded CPUApr2007 (5948242) alias Interim patch 4. I've compared content of these patch and majority of files are &lt;span style="font-weight:bold;"&gt;identical&lt;/span&gt;.  Most changes are in patch description files. The only important file that has some changes is &lt;span style="font-style:italic;"&gt;oracle.exe&lt;/span&gt; while all other &lt;span style="font-style:italic;"&gt;*.dll&lt;/span&gt; files are identical. Also scripts to apply do database &lt;span style="font-style:italic;"&gt;catcpu.sql&lt;/span&gt; differs only by 2 lines.
&lt;br&gt;Interim patch 3:
&lt;pre&gt;DEFINE CPU_NUMBER  = 5916257
DEFINE CPU_DESC    = 'Patch3'&lt;/pre&gt;
&lt;br&gt;CPUApr2007:
&lt;pre&gt;DEFINE CPU_NUMBER  = 5948242
DEFINE CPU_DESC    = 'CPUApr2007'&lt;/pre&gt;
I wonder why Oracle published 2 patches just in 4 days? On Windows all interim patches contain also previous interim patch. For me the only explanation is that they didn't what to include other bug description into CPU. What do you think?
&lt;br&gt;&lt;br&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5258894067095592402?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5258894067095592402/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5258894067095592402' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5258894067095592402'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5258894067095592402'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/04/cpuapr2007-and-interim-patch-3-for.html' title='CPUApr2007 and Interim patch 3 for 10.2.0.3 on Windows'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-9072561178250267745</id><published>2007-04-06T19:16:00.000+02:00</published><updated>2007-04-06T19:22:12.504+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='efficiency'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle: Cursors, Bind Variables and Performance</title><content type='html'>I've found today very good document on &lt;a href="http://www.miracleas.dk/tools/Miracle_2_cursor.pdf"&gt;Efficient use of bind variables, cursor_sharing and related cursor parameters&lt;/a&gt; dated 2002. Document is related to Oracle 9i, but also applies to Oracle 10g.
&lt;br/&gt;&lt;br/&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-9072561178250267745?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/9072561178250267745/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=9072561178250267745' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9072561178250267745'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9072561178250267745'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/04/oracle-cursors-bind-variables-and.html' title='Oracle: Cursors, Bind Variables and Performance'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2994906976018649346</id><published>2007-03-28T23:05:00.000+02:00</published><updated>2008-12-10T23:58:16.907+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Monitor progress of long running processes</title><content type='html'>This time I want to share how I use v$session_longops to monitor Oracle long running queries but also how to create your own entries in this view. When monitoring long lasting operation I'm interested what is running now, and what was finished lately. For this purposes I use query:
&lt;pre&gt;SELECT sid,
  serial#,
  opname,
  target_desc,
  percent,
  sofar,
  totalwork,
  to_char(start_time,   'hh24:mi:ss') start_time,
  to_char(efin,   'hh24:mi:ss') estimate_fin,
  case when sofar &lt;&gt; totalwork and last_update_time &lt; sysdate-1/10000 then '*' else null end broken
FROM
  (SELECT sid,
     serial#,
     opname,
     target_desc,
     sofar,
     totalwork,
     to_char(CASE
             WHEN totalwork = 0 THEN 1
             ELSE sofar / totalwork
             END *100,    '990') percent,
     start_time,
     last_update_time,
     start_time +((elapsed_seconds + time_remaining) / 86400) efin
   FROM v$session_longops
   ORDER BY  CASE
             WHEN sofar = totalwork 
                THEN 1
                ELSE 0 END,
          efin DESC)
WHERE sofar &lt;&gt; totalwork or rownum &lt;= 20;&lt;/pre&gt;
It lists all currently running operations and up to twenty lately finished. The most important columns are &lt;b&gt;estimate_finish&lt;/b&gt; – it predicts time of process end, and &lt;b&gt;broken&lt;/b&gt; – if contains star (*) it is very possible that process was terminated or hung. Constant  1/10000 (about 8 seconds) in comparison  &lt;pre&gt;efin &lt; sysdate-1/10000&lt;/pre&gt; is to avoid false alerts. If single step of yours process takes more then 8 seconds than you should alter this value to meet your needs. You can find more information on &lt;a href="http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14237/dynviews_2092.htm#REFRN30227"&gt;v$session_longops view in Oracle documentation&lt;/a&gt;.
&lt;br&gt;Sample output:
&lt;a onblur="try {parent.deselectBloggerImageGracefully();} catch(e) {}" href="http://3.bp.blogspot.com/_6xECfZb_CD0/RgrZZQIlPAI/AAAAAAAAA_s/AQSDoz0EsXA/s1600-h/longops.gif"&gt;&lt;img style="cursor:pointer; cursor:hand;" src="http://3.bp.blogspot.com/_6xECfZb_CD0/RgrZZQIlPAI/AAAAAAAAA_s/AQSDoz0EsXA/s320/longops.gif" border="0" alt=""id="BLOGGER_PHOTO_ID_5047085360272980994" /&gt;&lt;/a&gt;
&lt;br&gt;&lt;br&gt;
Lets take a look how to write your own entries to long operations view. As a samle I'll just use simple loop that for each record in ALL_OBJECTS process will sleep for 0.1 second:
&lt;pre&gt;declare
  v_rindex pls_integer;
  v_slno   pls_integer;
begin
  v_rindex := dbms_application_info.set_session_longops_nohint;
  for r_qry in (select t.*, rownum rn, count(*) over () cnt 
                  from ALL_OBJECTS t ) loop
    dbms_application_info.set_session_longops
      ( rindex =&gt;  v_rindex,
        slno   =&gt;  v_slno,
        op_name =&gt; 'ALL_OBJECTS processing',
        target  =&gt;  0,
        target_desc =&gt; 'ALL_OBJECTS',
        context     =&gt; 0,
        sofar       =&gt; r_qry.rn,
        totalwork   =&gt; r_qry.cnt,
        units       =&gt; 'loops'
      );
    dbms_lock.sleep(0.1);
  end loop;
end;&lt;/pre&gt;
So what is important here:
&lt;ul&gt;&lt;li&gt;rindex – for first call it must be ste to dbms_application_info.set_session_longops_nohint – it means add new row to v$session_longops view&lt;/li&gt;
&lt;li&gt;rownum is used to get row number; it is passed to sofar parameter&lt;/li&gt;
&lt;li&gt;analytical function (count(*) over () cnt) is used to calculate all rows (steps) in that process; it is passed to totalwork parameter&lt;/li&gt;
&lt;li&gt;rindex, slno – should be assigned always to the same variable; it is needed to pass information about row that should be changed&lt;/li&gt;&lt;/ul&gt;
Additionaly you can add when others handler to set progress to 100%, but you do have to do that. Broken flag described above should work fine, and you know if process ended normally or with errors.
Full specification of &lt;a href="http://download-uk.oracle.com/docs/cd/B19306_01/appdev.102/b14258/d_appinf.htm#sthref503"&gt;dbms_application_info.set_session_longops&lt;/a&gt;
&lt;br&gt;&lt;br&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2994906976018649346?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2994906976018649346/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2994906976018649346' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2994906976018649346'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2994906976018649346'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/monitor-progress-of-long-running.html' title='Monitor progress of long running processes'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><media:thumbnail xmlns:media='http://search.yahoo.com/mrss/' url='http://3.bp.blogspot.com/_6xECfZb_CD0/RgrZZQIlPAI/AAAAAAAAA_s/AQSDoz0EsXA/s72-c/longops.gif' height='72' width='72'/><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8580852866641166320</id><published>2007-03-22T23:45:00.000+01:00</published><updated>2007-03-23T00:09:14.152+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='flashback'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Table that cannot be deleted</title><content type='html'>Today I run into interesting situation on one of development machines. I was drooping all tables of one user and after that there was still one table with name SYS_IOT_OVER_54321. Seeing that name I've concluded that it must be an overflow table for some Index Organized Table. But there were no other table in that schema. Of course I was not able to delete it. 
&lt;br&gt;Than I've realized that there are some tables in recycle bin. This situation is inconsistent as table is in recycle bin but its overflow area is still in normal table list. 
&lt;p&gt;Here is test case:
&lt;pre&gt;SQL&gt; create table IOT_TEST
  2  (a_pk number not null primary key
  3  ,a_number number
  4  ,big_string varchar2(4000)
  5  ) organization index
  6  including a_number overflow tablespace users;

Table created.

SQL&gt; select table_name, iot_name
  2  from user_tables where table_name like '%IOT%';

TABLE_NAME                     IOT_NAME                                         
------------------------------ ------------------------------                   
SYS_IOT_OVER_14580             IOT_TEST                                         
IOT_TEST                                                                        &lt;/pre&gt;
So lets drop it and see what will happen:
&lt;pre&gt;SQL&gt; drop table IOT_TEST;

Table dropped.

SQL&gt; select table_name, iot_name
  2  from user_tables where table_name like '%IOT%';

TABLE_NAME                     IOT_NAME                                         
------------------------------ ------------------------------                   
SYS_IOT_OVER_14580             BIN$rKpJH0NuROKt+Woa00+hMg==$0                   &lt;/pre&gt;
As you can see we still have IOT Overflow table that cannot be deleted:
&lt;pre&gt;SQL&gt; drop table SYS_IOT_OVER_14580;
drop table SYS_IOT_OVER_14580
           *
ERROR at line 1:
ORA-25191: cannot reference overflow table of an index-organized table&lt;/pre&gt;
The only way to get rid of that table is to purge recycle bin:
&lt;pre&gt;SQL&gt; purge recyclebin;

Recyclebin purged.

SQL&gt; select table_name, iot_name
  2  from user_tables where table_name like '%IOT%';

no rows selected&lt;/pre&gt;
In my opinion it is bug. I haven't yet reported it on metalink, but I'll fill SR soon. I've confirmed it on Oracle 10g R2 (versions: XE, 10.2.0.1,  10.2.0.2,  10.2.0.3)
&lt;/p&gt;&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8580852866641166320?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8580852866641166320/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8580852866641166320' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8580852866641166320'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8580852866641166320'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/table-that-cannot-be-deleted.html' title='Table that cannot be deleted'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2567463081088518898</id><published>2007-03-16T00:05:00.000+01:00</published><updated>2007-03-16T00:04:05.429+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='piracy'/><category scheme='http://www.blogger.com/atom/ns#' term='microsoft'/><title type='text'>„Do not use Linux, please, pirate our software” - Microsoft</title><content type='html'>It seems that Microsoft wants You to pirate it's software. According to &lt;a href="http://www.theregister.co.uk/2007/03/13/ms_piracy_benefits/"&gt;The Register&lt;/a&gt;, Jeff Raikes, Microsoft business group president, said that if You have to pirate, You should pirate Microsoft software. The idea behind it is that some percentage of pirates become paying customers.

Microsoft wants You to:
&lt;ul&gt;&lt;li&gt;pay and use MS software,
&lt;li&gt;use MS software not paying for it; might be in future you will pay,
&lt;li&gt;not use other software. Microsoft does not want You to switch to competing software, especially legal royalty-free FLOSS software such as Linux, OpenOffice.org or Mozilla.org
&lt;/ul&gt;
So why they implemented Windows Genuine Advantage Programme, if they do not want to push You to be legal?



Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2567463081088518898?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2567463081088518898/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2567463081088518898' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2567463081088518898'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2567463081088518898'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/do-not-use-linux-please-pirate-our.html' title='„Do not use Linux, please, pirate our software” - Microsoft'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-7986172078286766595</id><published>2007-03-15T21:28:00.000+01:00</published><updated>2007-03-15T21:29:20.969+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>Polish Students won ACM Programming Contest</title><content type='html'>Today students from &lt;a href="http://www.mimuw.edu.pl/english/"&gt;Warsaw University&lt;/a&gt; won &lt;a href="http://icpc.baylor.edu/icpc/"&gt;ACM-International Collegiate Programming Contest&lt;/a&gt;.  They solved 8 tasks out of 10, see &lt;a href="http://icpc.baylor.edu/icpc/Finals/scoreboard/Final/"&gt;Final results&lt;/a&gt;.
&lt;br&gt;&lt;br&gt;Congratulations to my compatriot,
&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-7986172078286766595?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/7986172078286766595/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=7986172078286766595' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7986172078286766595'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7986172078286766595'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/polish-students-won-acm-programming.html' title='Polish Students won ACM Programming Contest'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6077633448848974589</id><published>2007-03-07T18:13:00.000+01:00</published><updated>2007-03-07T18:30:57.323+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Moving/Adding Control file when using SPFile</title><content type='html'>Adding controlfile or moving to new location is tricky when your database was started with server parameter file (spfile). It is because You cannot edit spfile when database is not running.
&lt;br&gt;Method 1 – preferred by me:
&lt;ol&gt;&lt;li&gt;alter system parameter to point to new (planed) location of controlfiles
&lt;pre&gt;alter system set control_files
= '/dir1/CONTROL01.CTL'
, '/dir2/CONTROL02.CTL'
, '/dir3/CONTROL03.CTL'
scope=spfile;&lt;/pre&gt;
&lt;/li&gt;&lt;li&gt;shutdown database,&lt;/li&gt;&lt;li&gt;copy one of controlfile to new locations,&lt;/li&gt;&lt;li&gt;startup database.&lt;/li&gt;&lt;/ol&gt;Method 2:
&lt;ol&gt;&lt;li&gt;shutdown database,
&lt;/li&gt;&lt;li&gt;copy one of controlfile to new locations,
&lt;/li&gt;&lt;li&gt;copy spfile to pfile:
&lt;pre&gt;create pfile from spfile;&lt;/pre&gt;
&lt;/li&gt;&lt;li&gt;manually edit pfile,
&lt;/li&gt;&lt;li&gt;copy pfile back to spfile:
&lt;pre&gt;create spfile from pfile;&lt;/pre&gt;
&lt;/li&gt;&lt;li&gt;startup database.&lt;/li&gt;&lt;/ol&gt;

Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6077633448848974589?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6077633448848974589/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6077633448848974589' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6077633448848974589'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6077633448848974589'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/movingadding-control-file-when-using.html' title='Moving/Adding Control file when using SPFile'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2598132662464234084</id><published>2007-03-06T22:22:00.000+01:00</published><updated>2007-03-06T22:25:34.302+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='about'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>Technorati</title><content type='html'>I've just created my &lt;a href="http://technorati.com/claim/y8xg3ifnrq" rel="me"&gt;Technorati Profile&lt;/a&gt;, so this post is just to interrelate this blog with my Technorati account.
&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2598132662464234084?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2598132662464234084/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2598132662464234084' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2598132662464234084'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2598132662464234084'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/technorati.html' title='Technorati'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2224031108663825054</id><published>2007-03-05T19:57:00.000+01:00</published><updated>2007-03-05T21:18:18.312+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='php'/><title type='text'>the Month of PHP Bugs</title><content type='html'>For all PHP developers, web admins and users this might be very interesting. &lt;a href="http://www.php-security.org/"&gt;the Month of PHP Bugs&lt;/a&gt; is an initiative to improve the security of PHP. It focuses on PHP Core vulnerabilities that are dangerous for web servers with applications written in PHP. It is done in hope that flaws that are publicly disclosed will get fixed quickly.
&lt;br&gt;&lt;br&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2224031108663825054?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2224031108663825054/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2224031108663825054' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2224031108663825054'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2224031108663825054'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/month-of-php-bugs.html' title='the Month of PHP Bugs'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3003477257710135281</id><published>2007-03-03T22:54:00.000+01:00</published><updated>2007-03-03T22:55:03.146+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Yet another tokenizer in Oracle</title><content type='html'>I was in need to have function that transforms string into table of words. Also words can be separated by many different chars. For this purpose i've created function:
&lt;pre&gt;create or replace function tokenizer
  (p_string in varchar2
  ,p_separators in varchar2
  ) return dbms_sql.varchar2s
is
  v_strs dbms_sql.varchar2s;
begin
  with sel_string as 
      (select p_string fullstring 
         from dual)
  select substr(fullstring, beg+1, end_p-beg-1) token
   bulk collect into v_strs
   from (select beg, lead(beg) over (order by beg) end_p, fullstring
           from (select beg, fullstring
                   from (select level beg, fullstring
                           from sel_string
                         connect by level &lt;= length(fullstring))
                   where instr(p_separators ,substr(fullstring,beg,1)) &gt;0
                 union all
                 select 0, fullstring from sel_string
                 union all
                 select length(fullstring)+1, fullstring from sel_string))
    where end_p is not null
      and end_p&gt;beg+1;
  return v_strs;
end;&lt;/pre&gt;
Usage is very simple. First parameter is string that should be tokenized, second parameter is string with characters that should be treated as word separators. Example:
&lt;pre&gt;SQL&gt; set serveroutput on
SQL&gt; declare v_strs dbms_sql.varchar2s;
  2  begin
  3    v_strs := tokenizer('I was in need to have function that transforms string into table of words.'
  4        , ' ,:;.&lt;&gt;[]{}()');
  5    for i in v_strs.first..v_strs.last loop
  6      dbms_output.put_line(v_strs(i));
  7    end loop;
  8  end;
  9  /
I                                                                               
was                                                                             
in                                                                              
need                                                                            
to                                                                              
have                                                                            
function                                                                        
that                                                                            
transforms                                                                      
string                                                                          
into                                                                            
table                                                                           
of                                                                              
words                                                                           

PL/SQL procedure successfully completed.&lt;/pre&gt;
Let me explain some elements
&lt;pre&gt;  with sel_string as 
      (select p_string fullstring 
         from dual)&lt;/pre&gt;
is just to bind string parameter into SQL just once. Otherwise it will have to be binded in many places.
&lt;pre&gt;                 select beg, fullstring
                   from (select level beg, fullstring
                           from sel_string
                         connect by level &lt;= length(fullstring))
                   where instr(p_separators ,substr(fullstring,beg,1)) &gt;0&lt;/pre&gt;
Internal select generates numbers from 1 to length of string. Outer select chooses only these rows (numbers) that are separators in string.
&lt;pre&gt;                 union all
                 select 0, fullstring from sel_string
                 union all
                 select length(fullstring)+1, fullstring from sel_string))&lt;/pre&gt;
adds separator at beginning and end of string, so first and last work can be recognized.
&lt;pre&gt; select beg, lead(beg) over (order by beg) end_p&lt;/pre&gt;
gives as positions of two consecutive separators, and finally
&lt;pre&gt;  select substr(fullstring, beg+1, end_p-beg-1) token
   bulk collect into v_strs
   ...
    where end_p is not null
      and end_p&gt;beg+1;&lt;/pre&gt;
select words.
&lt;br&gt;
&lt;br&gt;Might be you find it useful,
&lt;br&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3003477257710135281?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3003477257710135281/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3003477257710135281' title='9 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3003477257710135281'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3003477257710135281'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/03/yet-another-tokenizer-in-oracle.html' title='Yet another tokenizer in Oracle'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>9</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1020254996120886239</id><published>2007-02-15T18:38:00.000+01:00</published><updated>2007-02-15T18:39:51.705+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='other'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Bug 5705795 - AMAZON-LIKE ?</title><content type='html'>&lt;p&gt;Today I've reviewed list of 10.2.0.3 patch 1 for Windows and i've noticed bug with name: 5705795 - MANY CHILD CURSORS CREATED FOR AMAZON-LIKE WORKLOAD IN 10.2.0.3. I was aware of this bug as it was mentioned in note 403616.1 on Metalink. I do not think it's good idea to use customer name in bug description. From this I can assume:&lt;/p&gt; &lt;ul&gt;&lt;li&gt;&lt;p&gt;Amazon is using  latest Oracle Database,&lt;/p&gt;  &lt;/li&gt;&lt;li&gt;&lt;p&gt;Amazon is running on  Linux or Windows (as this bug is only for these platforms),&lt;/p&gt;  &lt;/li&gt;&lt;li&gt;&lt;p&gt;probably Amazon is  using Linux as patch for linux was released  earlier,&lt;/p&gt;  &lt;/li&gt;&lt;li&gt;&lt;p&gt;it gives some inside  view of software design used at Amazon,&lt;/p&gt; &lt;/li&gt;&lt;/ul&gt; &lt;p&gt;I do not think Amazon is happy with these reveals.&lt;/p&gt; &lt;p&gt;At least bug 5705795 is not public on Metalink.&lt;/p&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1020254996120886239?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1020254996120886239/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1020254996120886239' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1020254996120886239'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1020254996120886239'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/02/bug-5705795-amazon-like.html' title='Bug 5705795 - AMAZON-LIKE ?'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-537963002852891246</id><published>2007-02-07T23:15:00.000+01:00</published><updated>2007-02-07T23:17:10.297+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Empty String IS NOT NULL?</title><content type='html'>Today friend of mine show me interesting case:
&lt;pre&gt;declare
  var varchar2(3);
  chr char(3);
begin
  &lt;b&gt;var := ''; -- Empty string here
  chr := var;&lt;/b&gt;
  if var is null then
    dbms_output.put_line('VAR IS NULL');
  end if;
  if chr is null then
    dbms_output.put_line('CHR IS NULL');
  else
    dbms_output.put_line('CHR IS NOT NULL');
  end if;
end;
/
&lt;b&gt;VAR IS NULL
CHR IS NOT NULL&lt;/b&gt;&lt;/pre&gt;
I must say that I was expecting that both variables will be null. It might be my lack of experience with CHAR datatype as I usually use VARCHAR2 even when it is expected that string will have constant length.
&lt;pre&gt;declare
  var varchar2(3);
  chr char(3);
begin
  &lt;b&gt;var := null;
  chr := var;&lt;/b&gt;
  if var is null then
    dbms_output.put_line('VAR IS NULL');
  end if;
  if chr is null then
    dbms_output.put_line('CHR IS NULL');
  else
    dbms_output.put_line('CHR IS NOT NULL');
  end if;
end;
/
&lt;b&gt;VAR IS NULL
CHR IS NULL&lt;/b&gt;&lt;/pre&gt;
Just as expected. So it seems that in some cases NULL and empty string is not equivalent. But this difference can be only seen in PL/SQL. When I tried to reproduce this in pure SQL it was always NULL:
&lt;pre&gt;SQL&gt; create table a(v1 varchar2(3), v2 varchar2(3), c1 char(3), c2 char(3));
Table created.
SQL&gt; insert into a values (&lt;b&gt;null, '', null, ''&lt;/b&gt;);
1 row created.
SQL&gt; select dump(v1) v1,dump(v2) v2,dump(c1)c1,dump(c2) c2 from a;
V1    V2    C1    C2
----- ----- ----- -----
NULL  NULL  &lt;b&gt;NULL  NULL&lt;/b&gt;
SQL&gt; update a set c1 = v1, c2 = v2;
1 row updated.
SQL&gt; select dump(v1) v1,dump(v2) v2,dump(c1)c1,dump(c2) c2 from a;
V1    V2    C1    C2
----- ----- ----- -----
NULL  NULL  &lt;b&gt;NULL  NULL&lt;/b&gt;&lt;/pre&gt;
&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-537963002852891246?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/537963002852891246/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=537963002852891246' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/537963002852891246'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/537963002852891246'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/02/empty-string-is-not-null.html' title='Empty String IS NOT NULL?'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1476684002415827164</id><published>2007-02-06T09:17:00.000+01:00</published><updated>2007-02-06T09:53:12.165+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>Interesting posts 2007-02-06</title><content type='html'>Here are some interesting posts I've read recently:
&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.softwarebyrob.com/archive/2007/02/04/User_Interface_Design_Complexity_versus_Flexibility.aspx"&gt;User Interface Design: Complexity vs. Flexibility&lt;/a&gt; - Rob Walling is traing to find aswer to question: can a design be simple and flexible at the same time?&lt;/li&gt;&lt;li&gt;&lt;a href="http://tkyte.blogspot.com/2007/02/how-to-scale.html"&gt;How to scale... &lt;/a&gt;Tom Kyte post about scalability of middleware and database. Do not forget to read Tim Hall response &lt;a href="http://www.oracle-base.com/blog/2007/02/02/middle-tier-diet/"&gt;Middle-tier diet…&lt;/a&gt;.
&lt;/li&gt;&lt;li&gt;&lt;a href="http://headrush.typepad.com/creating_passionate_users/2007/02/difference_betw.html"&gt;Difference between Jeff Bezos and Bill Gates?&lt;/a&gt; by Kathy Sierra - very interesting story about top CEO's attitude to users.
&lt;/li&gt;&lt;/ul&gt;
&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1476684002415827164?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1476684002415827164/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1476684002415827164' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1476684002415827164'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1476684002415827164'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/02/intresting-posts-2007-02-06.html' title='Interesting posts 2007-02-06'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-7182838522595012467</id><published>2007-02-01T22:43:00.000+01:00</published><updated>2007-02-01T22:46:24.584+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='rman'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Restore CONTROLFILE and/or SPFILE from autobackup</title><content type='html'>As I mentioned earlier in post about &lt;a href="http://pbarut.blogspot.com/2007/01/autobackup-of-spfile-and-controlfile.html"&gt;setting up autobackup&lt;/a&gt;, 
its time to describe how to restore CONTROLFILE and SPFILE from autobackups. 
If your &lt;b&gt;database is still running&lt;/b&gt; and what You want is just get historical version of SPFILE or CONTROLFILE then it is easy task. Just start RMAN:
&lt;pre&gt;RMAN TARGET=/&lt;/pre&gt;
And enter command to restore CONTROLFILE:
&lt;pre&gt;RMAN&gt; restore until time 'sysdate-3'
2&gt; CONTROLFILE to 'c:\temp\cfile' from autobackup;
Starting restore at 01-FEB-07
using channel ORA_DISK_1
recovery area destination: C:\oracle\product\10.2.0/flash_recovery_area
database name (or database unique name) used for search: BAR
channel ORA_DISK_1: no autobackups found in the recovery area
channel ORA_DISK_1: looking for autobackup on day: 20070129
channel ORA_DISK_1: autobackup found: C:\Backup\c-669001291-20070129-03
channel ORA_DISK_1: control file restore from autobackup complete
Finished restore at 01-FEB-07&lt;/pre&gt;
The until time clause sets time of validity for CONTROLFILE. By default RAM looks for autobackups for seven days into past starting from that time. It can happen that for several days there were no changes, and autobackup was not invoked. In that case add &lt;b&gt;MAXDAYS&lt;/b&gt; clause:
&lt;pre&gt;RMAN&gt; restore until time 'sysdate-3'
2&gt; CONTROLFILE to 'c:\temp\cfile' from autobackup maxdays 100;&lt;/pre&gt;
It will force RMAN to look for copies for more days into past.
Similarly You can restore SPFILE:
&lt;pre&gt;RMAN&gt; restore until time 'sysdate-3'
2&gt; SPFILE to 'c:\temp\SPFILE' from autobackup maxdays 100;
Starting restore at 01-FEB-07
using channel ORA_DISK_1
recovery area destination: C:\oracle\product\10.2.0/flash_recovery_area
database name (or database unique name) used for search: BAR
channel ORA_DISK_1: no autobackups found in the recovery area
channel ORA_DISK_1: looking for autobackup on day: 20070129
channel ORA_DISK_1: autobackup found: C:\Backup\c-669001291-20070129-03
channel ORA_DISK_1: SPFILE restore from autobackup complete
Finished restore at 01-FEB-07&lt;/pre&gt;
After restoring SPFILE You can convert it to PFILE, so You can easily read settings:
&lt;pre&gt;RMAN&gt; sql "create PFILE = ''c:\temp\PFILE'' from SPFILE = ''c:\temp\SPFILE''";
sql statement: create PFILE = ''c:\temp\PFILE'' from SPFILE = ''c:\temp\SPFILE''&lt;/pre&gt;

Now more complex scenario: &lt;b&gt;You have lost all database files including CONTROLFILE and SPFILE&lt;/b&gt;. 
You only have backups created by RMAN. In that case You have to eventually install Database Software. 
Then setup environment variables and start recovery. On Windows platform You have to create Service to be able to startup oracle. 
You probably remember instance name and SID. If You don't it can be usually found in some TNSNAMES files on client machines. 
But You probably do not know DBID. You can easily find DBID – it'is part of the name of autobackup file. 
Details in my &lt;a href="http://pbarut.blogspot.com/2007/01/autobackup-of-spfile-and-controlfile.html"&gt;previous post&lt;/a&gt;. 
So if autobackup file name is 'c-&lt;b&gt;669001291&lt;/b&gt;-20070129-03' then DBID is  &lt;b&gt;669001291&lt;/b&gt;. 
Now we can start recovery:
&lt;pre&gt;RMAN target=/&lt;/pre&gt;
At the beginning set Database ID:
&lt;pre&gt;RMAN&gt; SET DBID 669001291;&lt;/pre&gt;
Then startup instance:
&lt;pre&gt;RMAN&gt; startup force nomount;&lt;/pre&gt;
and run recovery of SPFILE
&lt;pre&gt;RMAN&gt; RUN {
2&gt; SET CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'C:\Backup\%F'; 
3&gt; RESTORE SPFILE FROM AUTOBACKUP; }&lt;/pre&gt;
I suggest also creating PFILE from SPFILE. Then You should check if all file locations are correct, 
all directories exists and Oracle have rights to write in them.
&lt;pre&gt;RMAN&gt; shutdown;
RMAN&gt; startup force nomount;
RMAN&gt; RUN { 
2&gt; SET CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'C:\Backup\%F'; 
3&gt; RESTORE CONTROLFILE FROM AUTOBACKUP; }&lt;/pre&gt;
Now You can continue recovery of datafiles.
&lt;br/&gt;&lt;br/&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-7182838522595012467?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/7182838522595012467/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=7182838522595012467' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7182838522595012467'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7182838522595012467'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/02/restore-controlfile-andor-spfile-from.html' title='Restore CONTROLFILE and/or SPFILE from autobackup'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2408406959741433850</id><published>2007-01-30T12:52:00.000+01:00</published><updated>2007-02-01T22:49:19.700+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='rman'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Autobackup of SPFILE and CONTROLFILE</title><content type='html'>Even if you do not use
RMAN to take backups of your database, you might find it useful to
take snapshots of your SPFILE and CONTROLFILE automatically. You can
configure Recovery Manager (RMAN) to automatically create copies of
CONTROLFILE and SPFILE when you make changes to database such as:
&lt;UL&gt;
 &lt;LI&gt;adding/dropping a new
 tablespace or datafile
 &lt;LI&gt;altering the state of
 a tablespace or datafile (online/offline/read only)
 &lt;LI&gt;adding a new online
 redo log, 
 
 &lt;LI&gt;renaming a file
 &lt;LI&gt;adding a new redo
 thread
 &lt;LI&gt;and many more...
&lt;/UL&gt;
To setup autobackup just start RMAN and connect to database
&lt;pre&gt;RMAN target=/&lt;/pre&gt;
or
&lt;pre&gt;RMAN target=sys/password@db&lt;/pre&gt;
set directory and format of backup files:
&lt;pre&gt;RMAN&amp;gt; CONFIGURE CONTROLFILE AUTOBACKUP FORMAT FOR DEVICE TYPE DISK TO 'C:\Backup\%F';&lt;/pre&gt;
In name of autbackup file you have to use %F. It will be expanded to C-XXXXXXXXX-YYYYMMDD-NN,
where:
&lt;UL&gt;
 &lt;LI&gt;XXXXXXXXX &amp;ndash;
 database id
 &lt;LI&gt;YYYYMMDD &amp;ndash; day,
 when backuped
 &lt;LI&gt;NN &amp;ndash; change
 number during day, starts with 00, and represented in hexadecimal
&lt;/UL&gt;
Activate autobackups:
&lt;pre&gt;RMAN&amp;gt; CONFIGURE CONTROLFILE AUTOBACKUP ON;&lt;/pre&gt;
Now autobackups are active, and every time you change database structure controlfile will
be automatically backed up.
&lt;br/&gt;
If you use RMAN for
backups it will create copy of SPFILE or CONTROLFILE also after each
backup operation.
&lt;br/&gt;
I've tested it on Oracle 10g (10.2) but it should work in Oracle since version 8i.
Next time i'll write how to restore SPFILE or CONTROLFILE from these backup.
&lt;br/&gt;
&lt;br/&gt;
Cheers, Paweł
&lt;br/&gt;
&lt;br/&gt;Update: 
&lt;a href="http://pbarut.blogspot.com/2007/02/restore-controlfile-andor-spfile-from.html"&gt;How to restore CONTROLFILE and SPFILE from RMAN autobackups&lt;/a&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2408406959741433850?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2408406959741433850/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2408406959741433850' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2408406959741433850'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2408406959741433850'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/01/autobackup-of-spfile-and-controlfile.html' title='Autobackup of SPFILE and CONTROLFILE'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4124268848377705006</id><published>2007-01-11T22:48:00.000+01:00</published><updated>2007-01-11T22:50:10.586+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle XMLType: exctractvalue vs. extract</title><content type='html'>I always thought that
&lt;b&gt;&lt;pre&gt;exctarctvalue(xml, '/Node')&lt;/pre&gt;&lt;/b&gt;
is equivalent to 
&lt;b&gt;&lt;pre&gt;xml.extract('/Node/text()').getstringval()&lt;/pre&gt;&lt;/b&gt;
Usually it is true, but in some cases it is not. When node contains special characters like &amp;amp;, &amp;gt;, &amp;lt; etc... then results are different. 
Let me give an example:
&lt;pre&gt;SQL&gt; set define off
SQL&gt; select aa.a.extract('Node/text()').getStringVal() extr
  2       , extractvalue(aa.a, 'Node') extractval
  3    from (select XMLRoot(
  4              XMLElement("Node", 'test &amp;amp; &amp;lt; and &amp;gt;'),
  5             VERSION '1.0') a from dual) aa;

EXTR
----------------------------------------
EXTRACTVAL
----------------------------------------
test &amp;amp;amp; &amp;amp;lt; and &amp;amp;gt;
test &amp;amp; &amp;lt; and &amp;gt;
&lt;/pre&gt;First look on documentation even confirms my expectations:
&lt;br/&gt;&amp;quot;&lt;i&gt;extractValue – This takes an XPath expression and returns the corresponding leaf
node. The XPath expression passed to extractValue should identify a single
attribute or an element that has precisely one text node child. The result is
returned in the appropriate SQL data type. Function extractValue is essentially
a shortcut for extract plus either getStringVal() or getNumberVal().&lt;/i&gt;&amp;quot;
&lt;br/&gt;&lt;a href="http://download-uk.oracle.com/docs/cd/B19306_01/appdev.102/b14259.pdf"&gt;XML DB Developer's Guide - b14259.pdf&lt;/a&gt; page 1-17.
&lt;p&gt;But there is small note on that:
&lt;br/&gt;&amp;quot;&lt;i&gt;Note: Function extractValue and XMLType method
getStringVal() differ in their treatment of entity encoding.
Function extractValue unescapes any encoded entities; method
getStringVal() returns the data with entity encoding intact.&lt;/i&gt;&amp;quot;
&lt;br/&gt;&lt;a href="http://download-uk.oracle.com/docs/cd/B19306_01/appdev.102/b14259.pdf"&gt;XML DB Developer's Guide - b14259.pdf&lt;/a&gt; page 4-10.
&lt;/p&gt;
&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4124268848377705006?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4124268848377705006/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4124268848377705006' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4124268848377705006'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4124268848377705006'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/01/oracle-xmltype-exctractvalue-vs-extract.html' title='Oracle XMLType: exctractvalue vs. extract'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6142191345005142998</id><published>2007-01-10T23:31:00.000+01:00</published><updated>2007-01-10T23:40:24.592+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='rman'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>RMAN connection to Catalog - updated</title><content type='html'>I must say that I was completely wrong in my post &lt;a href="http://pbarut.blogspot.com/2006/10/rman-connection-to-catalog.html"&gt;RMAN connection to Catalog&lt;/a&gt;. In fact when connection to Catalog fails, RMAN quits and rest of script is ignored. So I've changed this. RMAN connect only to Target Database during backup process, and after that RMAN is run second time. This time it connects to Target Database and Catalog Database, then run command &lt;span style="font-weight: bold;"&gt;RESYNC CATALOG&lt;/span&gt; to force synchronization of control file with Catalog. It should work now.
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6142191345005142998?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6142191345005142998/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6142191345005142998' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6142191345005142998'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6142191345005142998'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/01/rman-connection-to-catalog-updated.html' title='RMAN connection to Catalog - updated'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-9087457635136553089</id><published>2007-01-02T23:54:00.000+01:00</published><updated>2007-01-03T00:06:02.302+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='flashback'/><category scheme='http://www.blogger.com/atom/ns#' term='dba'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>ORA-03297 on empty datafile</title><content type='html'>Today I've noticed strange behavior of Oracle 10gR2 (10.2.0.3) while shrinking datafile. I had empty datafile (no objects) and i couldn't resize it. I was getting &lt;span style="font-style: italic;"&gt;ORA-03297: file contains used data beyond requested RESIZE value&lt;/span&gt; while DBA_EXTENTS show no rows for that file. I've discovered that there are objects in Recycle Bin that were located on that file. After purging recycle bin file was shirked successfully.
&lt;br/&gt;Let me make an example:
&lt;pre&gt;SQL&gt; create tablespace tb_test
  2  datafile 'c:\temp\tb_test.dbf' size 100 K autoextend on;
Tablespace created.
SQL&gt; select count(*) from dba_extents where tablespace_name='TB_TEST';
  COUNT(*)                                                                      
----------                                                                      
         0                                                                      
SQL&gt; select bytes from v$datafile where name = 'C:\TEMP\TB_TEST.DBF';
     BYTES                                                                      
----------                                                                      
    106496                                                                      
SQL&gt; create table t_big tablespace tb_test as
  2  select a.* from all_objects a, dba_users for_cartesian;
Table created.
SQL&gt; select count(*) from dba_extents where tablespace_name='TB_TEST';
  COUNT(*)                                                                      
----------                                                                      
        34                                                                      
SQL&gt; select bytes from v$datafile where name = 'C:\TEMP\TB_TEST.DBF';
     BYTES                                                                      
----------                                                                      
  19963904&lt;/pre&gt;Now we have datafile quite big. Let's drop table and shrink file:
&lt;pre&gt;SQL&gt; drop table t_big;
Table dropped.
SQL&gt; select count(*) from dba_extents where tablespace_name='TB_TEST';
  COUNT(*)                                                                      
----------                                                                      
         0                                                                      
SQL&gt; alter database datafile 'c:\temp\tb_test.dbf' resize 100 K;
alter database datafile 'c:\temp\tb_test.dbf' resize 100 K
*
ERROR at line 1:
ORA-03297: file contains used data beyond requested RESIZE value 
&lt;/pre&gt;So. even there is nothing reported in DBA_EXTENT, file cannot be shinked.
Let's purge recyclebin and try again:
&lt;pre&gt;SQL&gt; purge recyclebin;
Recyclebin purged.
SQL&gt; alter database datafile 'c:\temp\tb_test.dbf' resize 100 K;
Database altered.&lt;/pre&gt;
&lt;span style="font-weight:bold;"&gt;Now works fine!&lt;/span&gt;
Don't forget to clear after tests :)
&lt;pre&gt;SQL&gt; drop tablespace tb_test including contents and datafiles;
Tablespace dropped.&lt;/pre&gt;
&lt;br/&gt;&lt;br/&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-9087457635136553089?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/9087457635136553089/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=9087457635136553089' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9087457635136553089'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9087457635136553089'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2007/01/ora-03297-on-empty-datafile.html' title='ORA-03297 on empty datafile'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1330250688396803144</id><published>2006-12-30T17:43:00.000+01:00</published><updated>2006-12-30T17:59:04.777+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='security'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Security: getting DBA rights quite easy</title><content type='html'>I've stepped today at &lt;a href="http://orasec.blogspot.com/"&gt;ORASEC blog by Paul Wright&lt;/a&gt;. I've found &lt;a href="http://www.ukcert.org.uk/oracle/Demonstrating%20the%20ALTER%20SESSSION%20bug%20reported%20by%20Imperva.htm"&gt;this issue&lt;/a&gt; a big problem. Anybody that is using Oracle client on windows can quite easy get DBA rights by editing client9.dll file. I've to check if this is still problem with latest Oracle 10.2.0.3 release.
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1330250688396803144?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1330250688396803144/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1330250688396803144' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1330250688396803144'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1330250688396803144'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/12/security-getting-dba-rights-quite-easy.html' title='Security: getting DBA rights quite easy'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3415797539864373101</id><published>2006-12-21T13:25:00.000+01:00</published><updated>2006-12-21T14:14:56.444+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='patch'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Applying Oracle 10.2.0.3 patch</title><content type='html'>Today I've installed patch 10.2.0.3 for Oracle on Windows on top of 10.2.0.2 database. I've noticed that my spool file generated by upgrade script was &lt;span style="font-weight: bold;"&gt;33 MB big&lt;/span&gt;. It occurred that source of all oracle build-in packages were spooled. It was terrible experience to search for errors in this log file, as searching for 'ORA-' give hundreds results and I had to figure out if it is in comment of package, or real error.
&lt;br /&gt;Fortunately patch was installed successfully and everything runs fine.
&lt;br /&gt;
&lt;br /&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3415797539864373101?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3415797539864373101/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3415797539864373101' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3415797539864373101'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3415797539864373101'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/12/applying-oracle-10203-patch.html' title='Applying Oracle 10.2.0.3 patch'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-855576528347528725</id><published>2006-12-07T23:05:00.000+01:00</published><updated>2006-12-07T23:08:33.221+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='strings'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>UTL_MATCH - String Similarity in Oracle</title><content type='html'>You
can compare string using equality operator (=), or using similarity
operator (LIKE). But there are cases where it is not enough. You Can
use &lt;b&gt;UTL_MATCH &lt;/b&gt;package to calculate string
similarity index. This packages offers 4 functions that take two
strings as parameters:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;b&gt;edit_distance&lt;/b&gt;
- algorithm by &lt;a href="http://en.wikipedia.org/wiki/Edit_distance"&gt;Levenshtein&lt;/a&gt;
- returns number of edits&amp;nbsp;that must be done to change one
string into second,&lt;/li&gt;&lt;li&gt;&lt;b&gt;edit_distance_similarity&lt;/b&gt;
- normalized results of &lt;b&gt;edit_distance&lt;/b&gt; in percents -
integer values,&lt;/li&gt;&lt;li&gt;&lt;b&gt;jaro_winkler&lt;/b&gt;
- returns similarity based on &lt;a
 href="http://en.wikipedia.org/wiki/Jaro-Winkler"&gt;Jaro-Winkler
distance algorithm&lt;/a&gt;,&lt;/li&gt;&lt;li&gt;&lt;b&gt;jaro_winkler_similarity&lt;/b&gt;
- same as above but presented as integer in range 0-100.&lt;/li&gt;&lt;/ul&gt;Lets
teke a look how it works. First we can create sample table and insert
some data:&lt;br /&gt;&lt;pre&gt;create table countries(name varchar2(15) not null);&lt;br /&gt;insert into countries values ('Poland');&lt;br /&gt;insert into countries values ('Germany');&lt;br /&gt;insert into countries values ('United States');&lt;br /&gt;insert into countries values ('Portugal');&lt;br /&gt;insert into countries values ('Czech Republic');&lt;br /&gt;insert into countries values ('China');&lt;br /&gt;insert into countries values ('Slovakia');&lt;br /&gt;insert into countries values ('Slovenia');&lt;br /&gt;commit;&lt;br /&gt;&lt;/pre&gt;Now
we can take a look at results. Lets compare to miss-spelled country
name: '&lt;b&gt;Slovnia&lt;/b&gt;'&lt;br /&gt;&lt;pre&gt;select name&lt;br /&gt; ,to_char(utl_match.edit_distance(name, 'Slovnia'),'999') edit_dist&lt;br /&gt; ,to_char(utl_match.edit_distance_similarity(name, 'Slovnia'),'999') edit_dist_sim&lt;br /&gt; ,to_char(utl_match.jaro_winkler(name, 'Slovnia'),'999d9999') jaro_winkler&lt;br /&gt; ,to_char(utl_match.jaro_winkler_similarity(name, 'Slovnia'),'999') jaro_winkler_sim&lt;br /&gt;from countries&lt;br /&gt;order by jaro_winkler_sim desc;&lt;br /&gt;&lt;br /&gt;NAME                 EDIT EDIT JARO_WINK JARO&lt;br /&gt;-------------------- ---- ---- --------- ----&lt;br /&gt;Slovenia                1   88     .9750   97&lt;br /&gt;Slovakia                2   75     .8881   88&lt;br /&gt;China                   5   29     .5619   56&lt;br /&gt;United States          12    8     .5531   55&lt;br /&gt;Poland                  6   15     .5317   53&lt;br /&gt;Portugal                7   13     .5119   51&lt;br /&gt;Germany                 7    0     .3571   35&lt;br /&gt;Czech Republic         13    8     .0000    0&lt;/pre&gt;Above
we
can observe differences in algorithms.&lt;br /&gt;Lets test it on NULLs:&lt;br /&gt;&lt;pre&gt;SQL&amp;gt; select to_char(utl_match.edit_distance('test', NULL),'999')&lt;br /&gt;  2      edit_dist&lt;br /&gt;  3   ,to_char(utl_match.edit_distance_similarity('test', NULL),'999')&lt;br /&gt;  4      edit_dist_sim&lt;br /&gt;  5   ,to_char(utl_match.jaro_winkler('test', NULL),'999d9999')&lt;br /&gt;  6      jaro_winkler&lt;br /&gt;  7   ,to_char(utl_match.jaro_winkler_similarity('test', NULL),'999')&lt;br /&gt;  8      jaro_winkler_sim&lt;br /&gt;  9  from dual;&lt;br /&gt;&lt;br /&gt;EDIT EDIT JARO_WINK JARO&lt;br /&gt;---- ---- --------- ----&lt;br /&gt;&lt;b&gt;  -1  125&lt;/b&gt;     .0000    0&lt;/pre&gt;We
can see that using &lt;b&gt;edit_distance&lt;/b&gt; on NULLs migth be
dengerous.&lt;br /&gt;All samples were run on Oracle 10g XE&lt;br /&gt;&lt;br /&gt;Hope You find it usefull.&lt;br /&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-855576528347528725?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/855576528347528725/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=855576528347528725' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/855576528347528725'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/855576528347528725'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/12/utlmatch-string-similarity-in-oracle.html' title='UTL_MATCH - String Similarity in Oracle'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5232605478231239788</id><published>2006-11-22T23:29:00.000+01:00</published><updated>2006-11-22T23:33:52.305+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>MERGE and SEQUENCE</title><content type='html'>Last days I was working on
code and I was using merges often. And i've notice some side-effect.
When you use sequence in WHEN NOT FOUND clause then next sequence value
is gathered for all rows processed in query. I've observed it on 10g R2
EE (10.2.0.2) and on Oracle XE. Let me show test case. First create
sequence:&lt;pre&gt;SQL&amp;gt; create sequence a_sq start with 1 increment by 1 nocache;
Sequence created.&lt;/pre&gt;This
sequence generator starts with 1 with step 1. Lets taka look how many
rows we have in USER_OBJECTS view:&lt;pre&gt;SQL&amp;gt; select count(*) from user_objects;
 COUNT(*)
----------
 &lt;b&gt;46&lt;/b&gt;&lt;/pre&gt;Lets
create sample table and populate it with 10 rows:&lt;pre&gt;SQL&amp;gt; create table a_tab as
 2 select object_id o_id, object_name o_name, &lt;b&gt;a_sq.nextval&lt;/b&gt; o_sq
 3 from user_objects where rownum &amp;lt;=&lt;b&gt;10&lt;/b&gt;;
Table created.&lt;/pre&gt;So
we have table with 10 rows, and last number generated by sequence is
also 10:&lt;pre&gt;SQL&amp;gt; select count(*), max(o_sq) from a_tab;
 COUNT(*) MAX(O_SQ)
---------- ----------
 10 &lt;b&gt;10&lt;/b&gt;&lt;/pre&gt;Now
we run merge:&lt;pre&gt;SQL&amp;gt; merge into a_tab
 2 using (select object_id , object_name
 3 from user_objects )
 4 on (object_id = o_id)
 5 when matched then
 6 update set o_name = object_name
 7 when not matched then
 8 insert (o_id, o_name, o_sq)
 9 values (object_id, object_name, &lt;b&gt;a_sq.nextval&lt;/b&gt;);
&lt;b&gt;47 rows &lt;/b&gt;merged.&lt;/pre&gt;47
rows were merged, but 10 rows was updated and 37 inserted. Lets check
it:&lt;pre&gt;SQL&amp;gt; select count(*), max(o_sq) from a_tab;
 COUNT(*) MAX(O_SQ)
---------- ----------
 47 &lt;b&gt;57&lt;/b&gt;&lt;/pre&gt;It
seems that sequence generated &lt;b&gt;47 new values&lt;/b&gt;, but
only &lt;b&gt;37&lt;/b&gt; rws were inserted.
Lets run the
same merge one more time. This time rows will be only updated, as all
rows are already in a_tab table.&lt;pre&gt;SQL&amp;gt; merge into a_tab
 2 using (select object_id , object_name
 3 from user_objects )
 4 on (object_id = o_id)
 5 when matched then
 6 update set o_name = object_name
 7 when not matched then
 8 insert (o_id, o_name, o_sq)
 9 values (object_id, object_name, a_sq.nextval);
&lt;b&gt;47 &lt;/b&gt;rows merged.&lt;/pre&gt;Now
no new rows where created. But what happen to sequence:
&lt;pre&gt;SQL&amp;gt; select a_sq.nextval from dual;
 NEXTVAL
----------
 105&lt;/pre&gt;It
generated &lt;b&gt;another 47 &amp;nbsp;values&lt;/b&gt;, that are
useless.
It can be proved:
&lt;pre&gt;SQL&amp;gt; select count(*), max(o_sq) from a_tab;
 COUNT(*) MAX(O_SQ)
---------- ----------
 47 &lt;b&gt;57&lt;/b&gt;&lt;/pre&gt;This
side effect might have impact on performance. Also you loose lot of
numbers, when most of rows are updated.



Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5232605478231239788?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5232605478231239788/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5232605478231239788' title='6 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5232605478231239788'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5232605478231239788'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/merge-and-sequence.html' title='MERGE and SEQUENCE'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>6</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4906477278184872399</id><published>2006-11-20T17:41:00.000+01:00</published><updated>2006-11-20T17:41:17.622+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='links'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Links 2006-11-20</title><content type='html'>Links 2006-11-20:&lt;br /&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://download-uk.oracle.com/oowsf2005/936.pdf"&gt;
Tutorial for Oracle HA&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.orafaq.com/node/1025"&gt;Easy XML - Let the Database do the Work&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://www.oracle.com/technology/tech/xml/xmldb/Current/TWP_Mastering_XML_Generation.pdf"&gt;Mastering
XML Generation in Oracle Database 10g Release 2&lt;/a&gt;&lt;/li&gt;&lt;li&gt;&lt;a href="http://technology.amis.nl/blog/?p=1389"&gt;Extracting
Master-Detail data from an XMLType with a single SQL statement&lt;/a&gt;&lt;/li&gt;&lt;/ul&gt;
&lt;br/&gt;&lt;br/&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4906477278184872399?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4906477278184872399/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4906477278184872399' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4906477278184872399'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4906477278184872399'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/links-2006-11-20.html' title='Links 2006-11-20'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-1863854620373315107</id><published>2006-11-19T12:58:00.000+01:00</published><updated>2006-11-19T13:00:25.927+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Blogger Beta Backup tool</title><content type='html'>Finally i found time to
prepare solution to backup my blog. I've decided to do that as &lt;a href="http://pbarut.blogspot.com/2006/10/what-tool-do-you-use-to-make-blog.html"&gt;&lt;span&gt;I
had problems to backup my blog&lt;/span&gt;&lt;/a&gt;&lt;span&gt; using
available tools. To archive that I use Blogger Beta Atom feeds, few
tables in Oracle, and PL/SQL package to read blog posts, parse them
using XML DB features and store in DB tables.&lt;/span&gt;
&lt;h2&gt;Requirements&lt;/h2&gt;
&lt;ul&gt; &lt;li&gt;Oracle 10g (tested on Oracle XE on
Windows and Oracle Enterprise 10.2.0.2 on Windows). Oracle9i should
work also, but it's not tested. &lt;/li&gt;&lt;li&gt;Blogs
maintained by &lt;b&gt;Beta Blogger&lt;/b&gt; and hosted on
blogspot.com. You must allow to &lt;b&gt;publish full content &lt;/b&gt;of your posts and
comments. &lt;/li&gt;&lt;li&gt;Direct connection to
Internet
&lt;/li&gt;&lt;/ul&gt;&lt;h2&gt;Installation&lt;/h2&gt;
&lt;ol&gt; &lt;li&gt;Download &lt;a href="http://www.barut.info/down/blogger_backup.zip"&gt;installation
package&lt;/a&gt; &lt;/li&gt;&lt;li&gt;Create new
Oracle schema and grant to it: &lt;ol&gt; &lt;li&gt;roles
&lt;b&gt;CONNECT&lt;/b&gt; and &lt;b&gt;RESOURCE&lt;/b&gt; &lt;/li&gt;&lt;li&gt;&lt;b&gt;EXECUTE&lt;/b&gt;
on &lt;b&gt;SYS.UTL_HTTP&lt;/b&gt; &lt;/li&gt;&lt;/ol&gt; &lt;/li&gt;&lt;li&gt;run
script &lt;b&gt;install.sql&lt;/b&gt;
&lt;/li&gt;&lt;/ol&gt;&lt;h2&gt;Usage&lt;/h2&gt;
First You have to register blog you want to backup.
Use &lt;b&gt;BLOGSPOT_BACKUP.register_blog&lt;/b&gt; function:
&lt;pre&gt;begin&lt;br&gt; dbms_output.put_line(&lt;br&gt; BLOGSPOT_BACKUP.register_blog&lt;br&gt; ('Software Engineer Thoughts', 'http://pbarut.blogspot.com/'));&lt;br&gt; commit;&lt;br&gt;end;&lt;/pre&gt;To
download all your posts with comments andl labels
use this PL/SQL block:
&lt;pre&gt;begin &lt;br&gt; BLOGSPOT_BACKUP.synchronize_blog(null, false); &lt;br&gt; BLOGSPOT_BACKUP.synchronize_labels(null, null); &lt;br&gt; BLOGSPOT_BACKUP.synchronize_comments(null, null, false); &lt;br&gt; commit; &lt;br&gt;end;&lt;/pre&gt;For
more information take
a look into BLOGSPOT_BACKUP specification.
&lt;h2&gt;Data storage&lt;/h2&gt;
&lt;table border="1" bordercolor="#000000" cellpadding="4" cellspacing="0" width="100%"&gt; &lt;thead&gt; &lt;tr valign="top"&gt; &lt;th width="50%"&gt; Table
name &lt;/th&gt; &lt;th width="50%"&gt; Desription
&lt;/th&gt; &lt;/tr&gt; &lt;/thead&gt; &lt;tbody&gt; &lt;tr valign="top"&gt; &lt;td width="50%"&gt; BLOGS
&lt;/td&gt; &lt;td width="50%"&gt; Blogs registered
for backup. &lt;/td&gt; &lt;/tr&gt; &lt;tr valign="top"&gt;
&lt;td width="50%"&gt; BLOG_POSTS &lt;/td&gt;
&lt;td width="50%"&gt; Blog posts downloaded.
&lt;/td&gt; &lt;/tr&gt; &lt;tr valign="top"&gt; &lt;td width="50%"&gt; BLOG_LABELS &lt;/td&gt; &lt;td width="50%"&gt; Labels associated to blog posts.
&lt;/td&gt; &lt;/tr&gt; &lt;tr valign="top"&gt; &lt;td width="50%"&gt; BLOG_COMMENTS &lt;/td&gt; &lt;td width="50%"&gt; Comments related to blog posts.
&lt;/td&gt; &lt;/tr&gt; &lt;tr valign="top"&gt; &lt;td width="50%"&gt; FEED_CACHE &lt;/td&gt; &lt;td width="50%"&gt; Used speed up tests. In tests phase
feeds are read from this table instead of downloading every time.
&lt;/td&gt; &lt;/tr&gt; &lt;/tbody&gt;
&lt;/table&gt;&lt;br&gt;&lt;br&gt;
&lt;h2&gt;End notes&lt;/h2&gt;
I'm publishing this tool, as some of you might find
it useful. It should work on all beta blogger blogs, but I do not
give ant warranty. In case of any problems fill free to contact me.

&lt;br/&gt;&lt;br/&gt;Regards, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-1863854620373315107?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/1863854620373315107/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=1863854620373315107' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1863854620373315107'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/1863854620373315107'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/blogger-beta-backup-tool.html' title='Blogger Beta Backup tool'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4998557858409030103</id><published>2006-11-16T22:54:00.000+01:00</published><updated>2006-11-16T22:58:25.723+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>The Palm: The Eighth Wonder of World</title><content type='html'>You must definitely see &lt;a href="http://www.thepalm.ae/"&gt;The Palm: The Eighth Wonder of World&lt;/a&gt;. Incredible...
&lt;br/&gt;&lt;br/&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4998557858409030103?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4998557858409030103/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4998557858409030103' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4998557858409030103'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4998557858409030103'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/palm-eighth-wonder-of-world.html' title='The Palm: The Eighth Wonder of World'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-9041658468008666509</id><published>2006-11-13T23:48:00.000+01:00</published><updated>2006-11-13T23:50:40.232+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>ORA-30625 and XMLType</title><content type='html'>I will present
some differences in handling XMLType in SQL and PL/SQL by Oracle.
Test case was done on Oracle&amp;nbsp;10.2.0.2. Lets define
variable and fill it with sample data. It is important to have empty
value in tag &lt;b&gt;&amp;lt;empty&amp;gt;&lt;/b&gt;.&lt;pre&gt;SQL&amp;gt; var xm varchar2(100);&lt;br /&gt;SQL&amp;gt; exec :xm := '&amp;lt;root&amp;gt;&amp;lt;empty&amp;gt;&amp;lt;/empty&amp;gt;&amp;lt;/root&amp;gt;';&lt;br /&gt;PL/SQL procedure successfully completed.&lt;br /&gt;&lt;/pre&gt;
Lets try to extract value of empty tag:
&lt;pre&gt;SQL&amp;gt; var xmv varchar2(100);&lt;br /&gt;SQL&amp;gt; exec :xmv := XMLType(:xm).extract('//empty/text()').getstringval();&lt;br /&gt;BEGIN :xmv := XMLType(:xm).extract('//empty/text()').getstringval(); END;&lt;br /&gt;*&lt;br /&gt;ERROR at line 1:&lt;br /&gt;ORA-30625: method dispatch on NULL SELF argument is disallowed &lt;br /&gt;ORA-06512: at line 1 &lt;/pre&gt;Lets
do the same with SQL:&lt;br /&gt;&lt;pre&gt;SQL&amp;gt; select XMLType(:xm).extract('//empty/text()').getstringval() from dual;&lt;br /&gt;XMLTYPE(:XM).EXTRACT('//EMPTY/TEXT()').GETSTRINGVAL()&lt;br /&gt;--------------------------------------------------------------------------------&lt;br /&gt;&lt;/pre&gt;Now
we get NULL. You can confirm this with that query:&lt;br /&gt;&lt;pre&gt;SQL&amp;gt; select nvl(XMLType(:xm).extract('//empty/text()').getstringval(),&lt;br /&gt;'(NULL)') from dual;&lt;br /&gt;NVL(XMLTYPE(:XM).EXTRACT('//EMPTY/TEXT()').GETSTRINGVAL(),'(NULL)')&lt;br /&gt;--------------------------------------------------------------------------------&lt;br /&gt;(NULL)&lt;/pre&gt;So,
be careful when you extract data from XMLType in PL/SQL. If you want
NULL to be returned for empty tags then you should use function like
this:&lt;br /&gt;&lt;pre&gt;CREATE OR REPLACE&lt;br /&gt;FUNCTION XML_EXTRACT_NO_EXCEPTION&lt;br /&gt;( p_xml IN XMLTYPE&lt;br /&gt;, p_xpath IN VARCHAR2&lt;br /&gt;, p_namespace IN VARCHAR2 default NULL&lt;br /&gt;) RETURN VARCHAR2 AS&lt;br /&gt;BEGIN&lt;br /&gt;return case when p_xml.extract(p_xpath, p_namespace) is not null&lt;br /&gt;then p_xml.extract(p_xpath, p_namespace).getstringval()&lt;br /&gt;else NULL&lt;br /&gt;end;&lt;br /&gt;END XML_EXTRACT_NO_EXCEPTION;&lt;br /&gt;&lt;/pre&gt;And
then you can use it safe
in PL/SQL:&lt;br /&gt;&lt;pre&gt;SQL&amp;gt; exec :xmv := XML_EXTRACT_NO_EXCEPTION(XMLType(:xm), '//empt/text()');&lt;br /&gt;PL/SQL procedure successfully completed.&lt;br /&gt;SQL&amp;gt; print :xmv&lt;br /&gt;XMV&lt;br /&gt;--------------------------------------------------------------------------------&lt;br /&gt;&lt;/pre&gt;Another
reason for ORA-30625 can be that you did not provide namespace in
execution of extract. More on this in my post &lt;br /&gt;&lt;a href="http://pbarut.blogspot.com/2006/11/xmltype-and-namespace-problem.html"&gt;XMLType
and Namespace problem&lt;/a&gt;.&lt;br /&gt;&lt;br /&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-9041658468008666509?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/9041658468008666509/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=9041658468008666509' title='7 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9041658468008666509'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/9041658468008666509'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/ora-30625-and-xmltype.html' title='ORA-30625 and XMLType'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>7</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-28591435971343151</id><published>2006-11-12T16:39:00.000+01:00</published><updated>2006-11-12T16:44:13.466+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='sql developer'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>SQL Developer 1.1 preview</title><content type='html'>Today I give a try to new &lt;a href="http://apex.oracle.com/pls/otn/f?p=22290"&gt;SQL
Developer 1.1&lt;/a&gt;. Installation on Windows 2000 goes smoothly
without any problems. Users interface is almost the same as in previous
version. One change that I noticed at one is search plug in, that
allows user to search Oracle documentation and also &lt;a href="http://asktom.oracle.com/"&gt;Ask Tom&lt;/a&gt; site. It
integrated well with my Firefox . There are 2 new features
that&amp;nbsp;was missing in previous version:
&lt;ul&gt;
  &lt;li&gt;XMLType support - now XML data is displayed as query
results, so you can open pop-up and see all details&lt;/li&gt;
  &lt;li&gt;Display for Date type - you can define in
preferences how dates should be displayed&lt;/li&gt;
&lt;/ul&gt;
What I'm still missing is possibility to update more then one row in
Index Organized Tables (IOT) in single transaction. At the moment when
you change one row you must commit transaction. If you do not do that,
whole transaction will be forced to be rolled back.
&lt;br/&gt;Changes goes in good directions. Might be in few months i will completely stop to use TOAD...
&lt;br/&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-28591435971343151?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/28591435971343151/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=28591435971343151' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/28591435971343151'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/28591435971343151'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/sql-developer-11-preview.html' title='SQL Developer 1.1 preview'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8001620694811939461</id><published>2006-11-07T23:24:00.000+01:00</published><updated>2006-11-07T23:30:11.217+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>XMLType and Namespace problem</title><content type='html'>I've run into some strange problem with XMLType and XML namespaces.
I'll try to make a showcase. Lets define variable and simple XML
content
&lt;pre&gt;SQL&amp;gt; var x varchar2(200);&lt;br&gt;SQL&amp;gt; exec :x := '&amp;lt;feed&lt;br&gt;xmlns="http://www.w3.org/2005/Atom"&amp;gt;&amp;lt;id&amp;gt;test_id&amp;lt;/id&amp;gt;&amp;lt;/feed&amp;gt;'&lt;br&gt;PL/SQL procedure successfully completed.&lt;/pre&gt;
Try to find out what tag is on root:
&lt;pre&gt;SQL&amp;gt; select XMLType(:x).getRootElement() from dual;&lt;br&gt;XMLTYPE(:X).GETROOTELEMENT()&lt;br&gt;--------------------------------------------------------------------------------&lt;br&gt;feed&lt;/pre&gt;
Lets find out the namespace:
&lt;pre&gt;SQL&amp;gt; select XMLType(:x).getNamespace() from dual;&lt;br&gt;XMLTYPE(:X).GETNAMESPACE()&lt;br&gt;--------------------------------------------------------------------------------&lt;br&gt;&lt;/pre&gt;
Seems to be no namespace. But there was namespace in XML definition.
Lets try extract data:
&lt;pre&gt;SQL&amp;gt; select XMLType(:x).extract('/feed').getStringVal() from dual;&lt;br&gt;XMLTYPE(:X).EXTRACT('/FEED').GETSTRINGVAL()&lt;br&gt;--------------------------------------------------------------------------------&lt;br&gt;&lt;/pre&gt;
So nothing was extracted.&lt;span style="font-weight: bold;"&gt;
It's not what I was expecting.&lt;/span&gt; Ok, lets try to force
namespace:
&lt;pre&gt;SQL&amp;gt; select XMLType(:x).extract('/feed',&lt;br&gt;'xmlns="http://www.w3.org/2005/Atom"').getStringVal() from dual;&lt;br&gt;XMLTYPE(:X).EXTRACT('/FEED','XMLNS="HTTP://WWW.W3.ORG/2005/ATOM"').GETSTRINGVAL(&lt;br&gt;--------------------------------------------------------------------------------&lt;br&gt;&amp;lt;feed&lt;br&gt;xmlns="http://www.w3.org/2005/Atom"&amp;gt; &amp;lt;id&amp;gt;test_id&amp;lt;/id&amp;gt;&lt;br&gt;&amp;lt;/feed&amp;gt; &lt;br&gt;&lt;/pre&gt;
&lt;span style="font-weight: bold;"&gt;Now works fine&lt;/span&gt;.&lt;br&gt;
For me it is little confusing: there is no namespace, but you must
provide namespace if you want to extract data.

&lt;br/&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8001620694811939461?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8001620694811939461/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8001620694811939461' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8001620694811939461'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8001620694811939461'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/11/xmltype-and-namespace-problem.html' title='XMLType and Namespace problem'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-7708160679418110607</id><published>2006-10-25T22:36:00.000+02:00</published><updated>2006-10-25T22:45:01.303+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><category scheme='http://www.blogger.com/atom/ns#' term='search'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Search Oracle Blogs</title><content type='html'>Google announced release of new tool &lt;a href=http://google.com/coop/cse/&gt;Google Custom Search Engine&lt;/a&gt;. Using this tool You can create our own list of sites you want to search within. There are also many options to customize search result pages, to have search results on your own site. You may also collaborate with other users, to create list of sites on specific topic.
&lt;br /&gt;Based o this I’ve created a new search engine that searches only &lt;b&gt;Blogs related to Oracle&lt;/b&gt;. You can check if you are already listed. If not you can add your site. You are welcome to take part and propose sites with oracle related blogs. For sure I will include it in this listing.
&lt;br/&gt;On top of my page you can find search box. &lt;b&gt;Try it&lt;/b&gt;.
&lt;br/&gt;
If you want this search box on your page just copy following HTML code
&lt;pre&gt;&amp;lt;!-- Google CSE Search Box Begins --&amp;gt;
&amp;lt;form id="searchbox_007198821948994293043:dv284dbx17s" action="http://www.google.com/cse"&amp;gt;
  &amp;lt;input type="hidden" name="cx" value="007198821948994293043:dv284dbx17s" /&amp;gt;
  &amp;lt;input name="q" type="text" size="40" /&amp;gt;
  &amp;lt;input type="submit" name="sa" value="Search" /&amp;gt;
  &amp;lt;input type="hidden" name="cof" value="FORID:1" /&amp;gt;
&amp;lt;/form&amp;gt;
&amp;lt;script type="text/javascript" src="http://www.google.com/coop/cse/brand?form=searchbox_007198821948994293043%3Adv284dbx17s"&amp;gt;&amp;lt;/script&amp;gt;
&amp;lt;!-- Google CSE Search Box Ends --&amp;gt;&lt;/pre&gt;
&lt;br/&gt;&lt;br/&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-7708160679418110607?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/7708160679418110607/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=7708160679418110607' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7708160679418110607'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/7708160679418110607'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/search-oracle-blogs.html' title='Search Oracle Blogs'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3837216462317610516</id><published>2006-10-25T08:00:00.000+02:00</published><updated>2006-10-25T09:01:19.717+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle 11g new features, part 2</title><content type='html'>There are two new interesting sources for 11g new features.
&lt;br /&gt;Tim Hall post &lt;a href=http://www.oracle-base.com/blog/2006/10/24/the-next-generation-self-managing-database-11g/&gt;The Next-Generation Self-Managing Database (11g)&lt;/a&gt;
&lt;br /&gt;And Lewis Cunningham post &lt;a href=http://blogs.ittoolbox.com/oracle/guide/archives/oow-enhancements-in-oracle-11g-plsql-12502&gt;OOW: Enhancements in Oracle 11g PL/SQL&lt;/a&gt;
&lt;br /&gt;Also these features or enhancements seems very promising
&lt;ol&gt;&lt;li&gt;&lt;b&gt;PL/SQL Native Compilation&lt;/b&gt;. There is no need for external C compiler, so it’s easier to make PL/SQL faster.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;New Data Type: simple_integer&lt;/b&gt;. Another performance booster.&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Intra-unit inlining.&lt;/b&gt; - this is feature that I was missing for years. Now I can create complex expressions and reuse it easily. I hope it will work also in SQL&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Database Replay and SQL Replay &lt;/b&gt;- this is very interesting idea.&lt;/li&gt;
&lt;/ol&gt;
I'm looking forward to play with these features.
&lt;br /&gt;
&lt;br /&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3837216462317610516?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3837216462317610516/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3837216462317610516' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3837216462317610516'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3837216462317610516'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/oracle-11g-new-features-part-2.html' title='Oracle 11g new features, part 2'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6573024784100219298</id><published>2006-10-24T22:23:00.000+02:00</published><updated>2006-10-24T22:37:27.809+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='11g'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Oracle 11g new features</title><content type='html'>I have found Laurent post on &lt;a href="http://laurentschneider.blogspot.com/2006/10/11g-new-features.html"&gt;11g new features&lt;/a&gt; very interesting. Let me comment on some items:
&lt;ol&gt;&lt;li&gt;&lt;b&gt;/*+result_cache*/&lt;/b&gt; is very promising. From description it seems that it might be very useful for web applications based on Oracle. But sentence "There is an aggressive cache invalidation, so whatever DML happens on one dependent table, the cache result is invalidated" suggest that it will be useful only in read only environment. Otherwise cache will be constantly invalidated making this feature useless. Question is if query results will be stored in new memory structure, or it will be in Buffer Cache? Anyway there might be need for huge RAM&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Using sequence in PL/SQL without DML&lt;/b&gt;. This is long time expected feature&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Trigger order&lt;/b&gt;. This can be also sometimes useful.&lt;/li&gt;
&lt;/ol&gt;All other features seem to be just improvements or enhancements. I do not see any revolutionary solution in this list.
&lt;br /&gt;&lt;br /&gt;
Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6573024784100219298?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6573024784100219298/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6573024784100219298' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6573024784100219298'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6573024784100219298'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/oracle-11g-new-features.html' title='Oracle 11g new features'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-3314248895678111126</id><published>2006-10-21T00:22:00.000+02:00</published><updated>2006-10-21T00:27:37.225+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='xml'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Binding list variable</title><content type='html'>Today I was working with XMLType, and as a side effect I found interesting solution to transform list of values contained in single string to rows. You can find some solutions on &lt;a href= http://tkyte.blogspot.com/2006/06/varying-in-lists.html&gt;Tom Kyte blog&lt;/a&gt;. But my solution is new approach that uses xmlType and xmlSequence
&lt;pre&gt;SQL&gt; var list varchar2(200)
SQL&gt; exec :list := '2,4,6,8,10,34,33';

PL/SQL procedure successfully completed.

SQL&gt; select items.extract('/l/text()').getStringVal() item
  2  from table(xmlSequence(
  3    extract(XMLType('&amp;lt;all&amp;gt;&amp;lt;l&gt;'||
  4      replace(:list,',','&amp;lt;/l&amp;gt;&amp;lt;l&gt;')||'&amp;lt;/l&amp;gt;&amp;lt;/all&amp;gt;')
  5          ,'/all/l'))) items;

ITEM                                                                            
--------------------------------------------------------------------------------
2                                                                               
4                                                                               
6                                                                               
8                                                                               
10                                                                              
34                                                                              
33                                                                              

7 rows selected.
&lt;/pre&gt;Simple! Isn’t it?
&lt;br /&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-3314248895678111126?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/3314248895678111126/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=3314248895678111126' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3314248895678111126'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/3314248895678111126'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/binding-list-variable.html' title='Binding list variable'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-726303764208076899</id><published>2006-10-18T17:27:00.000+02:00</published><updated>2006-10-18T17:42:20.298+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='blog'/><title type='text'>What tool do you use to make blog backup?</title><content type='html'>Today a have a question to you: &lt;b&gt;What tool do you use to make backup of your blog?&lt;/b&gt;
&lt;br /&gt;My blog in hosted on blogspot and is run by &lt;a href="http://beta.blogger.com/"&gt;beta.blogger.com&lt;/a&gt;. I was trying to make backup (mirror) using &lt;a href="http://www.httrack.com/"&gt;HTTrack&lt;/a&gt; but it run into infinite loop. It was downloading every post many, many, many.... times with little changed name.
&lt;br /&gt;Looking forward for your recommendation…
&lt;br /&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-726303764208076899?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/726303764208076899/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=726303764208076899' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/726303764208076899'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/726303764208076899'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/what-tool-do-you-use-to-make-blog.html' title='What tool do you use to make blog backup?'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5515977603216185626</id><published>2006-10-16T22:12:00.000+02:00</published><updated>2006-10-16T22:17:03.851+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='front-end'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>A better view? I do not think so.</title><content type='html'>I have read today Gojko Adzic article &lt;a href="http://www.orafaq.com/node/1013"&gt;A better view&lt;/a&gt;. I must say that it made me thinking about my approach to database and front-end applications. I do not share his opinion.
&lt;br /&gt;In my approach PL/SQL API is the only possible way to retrieve and manipulate data in Oracle Database. Especialy when it goes for Web Applications.
&lt;ul&gt;
&lt;li&gt;Logging user activity. Using triggers is fantasting to logging changes to data (Journaling), but usually is useless for logging user activity. User activity should be logged based on his/her actions and it’s parameters not data modifications. You do not want your batch processes to generate so many log.&lt;/li&gt;
&lt;li&gt;Performance Monitoring. With well-written API you can get very detailed statistics for time consumed by individual routine. Based on this statistics You can decide where are your bottlenecks and you can improve that.&lt;/li&gt;
&lt;li&gt;Simplicity. For easy, standard operations You should prepare generators that automatically generate API procedures for many simple tables.&lt;/li&gt;
&lt;li&gt;Cursors. PL/SQL procedures can return REF CURSORS as an output. With dynamic SQL you can return different variations of data depending on input parameters.&lt;/li&gt;
&lt;li&gt;API can be used for many Applications. In many big organizations one database is often accessed by different client applications. You do not have to write the same (similar) SQL’s in PHP, java or whatever other tool You want/plan to use.&lt;/li&gt;
&lt;/ul&gt;
Hope You understand my point of view.
&lt;br /&gt;If you are disagree or agree, please leave a comment.
&lt;br /&gt;&lt;br /&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5515977603216185626?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5515977603216185626/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5515977603216185626' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5515977603216185626'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5515977603216185626'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/better-view-i-do-not-think-so.html' title='A better view? I do not think so.'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2629982739963092896</id><published>2006-10-15T18:21:00.000+02:00</published><updated>2006-10-15T19:16:10.923+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Group Comparison Conditions</title><content type='html'>Sometimes there is a need to compare one value to many others. In Oracle SQL or PL/SQL for this purpose you can use Group Comparisons. Syntax for this is: &lt;br /&gt;&lt;i&gt;&lt;b&gt;expr { = | != | &amp;lt; | &amp;gt; | &amp;lt;&amp;gt; | &amp;lt;= | &amp;gt;= } {ANY | SOME | ALL} (expr, …, expr) &lt;/b&gt;&lt;/i&gt;, for example &lt;i&gt;&lt;b&gt;X = ANY (1,2,3) &lt;/b&gt;&lt;/i&gt;. &lt;br /&gt;You can use subquery instead of expression list. For full syntax go to &lt;a href=http://download-uk.oracle.com/docs/cd/B19306_01/server.102/b14200/conditions002.htm#sthref2731&gt;Oracle Documentation&lt;/a&gt;.
Lets see how it works. First create sample table:
&lt;pre&gt;SQL&gt; CREATE TABLE T1 (N1 NUMBER PRIMARY KEY, TEXT VARCHAR2(10));
Table created.
SQL&gt; INSERT INTO T1 SELECT LEV, LEV
  2  FROM (SELECT LEVEL LEV FROM DUAL CONNECT BY LEVEL &amp;lt; 10);
9 rows created.
SQL&gt; COMMIT;
Commit complete.
&lt;/pre&gt;
Then do some queries
&lt;pre&gt;SQL&gt; SELECT * FROM T1 WHERE N1 &amp;lt; ANY (4,6);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
         4 4                                                                    
         5 5                                                                    
SQL&gt; SELECT * FROM T1 WHERE N1 &amp;lt; SOME (4,6);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
         4 4                                                                    
         5 5                                                                    
SQL&gt; SELECT * FROM T1 WHERE N1 &amp;lt; ALL (4,6);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
&lt;/pre&gt;
And lets see what will happen if there is NULL in list:
&lt;pre&gt;SQL&gt; SELECT * FROM T1 WHERE N1 &amp;lt; ANY (4,6, NULL);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
         4 4                                                                    
         5 5                                                                    
SQL&gt; SELECT * FROM T1 WHERE N1 &amp;lt; SOME (4,6, NULL);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
         4 4                                                                    
         5 5                                                                    
SQL&gt; SELECT * FROM T1 WHERE N1 &amp;lt; ALL (4,6, NULL);
no rows selected
&lt;/pre&gt;
So we can see that ANY is equivalent to SOME. These Grouping conditions are in fact rewritten to simple conditions. ANY is rewritten to many comparisons with logical OR, &lt;i&gt;&lt;b&gt;a &amp;lt; ANY (b,c,d)&lt;/b&gt;&lt;/i&gt; is rewritten to &lt;i&gt;&lt;b&gt; (a&amp;lt;b OR a&amp;lt;c OR a&amp;lt;d)&lt;/b&gt;&lt;/i&gt; while ALL is rewritten to AND statement &lt;i&gt;&lt;b&gt;a &amp;lt; ALL(b,c,d) &lt;/b&gt;&lt;/i&gt; becomes &lt;i&gt;&lt;b&gt; (a&amp;lt;b AND a&amp;lt;c AND a&amp;lt;d)&lt;/b&gt;&lt;/i&gt;.
&lt;br /&gt;We can observe that &lt;i&gt;&lt;b&gt;= ANY&lt;/b&gt;&lt;/i&gt; is equivalent to &lt;i&gt;&lt;b&gt;IN&lt;/b&gt;&lt;/i&gt; operator.
&lt;pre&gt;SQL&gt; SELECT * FROM T1 WHERE N1 = ANY (4,6, NULL);
        N1 TEXT                                                                 
---------- ----------                                                           
         4 4                                                                    
         6 6                                                                    
SQL&gt; SELECT * FROM T1 WHERE N1 IN (4,6, NULL);
        N1 TEXT                                                                 
---------- ----------                                                           
         4 4                                                                    
         6 6                                                                    
&lt;/pre&gt;
Also observe that &lt;i&gt;&lt;b&gt;!= ALL&lt;/b&gt;&lt;/i&gt; is equivalent to &lt;i&gt;&lt;b&gt;NOT IN&lt;/b&gt;&lt;/i&gt; operator.
&lt;pre&gt;SQL&gt; SELECT * FROM T1 WHERE N1 != ALL (4,6);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
         5 5                                                                    
         7 7                                                                    
         8 8                                                                    
         9 9                                                                    
7 rows selected.
SQL&gt; SELECT * FROM T1 WHERE N1 NOT IN (4,6);
        N1 TEXT                                                                 
---------- ----------                                                           
         1 1                                                                    
         2 2                                                                    
         3 3                                                                    
         5 5                                                                    
         7 7                                                                    
         8 8                                                                    
         9 9                                                                    
7 rows selected.
SQL&gt; SELECT * FROM T1 WHERE N1 != ALL (4,6, NULL);
no rows selected
SQL&gt; SELECT * FROM T1 WHERE N1 NOT IN (4,6, NULL);
no rows selected
&lt;/pre&gt;
Take a look at trick with joining many tables based on the same key. Lets create more tables
&lt;pre&gt;SQL&gt; CREATE TABLE T2 (N2 NUMBER PRIMARY KEY, TEXT VARCHAR2(10));
Table created.
SQL&gt; INSERT INTO T2 SELECT * FROM T1;
9 rows created.
SQL&gt; CREATE TABLE T3 (N3 NUMBER PRIMARY KEY, TEXT VARCHAR2(10));
Table created.
SQL&gt; INSERT INTO T3 SELECT * FROM T1;
9 rows created.
SQL&gt; COMMIT;
Commit complete.
&lt;/pre&gt;
And simple join:
&lt;pre&gt;SQL&gt; SELECT N1, N2, N3 FROM T1, T2, T3 WHERE &lt;b&gt;N1 = ALL (N2,N3)&lt;/b&gt;;
        N1         N2         N3                                                
---------- ---------- ----------                                                
         1          1          1                                                
         2          2          2                                                
         3          3          3                                                
         4          4          4                                                
         5          5          5                                                
         6          6          6                                                
         7          7          7                                                
         8          8          8                                                
         9          9          9                                                
9 rows selected.
&lt;/pre&gt;Is it really evaluated in proper way?
&lt;pre&gt;SQL&gt; set autotrace traceonly;
SQL&gt; SELECT N1, N2, N3 FROM T1, T2, T3 WHERE &lt;b&gt;N1 = ALL (N2,N3)&lt;/b&gt;;
9 rows selected.
Execution Plan
----------------------------------------------
Plan hash value: 3348756600 
---------------------------------------------- ...
| Id  | Operation              | Name        | ...
---------------------------------------------- ...                                   
|   0 | SELECT STATEMENT       |             | ...
|   1 |  NESTED LOOPS          |             | ...
|   2 |   NESTED LOOPS         |             | ...
|   3 |    INDEX FAST FULL SCAN| SYS_C004041 | ...
|*  4 |    INDEX UNIQUE SCAN   | SYS_C004042 | ...
|*  5 |   INDEX UNIQUE SCAN    | SYS_C004043 | ...
---------------------------------------------- ...                                         
Predicate Information (identified by operation id): 
--------------------------------------------------- 
   4 - access("N1"="N2") 
   5 - access("N1"="N3") 
&lt;/pre&gt;So we can observe that it is really rewritten and oracle uses indexes in optimal way.
&lt;br /&gt;Hope you find it useful
&lt;br /&gt;&lt;br /&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2629982739963092896?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2629982739963092896/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2629982739963092896' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2629982739963092896'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2629982739963092896'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/group-comparison-conditions.html' title='Group Comparison Conditions'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-101785644599587151</id><published>2006-10-15T12:30:00.000+02:00</published><updated>2006-10-15T15:26:18.804+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='firebird'/><title type='text'>GUI for FireBird DB</title><content type='html'>Friend of mine, that is still working on xBase (Clipper), asked me to recommend him a good GUI tool for SQL database. At first I didn't know what he exactly wanted. In fact he wanted a tool to retrive and manipulate data in &lt;a href="http://www.firebirdsql.org/"&gt;FireBird DB&lt;/a&gt;. After trying few tools I recommended &lt;a href="http://www.ibobjects.com/ibo_ib_sql.html"&gt;IB_SQL&lt;/a&gt;. It's realy light weighted and intuitive.
&lt;p&gt;It was my first experience with FireBird. I must say that for me it seems insecure. Whole database is stored in one file, and if you have this file, you can easily open it without need for any password.

&lt;br /&gt;&lt;br /&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-101785644599587151?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/101785644599587151/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=101785644599587151' title='4 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/101785644599587151'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/101785644599587151'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/gui-for-firebird-bd.html' title='GUI for FireBird DB'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>4</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-439794481124522306</id><published>2006-10-06T18:47:00.000+02:00</published><updated>2006-10-06T18:48:27.633+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='backup'/><category scheme='http://www.blogger.com/atom/ns#' term='rman'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>RMAN connection to Catalog</title><content type='html'>Today my nightly backups were not taken. I had an OS script that started backup using this command:
&lt;pre&gt;rman target=sysop/password@targetdb catalog=rman/password@catdb 
      log=rman.log append @rman.txt&lt;/pre&gt;
The reason was that network was down and there was no connection to catdb. It leaded to error and RMAN did not start at all. So I’ve changed my command line to:
&lt;pre&gt;rman target=sysop/password@targetdb 
      log=rman.log append @rman.txt&lt;/pre&gt;
And added a line in rman.txt
&lt;pre&gt;connect catalog rman/password@catdb;&lt;/pre&gt;
Next time there will be no connection to catdb backup will be done anyway. It will be not registered in catalog only. Catalog will be synchronized on next backup procedure or next time you connect to target and catalog an issue any command that operate on catalog.
&lt;br /&gt;&lt;br /&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-439794481124522306?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/439794481124522306/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=439794481124522306' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/439794481124522306'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/439794481124522306'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/rman-connection-to-catalog.html' title='RMAN connection to Catalog'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4494848686745727077</id><published>2006-10-05T22:52:00.000+02:00</published><updated>2006-10-05T22:57:24.215+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='flashback'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>More on Flashback</title><content type='html'>If you are instrested in more materials on Oracle Flashback you should take a look at &lt;a href="http://tkyte.blogspot.com/"&gt;Tom Kyte&lt;/a&gt; presentation &lt;a href="http://www.coug.ab.ca/Resources/Pres0405/TomKyte_FlashBackQ_Mar-05.zip"&gt;TomKyte_FlashBackQ_Mar-05.zip&lt;/a&gt; found on &lt;a href="http://www.coug.ab.ca/resources.htm"&gt;Calgary Oracle Users Group&lt;/a&gt;.
&lt;br /&gt;Polish speeking readers can have a look at my article &lt;a href="http://www.ploug.org.pl/plougtki.php?action=read&amp;amp;p=31&amp;amp;a=10"&gt;PLOUG'tki
nr 31 (IX 2004) -  Podróż w czasie, czyli Oracle Flashback&lt;/a&gt; that I wrote for &lt;a href="http://www.ploug.org.pl/"&gt;Polish Oracle Users Group&lt;/a&gt;.

&lt;br /&gt;&lt;br /&gt;Cheers, Paweł
&lt;p&gt;Related articles:
&lt;ul&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/10/undosql-in-flashbacktransactionquery.html"&gt;UNDO_SQL in FLASHBACK_TRANSACTION_QUERY&lt;/a&gt;
&lt;/li&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/09/flashback-table-and-materialized-view.html"&gt;Flashback Table and Materialized View – not working together&lt;/a&gt;
&lt;/li&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html"&gt;Rolling Back the DDL&lt;/a&gt;
&lt;/li&gt;&lt;/ul&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4494848686745727077?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4494848686745727077/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4494848686745727077' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4494848686745727077'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4494848686745727077'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/more-on-flashback.html' title='More on Flashback'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-2962964059618576774</id><published>2006-10-04T23:33:00.000+02:00</published><updated>2006-10-04T23:35:20.403+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='flashback'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>UNDO_SQL in FLASHBACK_TRANSACTION_QUERY</title><content type='html'>When You read my post on &lt;a href= http://pbarut.blogspot.com/2006/09/flashback-table-and-materialized-view.html &gt;Flashback and Materialized View&lt;/a&gt; You might think about other workaround. In FLASHBACK_TRANSACTION_QUERY View there is column with SQL Statement to Undo operation on table. Lets do simple test:
&lt;pre&gt;SQL&gt; insert into a_fb values (1,1);
1 row created.
SQL&gt; commit;
Commit complete.
SQL&gt; delete from a_fb;
1 row deleted.
SQL&gt; commit;&lt;/pre&gt;And now see whats in FLASHBACK_TRANSACTION_QUERY.
&lt;pre&gt;SQL&gt; select commit_scn, operation, row_id, undo_sql
  2  from FLASHBACK_TRANSACTION_QUERY
  3  where table_name = 'A_FB'
  4  order by commit_scn;
COMMIT_SCN OPERATION                        ROW_ID                              
---------- -------------------------------- -------------------                 
UNDO_SQL                                                                        
--------------------------------------------------------------------------------
    641488 INSERT                           AAAM2dAAEAAAAG9AAA                  
delete from "BARUT"."A_FB" where ROWID = 'AAAM2dAAEAAAAG9AAA';                  
                                                                                
    641571 DELETE                           AAAM2dAAEAAAAG9AAA                  
insert into "BARUT"."A_FB"("ID","TEXT") values ('1','1'); &lt;/pre&gt;
&lt;i&gt;To run above query You need SELECT ANY TRANSACTION privilege&lt;/i&gt;&lt;br /&gt;
So now instead of issuing FLASHBACK TABLE A_FB to SCN 641400 You may run statements from UNDO_SQL:
&lt;pre&gt;insert into "BARUT"."A_FB"("ID","TEXT") values ('1','1');
delete from "BARUT"."A_FB" where ROWID = 'AAAM2dAAEAAAAG9AAA';&lt;/pre&gt;
But it will not work! Because when you insert new row usually it will get new row id
&lt;pre&gt;SQL&gt; select rowid, id from a_fb;

ROWID                      ID                                                   
------------------ ----------                                                   
AAAM2dAAEAAAAG9AAB          1&lt;/pre&gt;
So when issuing Delete statement you must map old rowid to that new one. When you do Flashback on Table oracle manages it internally. But when you use UNDO_SQL you must take care for all details. So be careful with that…

&lt;br /&gt;&lt;br /&gt;Cheers, Paweł
&lt;p&gt;Related articles:
&lt;ul&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/09/flashback-table-and-materialized-view.html"&gt;Flashback Table and Materialized View – not working together&lt;/a&gt;
&lt;/li&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html"&gt;Rolling Back the DDL&lt;/a&gt;
&lt;/li&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/10/more-on-flashback.html"&gt;More on Flashback&lt;/a&gt;
&lt;/li&gt;&lt;/ul&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-2962964059618576774?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/2962964059618576774/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=2962964059618576774' title='2 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2962964059618576774'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/2962964059618576774'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/10/undosql-in-flashbacktransactionquery.html' title='UNDO_SQL in FLASHBACK_TRANSACTION_QUERY'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>2</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-8424125391582730584</id><published>2006-09-30T15:35:00.000+02:00</published><updated>2006-09-30T15:39:33.044+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='about'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>13 – Happy or Unhappy Number?</title><content type='html'>This is my 13 post. So I’ve decided to make some digression. Usually number 13 is considered as unhappy. It seems not a rule for me. This year 13 is my happy number. On 13th January I’ve signed new job contract. It was just about 13:15 (or might be it was exactly at 13:13). What is more interesting, sum of digits in that date (13-01-2006) is equal to 13 (1+3+0+1+2+0+0+6=13). Number of building I’m now working in is also 13. As for now I’m quite happy in my new job.
&lt;br /&gt;Also according to &lt;a href=http://www.wschnei.de/digit-related-numbers/happy-numbers.html&gt;Walter Schneider&lt;/a&gt; 13 is definitely happy number. I’ve observed that for me the unhappiest day in month is 26th. In fact it is 2*13. When I use Walters method to it gives me: 26 =&gt; 40 (2*2+6*6) =&amp;gt; 16 =&amp;gt; 37 =&amp;gt; 58 =&amp;gt; 89 =&amp;gt; 145 =&amp;gt; 42 =&amp;gt; 20 =&amp;gt; 4. So 26 is unhappy number and it confirms my observations :).
&lt;br /&gt;More on &lt;a href=http://en.wikipedia.org/wiki/Happy_Numbers&gt;Happy Numbers in Wikipedia&lt;/a&gt;. 

&lt;br /&gt;&lt;br /&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-8424125391582730584?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/8424125391582730584/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=8424125391582730584' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8424125391582730584'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/8424125391582730584'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/13-happy-or-unhappy-number.html' title='13 – Happy or Unhappy Number?'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6817839950323465880</id><published>2006-09-30T00:11:00.000+02:00</published><updated>2006-09-30T00:15:34.697+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='flashback'/><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Flashback Table and Materialized View – not working together</title><content type='html'>I must say that I like Flashback features very much. This is very useful option and should be used more often. But sometimes you might hit some obstacles. One of them is Materialized view. When You want to issue FLASHBACK TABLE statement on table that has materialized view it does not work.
&lt;br /&gt;Lets try:
&lt;pre&gt;SQL&gt; create table a_fb 
  2  (id number primary key, text char(200)) &lt;b&gt;enable row movement&lt;/b&gt;;
Table created.
SQL&gt; create materialized view log on a_fb with rowid;
Materialized view log created.&lt;/pre&gt;
Now insert some data:
&lt;pre&gt;SQL&gt; insert into a_fb select object_id, object_name
  2  from all_objects where rownum &lt;= 100;
100 rows created.
SQL&gt; commit;
Commit complete.
SQL&gt; select sys.dbms_flashback.get_system_change_number,
  2  min(id), max(id), count(*)
  3  from a_fb;
GET_SYSTEM_CHANGE_NUMBER    MIN(ID)    MAX(ID)   COUNT(*)                       
------------------------ ---------- ---------- ----------                       
                  &lt;b&gt;568668&lt;/b&gt;        258       1069        100                       &lt;/pre&gt;
ok. Lets insert more data and then try to flashback to above SCN.
&lt;pre&gt;SQL&gt; insert into a_fb select object_id, object_name
  2  from all_objects where rownum &lt;= 100
  3  and object_id not in(select id from a_fb);
100 rows created.
SQL&gt; commit;
Commit complete.
SQL&gt; select sys.dbms_flashback.get_system_change_number,
  2  min(id), max(id), count(*)
  3  from a_fb;
GET_SYSTEM_CHANGE_NUMBER    MIN(ID)    MAX(ID)   COUNT(*)                       
------------------------ ---------- ---------- ----------                       
                  568704        258       1257        200                       &lt;/pre&gt;
And now flashback:
&lt;pre&gt;SQL&gt; flashback table a_fb to scn &lt;b&gt;568668&lt;/b&gt;;
Flashback complete.&lt;/pre&gt;
It seems that Materialized view log is not a problem. Moreover when FLASHBACK TABLE is executed new rows are inserted to Materialized view log. You can check it issuing this select:
&lt;pre&gt;select count(*) from MLOG$_A_FB;&lt;/pre&gt;
Now lets try to create materialized view
&lt;pre&gt;SQL&gt; create materialized view a_fb_mv
  2  REFRESH FAST ON COMMIT with rowid
  3  as
  4  select id, text, rowid a_rowid from a_fb;
Materialized view created.
SQL&gt; select sys.dbms_flashback.get_system_change_number,
  2  min(id), max(id), count(*)
  3  from a_fb;
GET_SYSTEM_CHANGE_NUMBER    MIN(ID)    MAX(ID)   COUNT(*)                       
------------------------ ---------- ---------- ----------                       
                  &lt;b&gt;568852&lt;/b&gt;        258       1069        100                       &lt;/pre&gt;
Lets add some data and roll back to that SCN
&lt;pre&gt;SQL&gt; insert into a_fb select object_id, object_name
  2  from all_objects where rownum &lt;= 100
  3  and object_id not in(select id from a_fb);
100 rows created.
SQL&gt; commit;
Commit complete.
SQL&gt; select sys.dbms_flashback.get_system_change_number,
  2  min(id), max(id), count(*)
  3  from a_fb;
GET_SYSTEM_CHANGE_NUMBER    MIN(ID)    MAX(ID)   COUNT(*)                       
------------------------ ---------- ---------- ----------                       
                  568893        258       1257        200                       &lt;/pre&gt;
Lets see what we have in Materialized view:
&lt;pre&gt;SQL&gt; select sys.dbms_flashback.get_system_change_number,
  2  min(id), max(id), count(*)
  3  from a_fb_mv;
GET_SYSTEM_CHANGE_NUMBER    MIN(ID)    MAX(ID)   COUNT(*)                       
------------------------ ---------- ---------- ----------                       
                  568895        258       1257        200                       &lt;/pre&gt;
&lt;h2&gt;Problem&lt;/h2&gt;
Try to flashback:
&lt;pre&gt;SQL&gt; flashback table a_fb to scn  &lt;b&gt;568852&lt;/b&gt;;
flashback table a_fb to scn  568852
                *
ERROR at line 1:
&lt;b&gt;ORA-08194&lt;/b&gt;: Flashback Table operation is not allowed on materialized views &lt;/pre&gt;
You cannot flashback table if there is materialized view defined on it. But materialized view log is not a problem. I must say that I do not see any reason for that. If materialized view log is generated during flashback operation why materialized view is not updated according to that log?
&lt;h2&gt;Workaround&lt;/h2&gt;
This is quite simple. You just have to drop materialized view and issue flashback table statement:
&lt;pre&gt;SQL&gt; drop materialized view a_fb_mv;
Materialized view dropped.
SQL&gt; flashback table a_fb to scn  &lt;b&gt;568852&lt;/b&gt;;
Flashback complete.
SQL&gt; select sys.dbms_flashback.get_system_change_number,
  2  min(id), max(id), count(*)
  3  from a_fb;
GET_SYSTEM_CHANGE_NUMBER    MIN(ID)    MAX(ID)   COUNT(*)                       
------------------------ ---------- ---------- ----------                       
                  569009        258       1069        100                       &lt;/pre&gt;
Now you need only to recreate dropped materialized view.
&lt;p&gt;Related articles:
&lt;ul&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/10/undosql-in-flashbacktransactionquery.html"&gt;UNDO_SQL in FLASHBACK_TRANSACTION_QUERY&lt;/a&gt;
&lt;/li&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/09/rolling-back-ddl.html"&gt;Rolling Back the DDL&lt;/a&gt;
&lt;/li&gt;&lt;li&gt;&lt;a href="http://pbarut.blogspot.com/2006/10/more-on-flashback.html"&gt;More on Flashback&lt;/a&gt;
&lt;/li&gt;&lt;/ul&gt;&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6817839950323465880?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6817839950323465880/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6817839950323465880' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6817839950323465880'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6817839950323465880'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/flashback-table-and-materialized-view.html' title='Flashback Table and Materialized View – not working together'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4682146943187433063</id><published>2006-09-21T00:02:00.000+02:00</published><updated>2007-03-22T23:38:20.537+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ora_rowscn'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>ORA_ROWSCN continuation…</title><content type='html'>In my &lt;a href="http://pbarut.blogspot.com/2006/09/orarowscn-is-pseudo-column-that-gives.html"&gt;previous post&lt;/a&gt; I was wondering how SCN is assigned to ROW or Block. I couldn’t find explanation in Oracle Documentation. But I’ve found &lt;a href="http://www.jlcomp.demon.co.uk/cleanout.html"&gt;this document&lt;/a&gt; written by Jonathan Lewis. You should read this! I’m little afraid about 'best guess' technology.&lt;br /&gt;
By the way you can also read article about &lt;a href="http://www.jlcomp.demon.co.uk/commit.html"&gt;undocumented userenv('commitscn')&lt;/a&gt; written in May 1999. When I first saw it I thought it might be replaced by ORA_ROWSCN.&lt;br /&gt;
So I’ve try this:&lt;pre&gt;SQL&gt; create table t (n1 number, text varchar2(10)) ROWDEPENDENCIES;

Table created.

SQL&gt; insert into t values (userenv('commitscn'), 'T1');

1 row created.

SQL&gt; select ora_rowscn, n1 commitscn, text from t;

ORA_ROWSCN  COMMITSCN TEXT                                                     
---------- ---------- ----------                                               
             &lt;b&gt;4621851&lt;/b&gt; T1                                                       

SQL&gt; declare
 2    pragma autonomous_transaction;
 3  begin
 4    insert into t values (userenv('commitscn'), 'TAuto');
 5    commit;
 6  end;
 7  /

PL/SQL procedure successfully completed.

SQL&gt; select ora_rowscn, n1 commitscn, text from t;

ORA_ROWSCN  COMMITSCN TEXT                                                     
---------- ---------- ----------                                               
             &lt;b&gt;4621851&lt;/b&gt; T1                                                       
  4621852    4621851 TAuto                                                    

SQL&gt; commit;

Commit complete.

SQL&gt; select ora_rowscn, n1 commitscn, text from t;

ORA_ROWSCN  COMMITSCN TEXT                                                     
---------- ---------- ----------                                               
  4621854    &lt;b&gt;4621853&lt;/b&gt; T1                                                       
  4621852    4621851 TAuto
&lt;/pre&gt;
So for sure ORA_ROWSCN and userenv('commitscn') is not the same. I must say that I’m even more confused.
&lt;br /&gt;&lt;br /&gt;If You have some spare time, I recommend to read this post:
&lt;a href="http://www.escapefromcubiclenation.com/get_a_life_blog/2006/09/is_it_crazy_to_.html"&gt;Is it crazy to feel guilty about success?&lt;/a&gt;
and from Eddie Awad blog:
&lt;a href="http://awads.net/wp/2006/09/19/cool-undocumented-sql-function-sys_op_map_nonnull-and-some-alternatives/"&gt;SYS_OP_MAP_NONNULL&lt;/a&gt;, 
&lt;a href="http://awads.net/wp/2006/08/30/cool-undocumented-sql-function-reverse/"&gt;REVERSE&lt;/a&gt;, 
&lt;a href="http://awads.net/wp/2006/05/02/undocumented-lnnvl-sql-function-now-safe-to-use/"&gt;LNNVL&lt;/a&gt;, 
&lt;a href="http://awads.net/wp/2006/01/27/nvl-nvl2-or-coalesce/"&gt;NVL, NVL2, COALESCE&lt;/a&gt;
&lt;br /&gt;&lt;br /&gt;
Cheers, Paweł&lt;/p&gt;&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4682146943187433063?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://pbarut.blogspot.com/2006/09/orarowscn-is-pseudo-column-that-gives.html' title='ORA_ROWSCN continuation…'/><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4682146943187433063/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4682146943187433063' title='1 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4682146943187433063'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4682146943187433063'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/orarowscn-continuation.html' title='ORA_ROWSCN continuation…'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>1</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-6150645974392288557</id><published>2006-09-17T15:21:00.000+02:00</published><updated>2007-03-22T23:38:20.538+01:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='ora_rowscn'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>ORA_ROWSCN behavior: bug or feature?</title><content type='html'>ORA_ROWSCN is pseudo column that gives SCN (System Change Number) for transaction that was modifying record. Lets take a closer look. First create table:
&lt;pre&gt; CREATE TABLE A_TABLE
   (ID NUMBER, TEXT CHAR(2000));&lt;/pre&gt;
Then feed table with some data:
&lt;pre&gt;SQL&gt; declare
  2    procedure auto_commit
  3    is pragma autonomous_transaction;
  4    begin commit; end;
  5  begin
  6    for i in 1..10 loop
  7      insert into a_table select rownum, rownum 
from dual connect by level &lt;=10;
  8      auto_commit;
  9    end loop;
 10  end;
 11  /&lt;/pre&gt;
Procedure auto_commit is used to force change of SCN. Take a look what we have in table:
&lt;pre&gt;SQL&gt; select ora_rowscn, count(*) from a_table
  2  group by ora_rowscn;

ORA_ROWSCN   COUNT(*)                                                           
---------- ----------                                                           
   4589308         24                                                           
   4589313         16                                                           
   4589293         15                                                           
   4589297         24                                                           
   4589302         21                                                           
&lt;/pre&gt;
We ran INSERT statement 10 times and we get 5 different SCN’s in table. None of them has exactly 10 rows. This is because table was created with default setting: NOROWDEPENDENCIES, and SCN is kept on block level. Every and each row in block has the same SCN. Lets commit this transaction:
&lt;pre&gt;SQL&gt; commit;

Commit complete.

SQL&gt; select ora_rowscn, count(*) from a_table
  2  group by ora_rowscn;

ORA_ROWSCN   COUNT(*)                                                           
---------- ----------                                                           
   4589363        100                                                           
&lt;/pre&gt;
Now all rows haveexactly the same SCN.&lt;br /&gt;
Now lets take a look what will happen for table with ROWDEPENDENCIES on.
&lt;pre&gt; CREATE TABLE A_TABLE_ROW
   (ID NUMBER, TEXT CHAR(2000)) ROWDEPENDENCIES;&lt;/pre&gt;
Insert some data:
&lt;pre&gt;SQL&gt; declare
  2    procedure auto_commit
  3    is pragma autonomous_transaction;
  4    begin commit; end;
  5  begin
  6    for i in 1..10 loop
  7      insert into A_TABLE_ROW select rownum, rownum 
from dual connect by level &lt;=10;
  8      auto_commit;
  9    end loop;
 10  end;
 11  /
&lt;/pre&gt;
Query table:
&lt;pre&gt;SQL&gt; select ora_rowscn, count(*) from A_TABLE_ROW
  2  group by ora_rowscn;

ORA_ROWSCN   COUNT(*)                                                           
---------- ----------                                                           
                  100                                                           
&lt;/pre&gt;
Now ORA_ROWSCN is NULL for uncommitted transaction. This is very interesting.
&lt;pre&gt;SQL&gt; commit;

Commit complete.

SQL&gt; select ora_rowscn, count(*) from A_TABLE_ROW
  2  group by ora_rowscn;

ORA_ROWSCN   COUNT(*)                                                           
---------- ----------                                                           
   4590773        100                                                           
&lt;/pre&gt;
What will happen when updating:
&lt;pre&gt;SQL&gt; update A_TABLE_ROW set id = id where rownum &lt;20;

19 rows updated.

SQL&gt; select ora_rowscn, count(*) from A_TABLE_ROW
  2  group by ora_rowscn;

ORA_ROWSCN   COUNT(*)
---------- ----------
                   19
   4590773         81
&lt;/pre&gt;We can conclude that data in active transaction have NULL ORA_ROWSCN for tables with ROWDEPENDENCY.
&lt;br /&gt;What about Index Organized Tables:
&lt;pre&gt; CREATE TABLE A_TABLE_IOT
   (ID NUMBER primary key, TEXT CHAR(2000)) organization index;
&lt;/pre&gt;Generate data:&lt;pre&gt; SQL&gt; declare
  2    procedure auto_commit
  3    is pragma autonomous_transaction;
  4    begin commit; end;
  5  begin
  6    for i in 1..10 loop
  7      insert into A_TABLE_IOT select i*10+rownum, rownum 
from dual connect by level &lt;=10;
  8      auto_commit;
  9    end loop;
 10  end;
 11  /

PL/SQL procedure successfully completed.

SQL&gt; select ora_rowscn, count(*) from A_TABLE_IOT
  2  group by ora_rowscn;

ORA_ROWSCN   COUNT(*)
---------- ----------
                  100
&lt;/pre&gt;For IOT with NOROWDEPENDENCIES we still get NULLs for ORA_ROWSCN.&lt;h2&gt;Questions:&lt;/h2&gt;1. Why we have such differences in implementation of ORA_ROWSCN?
&lt;br /&gt;2. We can see that SCN is assigned at commit. Does commit tackles all blocks modified by transaction? For short transaction it is not a problem, as blocks probably are still in buffer. But large transactions that generate lot of redo, and there are few check points during transaction time should not change this blocks. That means that block should have only transaction id, and oracle translates this transaction id to SCN.
&lt;br/&gt;&lt;br /&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-6150645974392288557?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/6150645974392288557/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=6150645974392288557' title='3 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6150645974392288557'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/6150645974392288557'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/orarowscn-is-pseudo-column-that-gives.html' title='ORA_ROWSCN behavior: bug or feature?'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>3</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5411253850360346464</id><published>2006-09-14T22:24:00.000+02:00</published><updated>2006-09-14T22:26:56.271+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Avoiding Deadlocks: SKIP LOCKED</title><content type='html'>After reading Tim's article on &lt;a href="http://www.oracle-base.com/blog/2006/09/13/deadlocks/"&gt;Deadlocks&lt;/a&gt;, I've recalled solution that can help avoid deadlocks in some situations.&lt;br /&gt;
Assume that in our application we have to choose few (say 5) documents from pool to assign to users for processing. Usually we can use just update statement like that:&lt;pre&gt;
UPDATE documents
SET doc_state = 'ASSIGNED',
  doc_user = USER
WHERE doc_state = 'TO PROCESS'
 AND rownum &lt;= 5;
&lt;/pre&gt;
But this can cause some waits in highly loaded environments where this statement is run often. To overcome that we can use &lt;b&gt;SKIP LOCKED&lt;/b&gt; clause:&lt;pre&gt;
BEGIN
  FOR r IN
    (SELECT id FROM documents
     WHERE doc_state = 'TO PROCESS'
     AND rownum &lt;= 5 &lt;b&gt;FOR UPDATE SKIP LOCKED&lt;/b&gt;) LOOP
    UPDATE documents
    SET doc_state = 'ASSIGNED',
      doc_user = USER
    WHERE id = r.id;
  END LOOP;
END;
&lt;/pre&gt;In this statement we do not suffer from waits, and we get up to 5 rows assigned to current user.&lt;br /&gt;&lt;br /&gt;
Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5411253850360346464?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5411253850360346464/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5411253850360346464' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5411253850360346464'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5411253850360346464'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/avoiding-deadlocks-skip-locked.html' title='Avoiding Deadlocks: SKIP LOCKED'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-4248167583181240607</id><published>2006-09-13T23:59:00.000+02:00</published><updated>2006-09-14T00:05:30.049+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='other'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Binary Days</title><content type='html'>As addition to may previous post lets see other Binary days, where day number is power of 2.
&lt;pre&gt;
SQL&gt; select rownum-1 power_of2
  2  , to_char(trunc(sysdate,'YYYY')-1+power(2,rownum-1),
  3    'DD-MON-YYYY DAY')  magic_day
  4  from dual connect by level &lt;=9;

 POWER_OF2 MAGIC_DAY
---------- ---------------------------------------------------------
         0 01-JAN-2006 SUNDAY
         1 02-JAN-2006 MONDAY
         2 04-JAN-2006 WEDNESDAY
         3 08-JAN-2006 SUNDAY
         4 16-JAN-2006 MONDAY
         5 01-FEB-2006 WEDNESDAY
         6 05-MAR-2006 SUNDAY
         7 08-MAY-2006 MONDAY
         8 13-SEP-2006 WEDNESDAY

9 rows selected.
&lt;/pre&gt;
Interesting coincidence - there are only 3 days of week: SUNDAY, MONDAY and WEDNESDAY.
&lt;br /&gt;
&lt;br /&gt;BTW. Does anybody know if is it possible to turn off these automatic &amp;lt;br /&amp;gt; tags in beta blogger?
&lt;br /&gt;
&lt;br /&gt;Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-4248167583181240607?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='related' href='http://pbarut.blogspot.com/2006/09/programmers-day.html' title='Binary Days'/><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/4248167583181240607/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=4248167583181240607' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4248167583181240607'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/4248167583181240607'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/binary-days.html' title='Binary Days'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5993965473721536736</id><published>2006-09-13T19:54:00.000+02:00</published><updated>2006-09-13T19:56:51.522+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='other'/><title type='text'>Programmers Day</title><content type='html'>Today is 256th day of year. It is considered as &lt;a href="http://en.wikipedia.org/wiki/Programmers_day"&gt;Programmers Day&lt;/a&gt;. Let's celebrate...
&lt;br /&gt;
&lt;br /&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5993965473721536736?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5993965473721536736/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5993965473721536736' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5993965473721536736'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5993965473721536736'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/programmers-day.html' title='Programmers Day'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry><entry><id>tag:blogger.com,1999:blog-4677316190423110840.post-5851955170626445254</id><published>2006-09-12T22:44:00.000+02:00</published><updated>2006-09-12T22:53:06.539+02:00</updated><category scheme='http://www.blogger.com/atom/ns#' term='programming'/><category scheme='http://www.blogger.com/atom/ns#' term='oracle'/><title type='text'>Row Generators</title><content type='html'>You probably now all &lt;a href="http://orafaq.com/wiki/Oracle_Row_Generator_Techniques"&gt;these methods&lt;/a&gt; to generate rows.
I've decided to choose the best method.
My criterias are:&lt;ul&gt;&lt;li&gt;Maximum Speed&lt;/li&gt;&lt;li&gt;Without limitations&lt;/li&gt;&lt;li&gt;Easy of use&lt;/li&gt;&lt;/ul&gt;To measure time I use PL/SQL block:
&lt;pre&gt;declare
v_start_time  timestamp;
v_end_time    timestamp;
v_max_number  integer;
v_max_gen     integer;
begin
v_max_number := 1000;
v_max_gen := 0;
v_start_time := systimestamp;
for r in (&lt;b&gt;QUERY_HERE&lt;/b&gt;) loop
  v_max_gen := r.r;
end loop;
v_end_time := systimestamp;
dbms_output.put_line('Max gen = '||v_max_gen);
dbms_output.put_line('Time = '||(v_end_time-v_start_time));
end;&lt;/pre&gt;
Where &lt;b&gt;QUERY_HERE&lt;/b&gt; was one of:
&lt;table&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td valign="top"&gt;ALL_OBJECTS&lt;/td&gt;&lt;td&gt;&lt;pre&gt;select rownum r from all_objects where rownum &lt;= v_max_number&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign="top"&gt;2*ALL_OBJECTS&lt;/td&gt;&lt;td&gt;&lt;pre&gt;select rownum r from all_objects, all_objects where rownum &lt;= v_max_number&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt;&lt;td valign="top"&gt;group by cube&lt;/td&gt;&lt;td&gt;&lt;pre&gt;select rownum r from (select 1 from dual 
group by cube(1,2,3,4,5,6,7,8,9,10,11,12,13,14)) where rownum &lt;= v_max_number&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td valign="top"&gt;level&lt;/td&gt;&lt;td&gt;&lt;pre&gt;select level r from dual connect by level &lt;= v_max_number&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td valign="top"&gt;PL/SQL Function&lt;/td&gt;&lt;td&gt;&lt;pre&gt;select rownum r from table(rowgen(v_max_number))&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td&gt;
&lt;/td&gt;&lt;td&gt;where function was created using:
 &lt;pre&gt;CREATE OR REPLACE TYPE numtab_type IS TABLE OF NUMBER;

CREATE or replace FUNCTION rowgen(pin_nor IN NUMBER)
RETURN numtab_type DETERMINISTIC PIPELINED
AS
BEGIN
FOR i IN 1..pin_nor
LOOP
  PIPE ROW(i);
END LOOP;
RETURN;
END rowgen;
/
&lt;/pre&gt;&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
My Results, all times in seconds
&lt;table border="1"&gt;&lt;tbody&gt;&lt;tr&gt; &lt;td&gt;Method/Rows&lt;/td&gt;  &lt;td&gt;1000 rows&lt;/td&gt;  &lt;td&gt;10000 rows&lt;/td&gt;  &lt;td&gt;1000000 rows&lt;/td&gt;  &lt;td&gt;Comment&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt;ALL_OBJECTS&lt;/td&gt; &lt;td&gt;0.1&lt;/td&gt; &lt;td&gt;(*)&lt;/td&gt; &lt;td&gt;(*)&lt;/td&gt; &lt;td&gt;(*) only 5292 rows generated. We cannot generate big number of rows&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt;2*ALL_OBJECTS&lt;/td&gt; &lt;td&gt;0.2&lt;/td&gt; &lt;td&gt;0.7&lt;/td&gt; &lt;td&gt;66.2&lt;/td&gt; &lt;td&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt;group by cube&lt;/td&gt; &lt;td&gt;0&lt;/td&gt; &lt;td&gt;0.1&lt;/td&gt; &lt;td&gt;&amp;gt; 5 min&lt;/td&gt; &lt;td&gt;Number of elements in cube clause vary on how big numbers we want get.
For big numbers it is slow and not flexible in setting.&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt;level&lt;/td&gt; &lt;td&gt;0&lt;/td&gt; &lt;td&gt;0.1&lt;/td&gt; &lt;td&gt;2.8&lt;/td&gt; &lt;td&gt;&lt;/td&gt;&lt;/tr&gt;&lt;tr&gt; &lt;td&gt;PL/SQL Function&lt;/td&gt; &lt;td&gt;0&lt;/td&gt; &lt;td&gt;0.1&lt;/td&gt;&lt;td&gt;2.2&lt;/td&gt;&lt;td&gt;We have to create Type and Function&lt;/td&gt;&lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;
&lt;h2&gt;Conclusion&lt;/h2&gt;
If we consider speed, we should use one of two methods: &lt;b&gt;level&lt;/b&gt; or &lt;b&gt;PL/SQL Function&lt;/b&gt;.
When we also consider the Easy of use we have only one solution &lt;b&gt;select level r from dual connect by level &lt;= v_max_number&lt;/b&gt;
&lt;br /&gt;
&lt;br /&gt;Cheers, Paweł&lt;div class="blogger-post-footer"&gt;&lt;img width='1' height='1' src='https://blogger.googleusercontent.com/tracker/4677316190423110840-5851955170626445254?l=pbarut.blogspot.com' alt='' /&gt;&lt;/div&gt;</content><link rel='replies' type='application/atom+xml' href='http://pbarut.blogspot.com/feeds/5851955170626445254/comments/default' title='Post Comments'/><link rel='replies' type='text/html' href='http://www.blogger.com/comment.g?blogID=4677316190423110840&amp;postID=5851955170626445254' title='0 Comments'/><link rel='edit' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5851955170626445254'/><link rel='self' type='application/atom+xml' href='http://www.blogger.com/feeds/4677316190423110840/posts/default/5851955170626445254'/><link rel='alternate' type='text/html' href='http://pbarut.blogspot.com/2006/09/row-generators.html' title='Row Generators'/><author><name>Paweł Barut</name><uri>http://www.blogger.com/profile/16867021334037413869</uri><email>noreply@blogger.com</email><gd:image rel='http://schemas.google.com/g/2005#thumbnail' width='31' height='32' src='http://www.barut.info/pic/pawel_2007_07-29_300.jpg'/></author><thr:total>0</thr:total></entry></feed>
