<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	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/"
		>
<channel>
	<title>Comments on: Hibernate: Why should I Force Discriminator?</title>
	<atom:link href="http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/</link>
	<description>Ganesh\</description>
	<lastBuildDate>Sat, 04 Feb 2012 00:52:17 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3</generator>
	<item>
		<title>By: Hibernate n&#8217;aime pas la discrimination &#124; Excilys Labs</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-206453</link>
		<dc:creator>Hibernate n&#8217;aime pas la discrimination &#124; Excilys Labs</dc:creator>
		<pubDate>Fri, 30 Dec 2011 10:41:47 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-206453</guid>
		<description>[...] pas naturel de devoir forcer l&#8217;utilisation du discriminant. Certains ce sont déjà posés la question mais je n&#8217;ai pas un avis tranché à ce jour. Et vous, qu&#8217;en pensez vous ? VN:R_U [...]</description>
		<content:encoded><![CDATA[<p>[...] pas naturel de devoir forcer l&#8217;utilisation du discriminant. Certains ce sont déjà posés la question mais je n&#8217;ai pas un avis tranché à ce jour. Et vous, qu&#8217;en pensez vous ? VN:R_U [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Gunjan</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-161017</link>
		<dc:creator>Gunjan</dc:creator>
		<pubDate>Tue, 06 Sep 2011 20:20:37 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-161017</guid>
		<description>Awesome! Thanks - solved my problem..</description>
		<content:encoded><![CDATA[<p>Awesome! Thanks &#8211; solved my problem..</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Louis Vuitton Handbags</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-159894</link>
		<dc:creator>Louis Vuitton Handbags</dc:creator>
		<pubDate>Thu, 01 Sep 2011 07:53:39 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-159894</guid>
		<description>Very interesting many thanks, I presume your readers would likely want more reviews along these lines continue the great effort.</description>
		<content:encoded><![CDATA[<p>Very interesting many thanks, I presume your readers would likely want more reviews along these lines continue the great effort.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: www.gmarwaha.com</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-128859</link>
		<dc:creator>www.gmarwaha.com</dc:creator>
		<pubDate>Fri, 22 Apr 2011 14:23:49 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-128859</guid>
		<description>Hibernate why should i force discriminator.. Retweeted it :)</description>
		<content:encoded><![CDATA[<p>Hibernate why should i force discriminator.. Retweeted it <img src='http://www.gmarwaha.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: www.gmarwaha.com</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-124049</link>
		<dc:creator>www.gmarwaha.com</dc:creator>
		<pubDate>Fri, 08 Apr 2011 05:46:18 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-124049</guid>
		<description>Hibernate why should i force discriminator.. Nice :)</description>
		<content:encoded><![CDATA[<p>Hibernate why should i force discriminator.. Nice <img src='http://www.gmarwaha.com/blog/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Abhiranjan</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-89055</link>
		<dc:creator>Abhiranjan</dc:creator>
		<pubDate>Wed, 17 Nov 2010 22:47:01 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-89055</guid>
		<description>Hi Ganesh, 
Nice article. I&#039;m facing a similar problem.
While trying to implement the table per class inheritance using discriminator, I am using a column as the discriminator which is essentially a foreign key referring to a code table. 
I believe I&#039;m doing the mapping, and the discriminator value correct, but when I try to save, it gives me an error meaning 
- cannot insert null in the discriminator column (foreign key column). Is it an issue with the discriminator column being foreign key too?</description>
		<content:encoded><![CDATA[<p>Hi Ganesh,<br />
Nice article. I&#8217;m facing a similar problem.<br />
While trying to implement the table per class inheritance using discriminator, I am using a column as the discriminator which is essentially a foreign key referring to a code table.<br />
I believe I&#8217;m doing the mapping, and the discriminator value correct, but when I try to save, it gives me an error meaning<br />
- cannot insert null in the discriminator column (foreign key column). Is it an issue with the discriminator column being foreign key too?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: redoc</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-84753</link>
		<dc:creator>redoc</dc:creator>
		<pubDate>Mon, 18 Oct 2010 19:19:32 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-84753</guid>
		<description>I got a similar exception with seeded data (through batch process) in db. Instead of discriminator &#039;USER&#039;, the discriminator value is &#039;User&#039;, so it was throwing exactly the same above exception. When I changed and updated it worked perfectly fine. So watch out for that possibility as well.</description>
		<content:encoded><![CDATA[<p>I got a similar exception with seeded data (through batch process) in db. Instead of discriminator &#8216;USER&#8217;, the discriminator value is &#8216;User&#8217;, so it was throwing exactly the same above exception. When I changed and updated it worked perfectly fine. So watch out for that possibility as well.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: koltuk y?kama</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-82466</link>
		<dc:creator>koltuk y?kama</dc:creator>
		<pubDate>Tue, 28 Sep 2010 22:36:06 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-82466</guid>
		<description>I put a where clause in the mappings and it worked pretty good.</description>
		<content:encoded><![CDATA[<p>I put a where clause in the mappings and it worked pretty good.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Agus</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-81587</link>
		<dc:creator>Agus</dc:creator>
		<pubDate>Sun, 19 Sep 2010 13:58:58 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-81587</guid>
		<description>So many thanks for this post!!!!

I was struggling with the same &quot;feature&quot; and getting mad.

I consider this behavior a bug as it forces me to use a Hibernate-specific annotation (@ForceDiscriminator is not a JPA standard) and it seems the behavior is different when using XML configuration instead of annotations.

Having said that, I must admit I&#039;m generally satisfied with Hibernate as an ORM tool.

Agus</description>
		<content:encoded><![CDATA[<p>So many thanks for this post!!!!</p>
<p>I was struggling with the same &#8220;feature&#8221; and getting mad.</p>
<p>I consider this behavior a bug as it forces me to use a Hibernate-specific annotation (@ForceDiscriminator is not a JPA standard) and it seems the behavior is different when using XML configuration instead of annotations.</p>
<p>Having said that, I must admit I&#8217;m generally satisfied with Hibernate as an ORM tool.</p>
<p>Agus</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ganeshji Marwaha</title>
		<link>http://www.gmarwaha.com/blog/2009/08/26/hibernate-why-should-i-force-discriminator/comment-page-1/#comment-80925</link>
		<dc:creator>Ganeshji Marwaha</dc:creator>
		<pubDate>Sun, 12 Sep 2010 18:35:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.gmarwaha.com/blog/?p=100#comment-80925</guid>
		<description>@Kalyan #27: Applying a &quot;Where Clause&quot; Filter is another solution to the same problem, but something I would try to avoid, because that way you are directly appending strings to the SQL query generated by Hibernate. In case of a simple &quot;where&quot; clause, it might not be a problem, but when that becomes a bit more than standard SQL, then you don&#039;t have portability anymore. I agree, portability is most often not necessary for medium to big applications, but still, u know what i mean. Another issue I see is - the &quot;where&quot; clause can possibly hold plain strings on the RHS without being used as a prepared statement.</description>
		<content:encoded><![CDATA[<p>@Kalyan #27: Applying a &#8220;Where Clause&#8221; Filter is another solution to the same problem, but something I would try to avoid, because that way you are directly appending strings to the SQL query generated by Hibernate. In case of a simple &#8220;where&#8221; clause, it might not be a problem, but when that becomes a bit more than standard SQL, then you don&#8217;t have portability anymore. I agree, portability is most often not necessary for medium to big applications, but still, u know what i mean. Another issue I see is &#8211; the &#8220;where&#8221; clause can possibly hold plain strings on the RHS without being used as a prepared statement.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

