<?xml version="1.0" encoding="utf-8"?>
<rss xmlns:atom="http://www.w3.org/2005/Atom" version="2.0"><channel><title>Eddie Awad’s Blog - Latest Comments in When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.disqus.com/</link><description>News, views, tips and tricks on Oracle and other fun stuff</description><atom:link href="https://awads.disqus.com/when_ansi_sql_join_syntax_does_not_work_in_oracle/latest.rss" rel="self"></atom:link><language>en</language><lastBuildDate>Tue, 07 Oct 2008 09:26:38 -0000</lastBuildDate><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659202</link><description>&lt;p&gt;I personally prefer Oracle's was because it’s easy to read, and i personally find the ANSI syntax to be very hard to follow especially once it starts to nest.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Brian Tkatch</dc:creator><pubDate>Tue, 07 Oct 2008 09:26:38 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659201</link><description>&lt;p&gt;Juanky, you meant writng SQL not PL/SQL, right? Performance should be the same unless proven otherwise. I personally prefer ANSI SQL because it's easier to read.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Eddie Awad</dc:creator><pubDate>Mon, 06 Oct 2008 23:54:25 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659199</link><description>&lt;p&gt;Question? What syntax is more efficient for writing PLSQL... ANSI or the old Oracle way?? When I say efficient is performance, and maintainability wise..&lt;br&gt;Thanks&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Juanky</dc:creator><pubDate>Mon, 06 Oct 2008 11:18:53 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659200</link><description>&lt;p&gt;Take a look at the Query itself... putting a (+) on the Left Side does not mean a LEFT OUTER JOIN as you have written... i mean for example in the old way if we put the (+) on RIGHT side that actually should interprete as LEFT OUTER JOIN keeping the Tables in the same sqquence... so please check the Query itself... sould work... simple stuff!&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Sanjay</dc:creator><pubDate>Thu, 07 Aug 2008 06:41:01 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659198</link><description>&lt;p&gt;I'm experiencing this problem and it erks me that I have to switch my queries from ANSI to non-ANSI.  However it erks me even more that I have to deal with a table with over 300 columns!!!  I find it staggering that any professional organisation that relies on such a database for mission critical operations involving billions for euros can allow such a thing to happen.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Paul Hartness</dc:creator><pubDate>Wed, 20 Feb 2008 04:24:54 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659197</link><description>&lt;p&gt;Nice looking site providing detailled information about sql syntax: &lt;a href="www.sqlexikon.de" rel="nofollow noopener" target="_blank" title="www.sqlexikon.de"&gt;www.sqlexikon.de&lt;/a&gt; have a look (ooch, this site is german)&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">jabber2</dc:creator><pubDate>Thu, 31 Jan 2008 15:05:46 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659196</link><description>&lt;p&gt;I just had this problem reported to me and as I was provided nice little(ish) test case I was able to take an export of the schema involved and try it on Oracle 11g.&lt;/p&gt;&lt;p&gt;I'm happy to say that the query that was failing in Oracle 10.2.0.3.0 interim patch 12 works fine in Oracle 11.1.0.6.0.&lt;/p&gt;&lt;p&gt;I haven't found the bit of documentation that stated if the 1050 limit has been increased but I suspect this it what has changed.&lt;/p&gt;&lt;p&gt;I suspect also that the Oracle pseudo columns are included in the limit as the number of columns in the query that was failing was only just over 1000.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Mike Studholme</dc:creator><pubDate>Thu, 06 Dec 2007 06:31:24 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659195</link><description>&lt;p&gt;Thanks for pointing out another ANSI join error Laurent. Too bad there is no corresponding FULL OUTER JOIN syntax in the "good old" Oracle join syntax, so we can compare. I wonder if Oracle DB 11g had these bugs fixed.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Eddie Awad</dc:creator><pubDate>Mon, 18 Jun 2007 15:28:59 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659194</link><description>&lt;p&gt;well, to make sense the query condition should contain&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;and u1.owner='FOO' and u2.owner='BAR'&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;but the bug is the same... not found on metalink yet&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Laurent Schneider</dc:creator><pubDate>Mon, 18 Jun 2007 11:57:51 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659193</link><description>&lt;p&gt;what about this...&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;select u1.object_name, u1.object_type, u2.object_type, u2.object_type&lt;br&gt;from all_objects u1 full outer join all_objects u2 on&lt;br&gt;(u1.object_name=u2.object_name);&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;from all_objects u1 full outer join all_objects u2 on&lt;br&gt;                                    *&lt;br&gt;ERROR at line 2:&lt;br&gt;ORA-00904: "XML_SCHEMA_NAME_PRESENT"."IS_SCHEMA_PRESENT": invalid identifier&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Laurent Schneider</dc:creator><pubDate>Mon, 18 Jun 2007 11:54:47 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659192</link><description>&lt;p&gt;As I already said, "interesting" data model :-)&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;Never had to do anything with Oracle Applications, probably SAP will not be better from a data model point of view.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;Patrick&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Patrick Wolf</dc:creator><pubDate>Sat, 16 Jun 2007 03:25:17 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659191</link><description>&lt;p&gt;Let's see how many total columns exist in the tables I select from in my example above:&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;pre&gt;&lt;code&gt;APPS@sigma&amp;gt; SELECT COUNT (*)&lt;br&gt;  2    FROM all_tab_columns&lt;br&gt;  3   WHERE table_name IN&lt;br&gt;  4            ('OE_ORDER_HEADERS_ALL',&lt;br&gt;  5             'OE_ORDER_LINES_ALL',&lt;br&gt;  6             'RA_CUSTOMERS',&lt;br&gt;  7             'MTL_SYSTEM_ITEMS_B',&lt;br&gt;  8             'ORG_ORGANIZATION_DEFINITIONS',&lt;br&gt;  9             'RA_SALESREPS_ALL',&lt;br&gt; 10             'HR_LOCATIONS_ALL'&lt;br&gt; 11            );&lt;br&gt;&lt;br&gt;  COUNT(*)&lt;br&gt;----------&lt;br&gt;      1072&lt;br&gt;&lt;/code&gt;&lt;/pre&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;The table OE_ORDER_LINES_ALL alone has 340 columns. These are all standard Oracle EBS tables.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Eddie Awad</dc:creator><pubDate>Fri, 15 Jun 2007 18:39:25 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659190</link><description>&lt;p&gt;A dump question, but who has 1050 columns in 1 table or 7 tables? That are still 150 each!&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;I would question the data model...&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;Patrick&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Patrick Wolf</dc:creator><pubDate>Fri, 15 Jun 2007 18:09:07 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659189</link><description>&lt;p&gt;Judging from the example Eddie it is the total number of colums, regardless of how many columns are actually selected. Select null from ... tells me that it doesn't matter how many columns are actually selected ;-). I would have to try this out myself, but it appears I don't want to switch over to Ansi SQL, when there is no need for it.&lt;br&gt;Good pointer, thanks Eddie.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Patrick Barel</dc:creator><pubDate>Fri, 15 Jun 2007 00:13:43 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659188</link><description>&lt;p&gt;Eep definitely a bug.  Does it happen when the total number of columns selected exceeds 1050, or if the total number of columns in the tables exceeds 1050 (regardless of which columns are actually specified)?&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Don Seiler</dc:creator><pubDate>Thu, 14 Jun 2007 22:34:54 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659187</link><description>&lt;p&gt;Sorry, where I said readable SQL what I should have added is that it is more readable because it still allows you to separate the join predicates from the actual where predicates.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;Which is my major problem with the 'good old' Oracle syntax.&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andy Todd</dc:creator><pubDate>Thu, 14 Jun 2007 21:50:00 -0000</pubDate></item><item><title>Re: When ANSI SQL Join Syntax Does Not Work in Oracle</title><link>http://awads.net/wp/2007/06/14/when-ansi-sql-join-syntax-does-not-work-in-oracle/#comment-3659186</link><description>&lt;p&gt;Yes its a bug. Although I haven't had any success getting official confirmation of that.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;My workaround is to continue using ANSI join syntax but to use in-line tables in my from clause.&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;e.g. instead of&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;FROM table_a a JOIN table_b b ON &lt;a href="http://a.fk" rel="nofollow noopener" target="_blank" title="a.fk"&gt;a.fk&lt;/a&gt;=&lt;a href="http://b.pk" rel="nofollow noopener" target="_blank" title="b.pk"&gt;b.pk&lt;/a&gt;&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;I use&lt;br&gt;FROM (SELECT fk, other_col FROM table_a) a&lt;br&gt;JOIN (SELECT pk, other_other_col FROM table_b) b ON &lt;a href="http://a.fk" rel="nofollow noopener" target="_blank" title="a.fk"&gt;a.fk&lt;/a&gt; = &lt;a href="http://b.pk" rel="nofollow noopener" target="_blank" title="b.pk"&gt;b.pk&lt;/a&gt;&lt;/p&gt;&lt;p&gt;&lt;br&gt;&lt;/p&gt;&lt;p&gt;Its a nasty bodge but still gives much more readable SQL (IMHO of course).&lt;/p&gt;</description><dc:creator xmlns:dc="http://purl.org/dc/elements/1.1/">Andy Todd</dc:creator><pubDate>Thu, 14 Jun 2007 21:47:10 -0000</pubDate></item></channel></rss>