<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>blog.mycado.fr &#187; IBM</title>
	<atom:link href="http://blog.mycado.fr/tag/ibm/feed/" rel="self" type="application/rss+xml" />
	<link>http://blog.mycado.fr</link>
	<description>Just another WordPress weblog</description>
	<lastBuildDate>Wed, 28 Oct 2009 12:21:58 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.4</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Queries on XML data with XQuery</title>
		<link>http://blog.mycado.fr/2009/08/queries-on-xml-data-with-xquery/</link>
		<comments>http://blog.mycado.fr/2009/08/queries-on-xml-data-with-xquery/#comments</comments>
		<pubDate>Wed, 26 Aug 2009 14:09:32 +0000</pubDate>
		<dc:creator>Stéphane Journot</dc:creator>
				<category><![CDATA[IBM DB2]]></category>
		<category><![CDATA[DB2]]></category>
		<category><![CDATA[IBM]]></category>
		<category><![CDATA[XML]]></category>
		<category><![CDATA[XQuery]]></category>

		<guid isPermaLink="false">http://blog.mycado.fr/?p=84</guid>
		<description><![CDATA[We know how to store native XML data in our DB2 tables, and now we will see how we can access to these data. We can choose between standard SQL queries and XQuery.. or both ! The first solution, with a SQL query, only query at the column level of your table; this query will [...]]]></description>
			<content:encoded><![CDATA[<p>We know how to <a title="Store native XML in DB2 table" href="http://blog.mycado.fr/2009/08/stocker-du-xml-natif-dans-un-table-db2/" target="_blank">store native XML data in our DB2 tables</a>, and now we will see how we can access to these data. We can choose between standard SQL queries and <strong>XQuery</strong>.. or both ! The first solution, with a SQL query, only query at the column level of your table; this query will return the full XML data. The second solution, with XQuery, allow us to make a &#8220;query&#8221; inside our XML data.</p>
<p>For the SQL query, nothing more than a <strong>SELECT</strong>:</p>
<pre>SELECT id, info from client</pre>
<p>Easy, but not really powerful for XML data, let&#8217;s try with XQuery, who give us two functions for DB2. <strong>db2-fn:sqlquery</strong> and <strong>db2-fn:xmlcolumn</strong>. The first function r<span>etrieves a sequence that is the result of an SQL fullselect and the second </span><span>retrieves a sequence from a column</span><span>. One important thing you should keep in mind, SQL is not a case-sensitive language alors que XQuery is a case-sensitive language.<br />
</span></p>
<p>An example which return all the XML data from the &#8220;<strong>info</strong>&#8221; column:</p>
<pre>XQUERY db2-fnxmlcolumn ('CLIENT.INFO')</pre>
<p>Which is same as this SQL query:</p>
<pre>SELECT info FROM client</pre>
<p>Let&#8217;s see something more nice. This query will return all the elements in &lt;<strong>name</strong>&gt; , inside the &#8220;info&#8221; column, and with the &lt;<strong>city</strong>&gt; element which containt &#8220;Paris&#8221;:</p>
<pre>XQUERY declare defaut element namespace "http://posample.org";
for $d in db2-fn:xmlcolumn('CLIENT.INFO')/clientinfo
  where $d/addr/city="Paris"
return &lt;out&gt;{$d/name}&lt;/out&gt;</pre>
<p>db2-fn:xmlcolumn retrieves the data from the &#8220;info&#8221; column in the &#8220;client&#8221; table. We add a $d variable, for each element of &lt;clientinfo&gt;, and we use a <strong>where</strong> to filter the &lt;<strong>city</strong>&gt; element which should be &#8220;Paris. To finish, we use &lt;<strong>out</strong>&gt; to output the data:</p>
<pre>&lt;out xmlns="http://posample.org"&gt;
  &lt;name&gt;Sophie Bool&lt;/name&gt;
&lt;/out&gt;</pre>
<div>
<p>To finish, the same example with a SQL query inside the XQuery:</p>
<pre>XQUERY declare default element namespace "http://posample.org";
for $d in db2-fn:sqlquery('SELECT info FROM client')/clientinfo
  where $d/addr/city="Paris
return &lt;out&gt;{$d/name}&lt;/out&gt;</pre>
<p>Enough for today, we will see next time how to do more complex and more powerful query with XQuery !</p></div>
]]></content:encoded>
			<wfw:commentRss>http://blog.mycado.fr/2009/08/queries-on-xml-data-with-xquery/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Store native XML in a DB2 table</title>
		<link>http://blog.mycado.fr/2009/08/stocker-du-xml-natif-dans-un-table-db2/</link>
		<comments>http://blog.mycado.fr/2009/08/stocker-du-xml-natif-dans-un-table-db2/#comments</comments>
		<pubDate>Sun, 23 Aug 2009 11:04:26 +0000</pubDate>
		<dc:creator>Stéphane Journot</dc:creator>
				<category><![CDATA[IBM DB2]]></category>
		<category><![CDATA[DB2]]></category>
		<category><![CDATA[IBM]]></category>
		<category><![CDATA[XML]]></category>

		<guid isPermaLink="false">http://blog.mycado.fr/?p=69</guid>
		<description><![CDATA[IBM DB2 is the first RDBMS to provide a native XML facility, in a table. You will be able to insert in a column, some XML data. It will be easier to make direct requests to these data with XQuery.
So, it&#8217;s funny, but why it&#8217;s interesting to do that ? Because XML data are hierarchic [...]]]></description>
			<content:encoded><![CDATA[<p>IBM DB2 is the first RDBMS to provide a native XML facility, in a table. You will be able to insert in a column, some XML data. It will be easier to make direct requests to these data with XQuery.</p>
<p>So, it&#8217;s funny, but why it&#8217;s interesting to do that ? Because XML data are hierarchic (instead of relational data which are flat) and data self-describing through XML tags. XML also allows a better flexibility for data structures required to change very often. In the other hand, access time performances will be a little slower, we lose the integrity constraints, and OLAP queries will be more difficult. The important question is &#8220;Which flexibility-performance ratio do you need ?&#8221;.</p>
<p>Let&#8217;s start now with the creation of a database, which should be encoded with UTF-8, to store XML. For that, we use the <strong>CREATE DATABASE</strong> command:</p>
<pre>CREATE DATABASE xmldb USING CODESET UTF-8 TERRITORY US</pre>
<p>We have our table, now we should create the &#8220;client&#8221; table, with an &#8220;info&#8221; column who contain client information, in XML format:</p>
<pre>CONNECT TO xmldb
CREATE TABLE client (id INT, info XML)</pre>
<p>Let&#8217;s try to insert a new client with a SQL query:</p>
<pre width="69">INSERT INTO client (id, info) VALUES (1, '&lt;clientinfo xmlns="http://posample.org" Cid="1"&gt;&lt;name&gt;Sophie Bool&lt;/name&gt;&lt;addr country="France"&gt;&lt;street&gt;5 rue du chateau de stable&lt;/street&gt;&lt;city&gt;Paris&lt;/city&gt;&lt;/addr&gt;&lt;phone type="work"&gt;01 72 92 02 88&lt;/phone&gt;&lt;/clientinfo&gt;')</pre>
<p>The first thing you will told me is <em>this query is a normal SQL query</em>, and this is right, insert XML isn&#8217;t more difficult. The second thing is about the XML, here we have a short XML data, but if we have more, it will be very difficult to use. This why, we will use XQuery to manipulate these data or use a XDS import. I&#8217;ll come back soon on these points.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mycado.fr/2009/08/stocker-du-xml-natif-dans-un-table-db2/feed/</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
		<item>
		<title>SQL tuning teleconference on September 1 from IBM</title>
		<link>http://blog.mycado.fr/2009/08/sql-tuning-teleconference-on-september-1-from-ibm/</link>
		<comments>http://blog.mycado.fr/2009/08/sql-tuning-teleconference-on-september-1-from-ibm/#comments</comments>
		<pubDate>Sun, 23 Aug 2009 03:11:27 +0000</pubDate>
		<dc:creator>Stéphane Journot</dc:creator>
				<category><![CDATA[IBM DB2]]></category>
		<category><![CDATA[IBM system z]]></category>
		<category><![CDATA[DB2]]></category>
		<category><![CDATA[IBM]]></category>
		<category><![CDATA[system z]]></category>
		<category><![CDATA[teleconference]]></category>

		<guid isPermaLink="false">http://blog.mycado.fr/?p=137</guid>
		<description><![CDATA[A new teleconference from IBM on SQL tuning for DB2 on system z coming on Tuesday, September 1, starting at 3pm (UTC). Aim for application programmers, application development managers, database administrators and database managers,  with an intermediate technical level. With the growing of the IT infrastructure, we must find how can we deliver a scalable, [...]]]></description>
			<content:encoded><![CDATA[<p>A new teleconference from IBM on SQL tuning for DB2 on system z coming on <strong>Tuesday, September 1</strong>, starting at <strong>3pm</strong> (UTC). Aim for application programmers, application development managers, database administrators and database managers,  with an intermediate technical level. With the growing of the IT infrastructure, we must find how can we deliver a <em>scalable, reliable, available and highly secure database infrastructure, in a cost-effective data server environment</em> !</p>
<p>The case study will explain:</p>
<ul>
<li>How the project was started</li>
<li>Which techniques and strategy were used</li>
<li>How follow-up was done</li>
<li>What investments where made</li>
<li>What was the return on investment</li>
</ul>
<p>The speakers are Surekha Parekh, DB2 Market Manager/Strategist, IBM Software Group and Kurt Struyf, Senior Consultant from Competence Partners.</p>
<p>You can register at <a title="IBM SQL Tuning teleconference" href="https://www-950.ibm.com/events/wwe/systemz/sztecsem.nsf/enrollallv16?openform&amp;seminar=kwo311" target="_blank">SQL tuning: the necessity, the benefits, a business case</a>.</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mycado.fr/2009/08/sql-tuning-teleconference-on-september-1-from-ibm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
		<item>
		<title>Get documented with IBM Redbooks</title>
		<link>http://blog.mycado.fr/2009/08/se-documenter-grace-aux-redbook-dibm/</link>
		<comments>http://blog.mycado.fr/2009/08/se-documenter-grace-aux-redbook-dibm/#comments</comments>
		<pubDate>Sun, 16 Aug 2009 13:28:55 +0000</pubDate>
		<dc:creator>Stéphane Journot</dc:creator>
				<category><![CDATA[IBM]]></category>
		<category><![CDATA[redbook]]></category>
		<category><![CDATA[redpaper]]></category>

		<guid isPermaLink="false">http://blog.mycado.fr/?p=55</guid>
		<description><![CDATA[
It&#8217;s always very hard to find good documentation on some products (IBM or else). Internet is really nice, but sometime it&#8217;s the jungle, we can find lot of good, but also lot of bad/false.. Shop sells very good books, but come on.. they&#8217;re too expensive, I&#8217;m student, I can&#8217;t buy 10 or 20 books near [...]]]></description>
			<content:encoded><![CDATA[<p><img class="size-full wp-image-77 alignnone" title="Redbooks" src="http://blog.mycado.fr/wp-content/uploads/2009/08/rb170x32.gif" alt="IBM Redbooks" width="170" height="32" /></p>
<p>It&#8217;s always very hard to find good documentation on some products (IBM or else). Internet is really nice, but sometime it&#8217;s the jungle, we can find lot of good, but also lot of bad/false.. Shop sells very good books, but come on.. they&#8217;re too expensive, I&#8217;m student, I can&#8217;t buy 10 or 20 books near 50/60€ each..</p>
<p>Hopefully, IBM have a huge ebook library named Redbooks. There are 5 kinds of IBM ebook, first is the classic RedBook, it&#8217;s a guide on one or multiple producs, Drat are RedBook in beta version, RedPapers are short technical articles, RedGuides are a kind of praticals business example, and TechNotes are brief technical help on something very precise.</p>
<p>IBM have more than 5.000 RedBooks, in 2008 more than 400 Redbooks have been published. Each month, more than 500.000 ebooks and 100.000 RedPapers are downloaded.</p>
<p>Here are some &#8220;must have&#8221; Redbooks:</p>
<ul>
<li><a title="IBM Redbook DB2 Linux" href="http://www.redbooks.ibm.com/Redbooks.nsf/RedbookAbstracts/sg246899.html?OpenDocument" target="_blank">Up and Running with DB2 on Linux</a></li>
<li><a title="IBM Redbook VSAM" href="http://www.redbooks.ibm.com/Redbooks.nsf/RedbookAbstracts/sg246105.html?OpenDocument" target="_blank">VSAM Demystified</a></li>
<li><a title="IBM Redbook DB2 9 z/OS" href="http://www.redbooks.ibm.com/Redbooks.nsf/RedbookAbstracts/sg247330.html?OpenDocument" target="_blank">DB2 9 for z/OS Technical Overview</a></li>
<li><a title="IBM Redbook ABC z/OS vol 1" href="http://www.redbooks.ibm.com/Redbooks.nsf/RedbookAbstracts/sg246981.html?OpenDocument" target="_blank">ABCs of z/OS System Programming Volume 1</a> (on 11)</li>
<li><a title="IBM Redbook DB2 9 z/OS perf" href="http://www.redbooks.ibm.com/Redbooks.nsf/RedbookAbstracts/sg247473.html?OpenDocument" target="_blank">DB2 9 for z/OS Performance Topics</a></li>
</ul>
<p>And, the most important, all these ebooks are free !</p>
]]></content:encoded>
			<wfw:commentRss>http://blog.mycado.fr/2009/08/se-documenter-grace-aux-redbook-dibm/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>
