<?xml version="1.0" encoding="UTF-8"?>
<?xml-stylesheet type="text/xsl" media="screen" href="/~d/styles/rss2full.xsl"?><?xml-stylesheet type="text/css" media="screen" href="http://feeds.feedburner.com/~d/styles/itemcontent.css"?><rss 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/" xmlns:feedburner="http://rssnamespace.org/feedburner/ext/1.0" version="2.0">

<channel>
	<title>betweenGo</title>
	
	<link>http://betweengo.com</link>
	<description>We make Ruby on Rails easy.  We make ATG easy.</description>
	<lastBuildDate>Thu, 11 Apr 2013 00:37:37 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.5.1</generator>
		<atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="self" type="application/rss+xml" href="http://feeds.feedburner.com/betweengo" /><feedburner:info uri="betweengo" /><atom10:link xmlns:atom10="http://www.w3.org/2005/Atom" rel="hub" href="http://pubsubhubbub.appspot.com/" /><feedburner:emailServiceId>betweengo</feedburner:emailServiceId><feedburner:feedburnerHostname>http://feedburner.google.com</feedburner:feedburnerHostname><item>
		<title>ATG Ordered One-to-Many Relationships</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/i4kDaNb5CxM/</link>
		<comments>http://betweengo.com/2013/04/08/atg-ordered-one-to-many-relationships/#comments</comments>
		<pubDate>Mon, 08 Apr 2013 13:00:00 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Repository]]></category>
		<category><![CDATA[sql]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1388</guid>
		<description><![CDATA[Last week I blogged about ATG unordered one-to-many relationships. Ordered one-to-many is quite similar but a little more complex. Here again is the same example of players belonging to a team except now the players are a list property of &#8230; <a href="http://betweengo.com/2013/04/08/atg-ordered-one-to-many-relationships/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/' rel='bookmark' title='ATG Unordered One-to-Many Relationships'>ATG Unordered One-to-Many Relationships</a></li>
<li><a href='http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/' rel='bookmark' title='Specifying One-to-Many Relationship in ATG Repositories'>Specifying One-to-Many Relationship in ATG Repositories</a></li>
<li><a href='http://betweengo.com/2005/07/28/user-defined-property-type-gotchas/' rel='bookmark' title='user-defined property type gotcha&#8217;s'>user-defined property type gotcha&#8217;s</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<div class="wp-caption alignnone" style="width: 510px"><a title="Former NY Knicks guard Jeremy Lin wins debut with Houston Rockets as James Harden explodes for 37 points" href="http://www.nydailynews.com/sports/basketball/knicks/houst-lin-beats-pistons-behind-harden-jeremy-article-1.1195336"><img title="Bautista, Lawrie, Rasmus" alt="Bautista, Lawrie, Rasmus" src="http://assets.nydailynews.com/polopoly_fs/1.1195323.1351749963!/img/httpImage/image.jpg_gen/derivatives/landscape_635/lin-harden-rockets.jpg"/></a><p class="wp-caption-text"><a title="Former NY Knicks guard Jeremy Lin wins debut with Houston Rockets as James Harden explodes for 37 points" href="http://www.nydailynews.com/sports/basketball/knicks/houst-lin-beats-pistons-behind-harden-jeremy-article-1.1195336">Former NY Knicks guard Jeremy Lin wins debut with Houston Rockets as James Harden explodes for 37 points</a></p></div>
<p>Last week I blogged about <a title="ATG Unordered One-to-Many Relationships" href="http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/">ATG unordered one-to-many relationships</a>. Ordered one-to-many is quite similar but a little more complex.</p>
<p>Here again is the same example of players belonging to a team except now the players are a list property of the team.</p>
<pre>&lt;item-descriptor name="team"&gt;
  &lt;table name="team" type="primary" id-column-names="id"&gt;
    &lt;property name="name" required="true" /&gt;
  &lt;/table&gt;
  &lt;table name="player" type="multi" multi-column-name=”idx” id-column-names="team_id"&gt;
    &lt;property name="players" column-name="id" data-type="list" component-item-type="player" /&gt;
  &lt;/table&gt;
&lt;/item-descriptor&gt;

&lt;item-descriptor name="player"&gt;
  &lt;table name="player" type="primary" id-column-names="id"&gt;
    &lt;property name="name" required="true" /&gt;
    &lt;property name="team" column-name="team_id" item-type="team" /&gt;
  &lt;/table&gt;
&lt;/item-descriptor&gt;</pre>
<p>And here is the SQL.</p>
<pre>CREATE TABLE team (
  id VARCHAR2(40) NOT NULL,
  name VARCHAR2(3) NOT NULL,
  CONSTRAINT team_p PRIMARY KEY (id)
);

CREATE TABLE player (
  id VARCHAR2(40) NOT NULL,
  idx NUMBER(2,0),<p>  name VARCHAR2(40),
  team_id VARCHAR2(40),
  CONSTRAINT player_p PRIMARY KEY (id)
);</p></pre>
<p>Now comes the tricky part. You can never just set the team in the player repository item.</p>
<pre>player.setPropertyValue("team", team);</pre>
<p>This is because when you do this the idx column in the player table is not set. We could create a repository property and try to set it separately but that is bad practice. You would have to know how many players are already on the team and then set the idx to that number.
</p>
<p>What you should do is not allow the team property to be written.</p>
<pre>&lt;property name="team" column-name="team_id" item-type="team" writable="false" /&gt;</pre>
<p>And instead add the player to the team repository item.</p>
<pre>Set&lt;RepositoryItem&gt; players = (Set&lt;RepositoryItem&gt;) team.getPropertyValue("players");
players.add(player);</pre>
<p>Because of this requirement you cannot make the team property required for the player as discussed before.</p>
<p>Again if you have any questions please leave them in the comments.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2013%2F04%2F08%2Fatg-ordered-one-to-many-relationships%2F&amp;title=ATG%20Ordered%20One-to-Many%20Relationships" id="wpa2a_2"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/' rel='bookmark' title='ATG Unordered One-to-Many Relationships'>ATG Unordered One-to-Many Relationships</a></li>
<li><a href='http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/' rel='bookmark' title='Specifying One-to-Many Relationship in ATG Repositories'>Specifying One-to-Many Relationship in ATG Repositories</a></li>
<li><a href='http://betweengo.com/2005/07/28/user-defined-property-type-gotchas/' rel='bookmark' title='user-defined property type gotcha&#8217;s'>user-defined property type gotcha&#8217;s</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=i4kDaNb5CxM:xiwQMQQME80:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=i4kDaNb5CxM:xiwQMQQME80:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=i4kDaNb5CxM:xiwQMQQME80:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=i4kDaNb5CxM:xiwQMQQME80:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=i4kDaNb5CxM:xiwQMQQME80:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/i4kDaNb5CxM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2013/04/08/atg-ordered-one-to-many-relationships/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2013/04/08/atg-ordered-one-to-many-relationships/</feedburner:origLink></item>
		<item>
		<title>ATG Unordered One-to-Many Relationships</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/DVynJ12v2Ng/</link>
		<comments>http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/#comments</comments>
		<pubDate>Thu, 04 Apr 2013 13:00:00 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Repository]]></category>
		<category><![CDATA[sql]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1378</guid>
		<description><![CDATA[Previously I blogged about specifying one-to-many relationships in ATG. Turns out I could have done it much more simply. Using the same example of players belonging to a team here are the simplified SQL repository definitions. &#60;item-descriptor name="team"&#62; &#60;table name="team" &#8230; <a href="http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2013/04/08/atg-ordered-one-to-many-relationships/' rel='bookmark' title='ATG Ordered One-to-Many Relationships'>ATG Ordered One-to-Many Relationships</a></li>
<li><a href='http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/' rel='bookmark' title='Specifying One-to-Many Relationship in ATG Repositories'>Specifying One-to-Many Relationship in ATG Repositories</a></li>
<li><a href='http://betweengo.com/2005/07/28/user-defined-property-type-gotchas/' rel='bookmark' title='user-defined property type gotcha&#8217;s'>user-defined property type gotcha&#8217;s</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<div class="wp-caption alignnone" style="width: 510px"><a href="http://www.flickr.com/photos/james_in_to/7952493122/"><img title="Bautista, Lawrie, Rasmus" alt="Bautista, Lawrie, Rasmus" src="http://farm9.staticflickr.com/8444/7952493122_b5d3e2c17f.jpg" width="500" height="333" /></a><p class="wp-caption-text">Photo by <a title="Flickr: james_in_to's photostream" href="http://www.flickr.com/photos/james_in_to/">james_in_to</a></p></div>
<p>Previously I blogged about <a title="Specifying One-to-Many Relationship in ATG Repositories" href="http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/">specifying one-to-many relationships in ATG</a>. Turns out I could have done it much more simply.</p>
<p>Using the same example of players belonging to a team here are the simplified SQL repository definitions.</p>
<pre>&lt;item-descriptor name="team"&gt;
  &lt;table name="team" type="primary" id-column-names="id"&gt;
    &lt;property name="name" required="true" /&gt;
  &lt;/table&gt;
  &lt;table name="player" type="multi" id-column-names="team_id"&gt;
    &lt;property name="players" column-name="id" data-type="set" component-item-type="player" /&gt;
  &lt;/table&gt;
&lt;/item-descriptor&gt;

&lt;item-descriptor name="player"&gt;
  &lt;table name="player" type="primary" id-column-names="id"&gt;
    &lt;property name="name" required="true" /&gt;
    &lt;property name="team" column-name="team_id" item-type="team" /&gt;
  &lt;/table&gt;
&lt;/item-descriptor&gt;</pre>
<p>And here is the SQL.</p>
<pre>CREATE TABLE team (
  id VARCHAR2(40) NOT NULL,
  name VARCHAR2(3) NOT NULL,
  CONSTRAINT team_p PRIMARY KEY (id)
);

CREATE TABLE player (
  id VARCHAR2(40) NOT NULL,
  name VARCHAR2(40) NOT NULL,
  team_id VARCHAR2(40),
  CONSTRAINT player_p PRIMARY KEY (id)
);</pre>
<p>You can set the team in the player repository item.</p>
<pre>player.setPropertyValue("team", team);</pre>
<p>Or add the player to the team repository item.</p>
<pre>Set&lt;RepositoryItem&gt; players = (Set&lt;RepositoryItem&gt;) team.getPropertyValue("players");
players.add(player);</pre>
<p>What gets tricky is if you require a player to be on a team.</p>
<pre>&lt;property name="team" column-name="team_id" item-type="team" required="true" /&gt;</pre>
<pre>team_id VARCHAR2(40) NOT NULL,</pre>
<p>In this case you cannot remove a player from a team by doing this:</p>
<pre>Set&lt;RepositoryItem&gt; players = (Set&lt;RepositoryItem&gt;) team.getPropertyValue("players");
players.remove(player);</pre>
<p>This is because when you remove the player from the team the player will no longer have a team. This violates both the repository definition and will result in a SQL error because team_id cannot be null.</p>
<p>The only way you can change a player&#8217;s team is to do this.</p>
<pre>player.setPropertyValue("team", newTeam);</pre>
<p>To help enforce this you can make the team&#8217;s players property unwritable.</p>
<pre>&lt;property name="players" column-name="id" data-type="set" component-item-type ="player" writable="false" /&gt;</pre>
<p>I hope this makes sense. If you have any questions please leave them in the comments.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2013%2F04%2F04%2Fatg-unordered-one-to-many-relationships%2F&amp;title=ATG%20Unordered%20One-to-Many%20Relationships" id="wpa2a_4"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2013/04/08/atg-ordered-one-to-many-relationships/' rel='bookmark' title='ATG Ordered One-to-Many Relationships'>ATG Ordered One-to-Many Relationships</a></li>
<li><a href='http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/' rel='bookmark' title='Specifying One-to-Many Relationship in ATG Repositories'>Specifying One-to-Many Relationship in ATG Repositories</a></li>
<li><a href='http://betweengo.com/2005/07/28/user-defined-property-type-gotchas/' rel='bookmark' title='user-defined property type gotcha&#8217;s'>user-defined property type gotcha&#8217;s</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=DVynJ12v2Ng:EWVDYH7_muQ:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=DVynJ12v2Ng:EWVDYH7_muQ:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=DVynJ12v2Ng:EWVDYH7_muQ:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=DVynJ12v2Ng:EWVDYH7_muQ:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=DVynJ12v2Ng:EWVDYH7_muQ:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/DVynJ12v2Ng" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2013/04/04/atg-unordered-one-to-many-relationships/</feedburner:origLink></item>
		<item>
		<title>Ignore Unavoidable Generic Type Problems in Eclipse</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/wCdbskGTnFo/</link>
		<comments>http://betweengo.com/2013/01/24/ignore-unavoidable-generic-type-problems-in-eclipse/#comments</comments>
		<pubDate>Thu, 24 Jan 2013 19:11:19 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[ATG]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1365</guid>
		<description><![CDATA[When you use Eclipse by default most generic type problems show up as warnings. Unfortunately this results in lots of warnings when you use ATG code. You can turn off the warnings that result from ATG code by checking the &#8230; <a href="http://betweengo.com/2013/01/24/ignore-unavoidable-generic-type-problems-in-eclipse/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2008/09/01/java-method-with-generic-return-type/' rel='bookmark' title='Java Method with Generic Return Type'>Java Method with Generic Return Type</a></li>
<li><a href='http://betweengo.com/2008/06/13/eclipse-memory-settings/' rel='bookmark' title='Eclipse memory settings'>Eclipse memory settings</a></li>
<li><a href='http://betweengo.com/2010/03/01/ignore-files-and-directories-in-subversion/' rel='bookmark' title='Ignore Files and Directories in Subversion'>Ignore Files and Directories in Subversion</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p>When you use Eclipse by default most generic type problems show up as warnings. Unfortunately this results in lots of warnings when you use ATG code.</p>
<p>You can turn off the warnings that result from ATG code by checking the option &#8220;Ignore unavoidable generic type problems&#8221;.</p>
<div id="attachment_1367" class="wp-caption aligncenter" style="width: 510px"><a href="http://betweengo.com/wp-content/uploads/2013/01/ignore-unavoidable-generic-type-problems.png"><img class="size-medium wp-image-1367" alt="Ignore unavoidable generic type problems" src="http://betweengo.com/wp-content/uploads/2013/01/ignore-unavoidable-generic-type-problems-500x297.png" width="500" height="297" /></a><p class="wp-caption-text">Ignore unavoidable generic type problems</p></div>
<p>For example you might have code like this where <tt>getValues()</tt> comes from the ATG API:</p>
<pre>getValues().put(name, value);</pre>
<p>By default Eclipse reports warnings for the above line. But this is unavoidable and with this Ignore option turned on no warning is reported for this line.</p>
<p>Kind of useful and you don&#8217;t have to add @SuppressWarnings(&#8220;unchecked&#8221;) liberally through your ATG code.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2013%2F01%2F24%2Fignore-unavoidable-generic-type-problems-in-eclipse%2F&amp;title=Ignore%20Unavoidable%20Generic%20Type%20Problems%20in%20Eclipse" id="wpa2a_6"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2008/09/01/java-method-with-generic-return-type/' rel='bookmark' title='Java Method with Generic Return Type'>Java Method with Generic Return Type</a></li>
<li><a href='http://betweengo.com/2008/06/13/eclipse-memory-settings/' rel='bookmark' title='Eclipse memory settings'>Eclipse memory settings</a></li>
<li><a href='http://betweengo.com/2010/03/01/ignore-files-and-directories-in-subversion/' rel='bookmark' title='Ignore Files and Directories in Subversion'>Ignore Files and Directories in Subversion</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=wCdbskGTnFo:rbV9SOoF9fM:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=wCdbskGTnFo:rbV9SOoF9fM:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=wCdbskGTnFo:rbV9SOoF9fM:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=wCdbskGTnFo:rbV9SOoF9fM:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=wCdbskGTnFo:rbV9SOoF9fM:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/wCdbskGTnFo" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2013/01/24/ignore-unavoidable-generic-type-problems-in-eclipse/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2013/01/24/ignore-unavoidable-generic-type-problems-in-eclipse/</feedburner:origLink></item>
		<item>
		<title>Debugging Transaction is not Active</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/bibm618MsOs/</link>
		<comments>http://betweengo.com/2012/08/30/debugging-transaction-is-not-active/#comments</comments>
		<pubDate>Fri, 31 Aug 2012 00:39:15 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Repository]]></category>
		<category><![CDATA[ATG]]></category>
		<category><![CDATA[debug]]></category>
		<category><![CDATA[JBoss]]></category>
		<category><![CDATA[transactions]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1343</guid>
		<description><![CDATA[Problems like this happen occasionally and are quite bedeviling. Caused by: java.lang.RuntimeException: CONTAINER:atg.repository.RepositoryException; SOURCE:org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImple &#60; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &#62;; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple &#60; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: &#8230; <a href="http://betweengo.com/2012/08/30/debugging-transaction-is-not-active/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2008/05/28/invalid-column-type-sqlexception-with-atg-repository/' rel='bookmark' title='Invalid column type SQLException with ATG Repository'>Invalid column type SQLException with ATG Repository</a></li>
<li><a href='http://betweengo.com/2008/07/22/fixing-illegalargumentexception-in-acc/' rel='bookmark' title='Fixing IllegalArgumentException in ACC'>Fixing IllegalArgumentException in ACC</a></li>
<li><a href='http://betweengo.com/2007/12/07/debugging-category-bad-child-products/' rel='bookmark' title='Debugging a Category&#8217;s Bad Child Products'>Debugging a Category&#8217;s Bad Child Products</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p>Problems like this happen occasionally and are quite bedeviling.</p>
<pre>Caused by: java.lang.RuntimeException: CONTAINER:atg.repository.RepositoryException; SOURCE:org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;)
    at atg.adapter.gsa.GSAItemDescriptor.loadProperty(GSAItemDescriptor.java:5479)
    at atg.adapter.gsa.GSAItem.getPersistentPropertyValue(GSAItem.java:1101)
    at atg.adapter.gsa.GSAItem.getPropertyValue(GSAItem.java:994)
    at atg.adapter.gsa.GSAItem.getPropertyValue(GSAItem.java:1272)
    at atg.repository.RepositoryItemImpl.getPropertyValue(RepositoryItemImpl.java:128)
    at atg.commerce.order.processor.ProcLoadHandlingInstructionObjects.runProcess(ProcLoadHandlingInstructionObjects.java:183)
    at atg.service.pipeline.PipelineLink.runProcess(PipelineLink.java:233)
    at atg.service.pipeline.PipelineChain.runProcess(PipelineChain.java:343)
    ... 17 more
Caused by: CONTAINER:atg.repository.RepositoryException; SOURCE:org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;)
    at atg.adapter.gsa.GSAItemDescriptor.loadProperties(GSAItemDescriptor.java:5431)
    at atg.adapter.gsa.GSAItemDescriptor.loadProperty(GSAItemDescriptor.java:5471)
    ... 24 more
Caused by: org.jboss.util.NestedSQLException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;; - nested throwable: (javax.resource.ResourceException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;)
    at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:96)
    at atg.service.jdbc.WatcherDataSource.getConnection(WatcherDataSource.java:801)
    at atg.service.jdbc.WatcherDataSource.getConnection(WatcherDataSource.java:782)
    at atg.adapter.gsa.GSATransaction.getConnection(GSATransaction.java:744)
    at atg.adapter.gsa.GSAItemDescriptor.getConnection(GSAItemDescriptor.java:2365)
    at atg.adapter.gsa.GSAItemDescriptor.loadProperties(GSAItemDescriptor.java:5345)
    ... 25 more
Caused by: javax.resource.ResourceException: Transaction is not active: tx=TransactionImple &lt; ac, BasicAction: 7f000001:c525:503e32fb:2f2c status: ActionStatus.ABORT_ONLY &gt;
    at org.jboss.resource.connectionmanager.TxConnectionManager.getManagedConnection(TxConnectionManager.java:319)
    at org.jboss.resource.connectionmanager.BaseConnectionManager2.allocateConnection(BaseConnectionManager2.java:403)
    at org.jboss.resource.connectionmanager.BaseConnectionManager2$ConnectionManagerProxy.allocateConnection(BaseConnectionManager2.java:850)
    at org.jboss.resource.adapter.jdbc.WrapperDataSource.getConnection(WrapperDataSource.java:90)
    ... 30 more</pre>
<p>I tweeted about issues like this over two years ago.</p>
<blockquote class="twitter-tweet tw-align-center"><p>Transaction is not active: tx=TransactionImple « The Java Blog. Not a transaction issue, actually an application issue. <a href="http://bit.ly/crvL1K">http://bit.ly/crvL1K</a></p>
<p>— Frank Kim (@betweengo) <a href="https://twitter.com/betweengo/status/19785780169" data-datetime="2010-07-29T01:15:52+00:00">July 29, 2010</a></p></blockquote>
<p>As I said in the tweet this almost always is not a transaction issue but actually an application issue. The tweet references an excellent article <a title="Transaction is not active: tx=TransactionImple &lt; ac, BasicAction « The Java Blog" href="http://thejavablog.wordpress.com/2010/04/05/transaction-is-not-active-txtransactionimple-ac-basicaction/">Transaction is not active: tx=TransactionImple &lt; ac, BasicAction</a> in which the author found in his case that the problem was a NullPointerException which caused the transaction to end.</p>
<p>Today I had to debug this issue again. First I checked the transaction in ProcLoadHandlingInstructionObjects before it called getPropertyValue on the shipping group repository item.</p>
<pre>GSAItem item = (GSAItem) sgMutItem;
ItemTransactionState state = item.getItemTransactionState(false);
logDebug("state=" + state.mGSATransaction);</pre>
<p>I saw in the logs that the status of the transaction was ActionStatus.ABORT_ONLY which meant the transaction was already aborted before getting the property value from the repository which is why the Transaction is not active exception happened.</p>
<p>Next I checked the transaction at the beginning of ProcLoadHandlingInstructionObjects using the order repository item.</p>
<pre>GSAItem item = (GSAItem) orderItem;
ItemTransactionState state = item.getItemTransactionState(false);
logDebug("state=" + state.mGSATransaction);</pre>
<p>When I confirmed that the status of the transaction was ActionStatus.ABORT_ONLY at the beginning of the processor I went backwards through the pipeline checking all the processors in the same way.</p>
<p>After doing that and confirming the transaction was ActionStatus.ABORT_ONLY at the beginning of the pipeline process I began checking the code that called the pipeline using code like this.</p>
<pre>GSAItem orderItem = (GSAItem) order.getRepositoryItem();
ItemTransactionState state = orderItem.getItemTransactionState(false);
try {
  int status = state.mGSATransaction.getTransaction().getStatus();
  if (status == Status.STATUS_MARKED_ROLLBACK) {
    logError("Oh-oh, marked for rollback.");
  }
} catch (SystemException exc) {}</pre>
<p>I finally found the problem was that in a previous call to another pipeline an error had occurred and the transaction was marked for rollback. However the code did not check the result of the pipeline call and had continued.</p>
<p>The moral of the story is always check your return values and don&#8217;t go down the rat hole of believing it&#8217;s a transaction issue.</p>
<p><a href="http://www.alice-in-wonderland.net/pictures/alice-pictures.html"><img class="aligncenter" title="Alice in front of the rabbit hole" src="http://www.alice-in-wonderland.net/alicepic/disney-movie/alice-in-front-of-rabbit-hole.jpg" alt="Alice in front of the rabbit hole" width="720" height="576" /></a></p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F08%2F30%2Fdebugging-transaction-is-not-active%2F&amp;title=Debugging%20Transaction%20is%20not%20Active" id="wpa2a_8"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2008/05/28/invalid-column-type-sqlexception-with-atg-repository/' rel='bookmark' title='Invalid column type SQLException with ATG Repository'>Invalid column type SQLException with ATG Repository</a></li>
<li><a href='http://betweengo.com/2008/07/22/fixing-illegalargumentexception-in-acc/' rel='bookmark' title='Fixing IllegalArgumentException in ACC'>Fixing IllegalArgumentException in ACC</a></li>
<li><a href='http://betweengo.com/2007/12/07/debugging-category-bad-child-products/' rel='bookmark' title='Debugging a Category&#8217;s Bad Child Products'>Debugging a Category&#8217;s Bad Child Products</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=bibm618MsOs:EQ07LTWHUBE:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=bibm618MsOs:EQ07LTWHUBE:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=bibm618MsOs:EQ07LTWHUBE:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=bibm618MsOs:EQ07LTWHUBE:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=bibm618MsOs:EQ07LTWHUBE:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/bibm618MsOs" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/08/30/debugging-transaction-is-not-active/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/08/30/debugging-transaction-is-not-active/</feedburner:origLink></item>
		<item>
		<title>Pretending You Are From Another Country</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/gXIQKu5OgGM/</link>
		<comments>http://betweengo.com/2012/07/30/pretending-you-are-from-another-country/#comments</comments>
		<pubDate>Mon, 30 Jul 2012 15:00:47 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Web]]></category>
		<category><![CDATA[firefox]]></category>
		<category><![CDATA[locale]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1331</guid>
		<description><![CDATA[Some websites determine what country you are from by simply checking your request&#8217;s locale. Knowing that you can fool a website by setting your browser&#8217;s locale. For example this is how I configured Firefox so that it appears that I &#8230; <a href="http://betweengo.com/2012/07/30/pretending-you-are-from-another-country/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss yarpp-related-none'>

No related posts.
</div>
]]></description>
				<content:encoded><![CDATA[<p>Some websites determine what country you are from by simply checking your request&#8217;s locale. Knowing that you can fool a website by setting your browser&#8217;s locale.</p>
<p>For example this is how I configured Firefox so that it appears that I am located in the United Kingdom. I can pretend I am in London watching the Olympics. <img src='http://betweengo.com/wp-includes/images/smilies/icon_smile.gif' alt=':-)' class='wp-smiley' /> </p>
<p><a href="http://betweengo.com/wp-content/uploads/2012/07/firefox-language.png"><img class="aligncenter size-medium wp-image-1333" title="Firefox Language Preference" src="http://betweengo.com/wp-content/uploads/2012/07/firefox-language-500x383.png" alt="Firefox Language Preference" width="500" height="383" /></a></p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F07%2F30%2Fpretending-you-are-from-another-country%2F&amp;title=Pretending%20You%20Are%20From%20Another%20Country" id="wpa2a_10"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss yarpp-related-none'>
<p>No related posts.</p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=gXIQKu5OgGM:GitutQLlGV8:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=gXIQKu5OgGM:GitutQLlGV8:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=gXIQKu5OgGM:GitutQLlGV8:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=gXIQKu5OgGM:GitutQLlGV8:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=gXIQKu5OgGM:GitutQLlGV8:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/gXIQKu5OgGM" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/07/30/pretending-you-are-from-another-country/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/07/30/pretending-you-are-from-another-country/</feedburner:origLink></item>
		<item>
		<title>Exporting ATG Repositories</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/05K0sR9k3Dw/</link>
		<comments>http://betweengo.com/2012/07/16/exporting-atg-repositories/#comments</comments>
		<pubDate>Mon, 16 Jul 2012 14:26:12 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Repository]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1328</guid>
		<description><![CDATA[ATG&#8217;s documentation suggests running startSQLRepository to export repositories. However this is an older solution that works well with SOLID and DAS but not so easily with Oracle and JBoss. Oracle uses its own JDBC jar which you have to add &#8230; <a href="http://betweengo.com/2012/07/16/exporting-atg-repositories/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/' rel='bookmark' title='Specifying One-to-Many Relationship in ATG Repositories'>Specifying One-to-Many Relationship in ATG Repositories</a></li>
<li><a href='http://betweengo.com/2008/05/09/accessing-repositoryitems-with-jstl/' rel='bookmark' title='Accessing RepositoryItems with JSTL'>Accessing RepositoryItems with JSTL</a></li>
<li><a href='http://betweengo.com/2007/02/07/user-defined-property-types/' rel='bookmark' title='ATG Repository User-Defined Property Types'>ATG Repository User-Defined Property Types</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<div class="wp-caption aligncenter" style="width: 510px"><a href="http://www.flickr.com/photos/wirralwater/3784429237/"><img title="Kmtc Jakarta at singapore | Flickr" src="http://farm4.staticflickr.com/3447/3784429237_3965cb796b.jpg" alt="Kmtc Jakarta at singapore | Flickr" width="500" height="375" /></a><p class="wp-caption-text"><a title="Kmtc Jakarta at singapore | Flickr" href="http://www.flickr.com/photos/wirralwater/3784429237/">Kmtc Jakarta at singapore</a> by <a title="Flickr: wirralwater (not very good but enjoy it)'s Photostream" href="http://www.flickr.com/photos/wirralwater/">wirralwater</a></p></div>
<p>ATG&#8217;s documentation suggests running startSQLRepository to export repositories. However this is an older solution that works well with SOLID and DAS but not so easily with Oracle and JBoss. Oracle uses its own JDBC jar which you have to add to the CLASSPATH before running startSQLRepository. JBoss uses JNDI and real DataSource&#8217;s to connect to the database. But this doesn&#8217;t work with startSQLRepository so you have to set up a separate ATG server with fake DataSources to run with startSQLRepository.</p>
<p>All of this is to say it&#8217;s a pain to use startSQLRepository. The much simpler method is to navigate to the repository in your Dynamo admin (e.g. <a title="http://localhost:8080/dyn/admin" href="http://localhost:8080/dyn/admin">http://localhost:8080/dyn/admin</a>). Then in the &#8220;Run XML Operation Tags on the Repository&#8221; textbox enter the command</p>
<pre>&lt;export-items /&gt;</pre>
<p>Or if you want to export only certain item-descriptors:</p>
<pre>&lt;export-items item-descriptors="authors, books" /&gt;</pre>
<p>And if you want to ensure you only get a certain item-descriptor without any referenced item-descriptors:</p>
<pre>&lt;export-items item-descriptors="books" skip-references="true" /&gt;</pre>
<p><a href="http://www.staples.com/sbd/cre/marketing/easybutton/takeiteasy.html"><img class="alignright" title="That Was Easy" src="http://www.staples.com/sbd/cre/marketing/easybutton/images/gr-easybutton.gif" alt="That Was Easy" width="120" height="115" /></a>You can then save the outputted XML to an XML file and then later paste the contents of this XML file to the same textbox to import the repository items.</p>
<p>For more information please see the &lt;export-items&gt; section in the SQL Repository Reference chapter of the ATG Repository Guide.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F07%2F16%2Fexporting-atg-repositories%2F&amp;title=Exporting%20ATG%20Repositories" id="wpa2a_12"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2010/01/21/specifying-one-to-many-relationship-in-atg-repositories/' rel='bookmark' title='Specifying One-to-Many Relationship in ATG Repositories'>Specifying One-to-Many Relationship in ATG Repositories</a></li>
<li><a href='http://betweengo.com/2008/05/09/accessing-repositoryitems-with-jstl/' rel='bookmark' title='Accessing RepositoryItems with JSTL'>Accessing RepositoryItems with JSTL</a></li>
<li><a href='http://betweengo.com/2007/02/07/user-defined-property-types/' rel='bookmark' title='ATG Repository User-Defined Property Types'>ATG Repository User-Defined Property Types</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=05K0sR9k3Dw:8Lfkl2oc3Fs:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=05K0sR9k3Dw:8Lfkl2oc3Fs:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=05K0sR9k3Dw:8Lfkl2oc3Fs:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=05K0sR9k3Dw:8Lfkl2oc3Fs:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=05K0sR9k3Dw:8Lfkl2oc3Fs:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/05K0sR9k3Dw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/07/16/exporting-atg-repositories/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/07/16/exporting-atg-repositories/</feedburner:origLink></item>
		<item>
		<title>Why is there a _requestid in my URL?</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/Jgp58crbkvU/</link>
		<comments>http://betweengo.com/2012/07/09/why-is-there-a-_requestid-in-my-url/#comments</comments>
		<pubDate>Mon, 09 Jul 2012 13:00:13 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1281</guid>
		<description><![CDATA[Sometimes when you are using an ATG powered website, e.g. Keds, you will see a _requestid parameter in your URL, e.g. http://www.keds.com/?_requestid=138580. This occurs when the ATG code, typically a form handler, does a local redirect instead of a redirect. &#8230; <a href="http://betweengo.com/2012/07/09/why-is-there-a-_requestid-in-my-url/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2006/12/15/forwarding-instead-of-redirecting-in-form-handlers/' rel='bookmark' title='Forwarding instead of Redirecting in Form Handlers'>Forwarding instead of Redirecting in Form Handlers</a></li>
<li><a href='http://betweengo.com/2005/09/14/java-filenotfoundexception-for-valid-url/' rel='bookmark' title='java.io.FileNotFoundException for valid URL'>java.io.FileNotFoundException for valid URL</a></li>
<li><a href='http://betweengo.com/2009/01/15/urlequals-and-hashcode-make-blocking-internet-connections/' rel='bookmark' title='URL.equals and hashCode make blocking Internet connections'>URL.equals and hashCode make blocking Internet connections</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<div class="wp-caption aligncenter" style="width: 510px"><a href="http://www.flickr.com/photos/eilonwy77/7229389076/"><img class="    " title="Tree Tutorial | Flickr" src="http://farm6.staticflickr.com/5455/7229389076_5458276b3c.jpg" alt="Tree Tutorial | Flickr" width="500" height="377" /></a><p class="wp-caption-text"><a title="Tree Tutorial | Flickr" href="http://www.flickr.com/photos/eilonwy77/7229389076/">Tree Tutorial</a> by <a title="Flickr: eilonwy77's Photostream" href="http://www.flickr.com/photos/eilonwy77/">eilonwy77</a></p></div>
<p>Sometimes when you are using an ATG powered website, e.g. <a title="Keds" href="http://www.keds.com/" target="_blank">Keds</a>, you will see a _requestid parameter in your URL, e.g. http://www.keds.com/?_requestid=138580.</p>
<p>This occurs when the ATG code, typically a form handler, does a <a title="DynamoHttpServletResponse (ATG Java API) sendLocalRedirect" href="http://docs.oracle.com/cd/E22630_01/Platform.1002/apidoc/atg/servlet/DynamoHttpServletResponse.html#sendLocalRedirect%28java.lang.String,%20atg.servlet.DynamoHttpServletRequest%29" target="_blank">local redirect</a> instead of a <a title="DynamoHttpServletResponse (ATG Java API) sendRedirect" href="http://docs.oracle.com/cd/E22630_01/Platform.1002/apidoc/atg/servlet/DynamoHttpServletResponse.html#sendRedirect%28java.lang.String%29" target="_blank">redirect</a>. This is ATG&#8217;s own flavor of redirect which does a few extra things as described in the JavaDoc:</p>
<blockquote><p>Sends a redirect response to the client using the specified redirect location URL. This function is similar to sendRedirect(), with the following two differences:</p>
<ul>
<li>The session ID is added to the URL if a valid cookie with the session ID is not found.</li>
<li>If the URL is a relative URL (i.e., &#8220;login/error.html&#8221;), then the URL will be converted to a full absolute URL, as required by the HTTP specification. A relative URL is one that does not specify a protocol (e.g., &#8220;http:&#8221;).</li>
</ul>
<p>In general, this function should be used when redirecting back to a page on the same site. If you are redirecting to a page on some other site, use the full absolute URL and call sendRedirect().</p></blockquote>
<p>However this does not explain the mysterious _requestid parameter. Fortunately ATG&#8217;s Programming Guide does:</p>
<blockquote><p>Preserving Request Scoped Objects on Redirects</p>
<p>If a request results in a redirect to a local page through the method HttpServletResponse.sendLocalRedirect(), the ATG platform treats the redirect request as part of the original request, and maintains any request-scoped objects associated with that request. To implement this, the ATG platform adds an additional query parameter named _requestid to the redirected URL.</p></blockquote>
<p>Now you know what the _requestid parameter is and why it exists. And if you don&#8217;t want it then you the programmer should use a redirect instead of a local redirect.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F07%2F09%2Fwhy-is-there-a-_requestid-in-my-url%2F&amp;title=Why%20is%20there%20a%20_requestid%20in%20my%20URL%3F" id="wpa2a_14"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2006/12/15/forwarding-instead-of-redirecting-in-form-handlers/' rel='bookmark' title='Forwarding instead of Redirecting in Form Handlers'>Forwarding instead of Redirecting in Form Handlers</a></li>
<li><a href='http://betweengo.com/2005/09/14/java-filenotfoundexception-for-valid-url/' rel='bookmark' title='java.io.FileNotFoundException for valid URL'>java.io.FileNotFoundException for valid URL</a></li>
<li><a href='http://betweengo.com/2009/01/15/urlequals-and-hashcode-make-blocking-internet-connections/' rel='bookmark' title='URL.equals and hashCode make blocking Internet connections'>URL.equals and hashCode make blocking Internet connections</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=Jgp58crbkvU:TQWs_RzxW7s:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=Jgp58crbkvU:TQWs_RzxW7s:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=Jgp58crbkvU:TQWs_RzxW7s:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=Jgp58crbkvU:TQWs_RzxW7s:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=Jgp58crbkvU:TQWs_RzxW7s:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/Jgp58crbkvU" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/07/09/why-is-there-a-_requestid-in-my-url/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/07/09/why-is-there-a-_requestid-in-my-url/</feedburner:origLink></item>
		<item>
		<title>Fixing Resource Already Exists on Disk Errors in Eclipse</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/3ZlzhMb4H78/</link>
		<comments>http://betweengo.com/2012/07/02/fixing-resource-already-exists-on-disk-errors-eclipse/#comments</comments>
		<pubDate>Mon, 02 Jul 2012 13:00:13 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Eclipse]]></category>
		<category><![CDATA[debug]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1267</guid>
		<description><![CDATA[When I imported a new project I could not build it because of &#8220;Resource already exists on disk&#8221; errors like this. The simple fix was to remove the directory, typically classes, which contained the file it was complaining about and &#8230; <a href="http://betweengo.com/2012/07/02/fixing-resource-already-exists-on-disk-errors-eclipse/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2006/02/22/import-project-into-eclipse/' rel='bookmark' title='Import A Project Into Eclipse'>Import A Project Into Eclipse</a></li>
<li><a href='http://betweengo.com/2008/04/22/eclipse-does-not-understand-maven2_classpath_container/' rel='bookmark' title='Eclipse does not understand MAVEN2_CLASSPATH_CONTAINER'>Eclipse does not understand MAVEN2_CLASSPATH_CONTAINER</a></li>
<li><a href='http://betweengo.com/2008/07/18/eclipse-ganymede/' rel='bookmark' title='Eclipse Ganymede'>Eclipse Ganymede</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p>When I imported a new project I could not build it because of &#8220;Resource already exists on disk&#8221; errors like this.</p>
<p style="text-align: center;"><img class="size-full wp-image-1272 aligncenter" title="Eclipse: The project was not built due to &quot;Resource already exists on disk&quot;" src="http://betweengo.com/wp-content/uploads/2012/06/resource-already-exists-on-disk1.png" alt="Eclipse: The project was not built due to &quot;Resource already exists on disk&quot;" width="415" height="180" /></p>
<p>The simple fix was to remove the directory, typically classes, which contained the file it was complaining about and then refreshing. Removing just the file and then refreshing did not work.</p>
<p>However when I would do an ant build later and then refresh my project I would get the same error.</p>
<p>The better solution is to tell Eclipse not to copy the files it is complaining about to the output folder.</p>
<ol>
<li>Go to Project Properties.</li>
<li>Select Java Compiler -&gt; Building.</li>
<li>In the Filtered resources box add the files you don&#8217;t want copied.</li>
<li>Rebuild project.</li>
</ol>
<p>Here is a screenshot showing how I added &#8220;*.properties, *.xslt&#8221; to the Filtered resources to fix this problem.</p>
<div id="attachment_1315" class="wp-caption aligncenter" style="width: 510px"><a href="http://betweengo.com/wp-content/uploads/2012/07/eclipse-filtered-resources.png"><img class="size-medium wp-image-1315" title="Eclipse: Filtered resources in Project Properties, Java Compiler, Building" src="http://betweengo.com/wp-content/uploads/2012/07/eclipse-filtered-resources-500x439.png" alt="Eclipse: Filtered resources in Project Properties, Java Compiler, Building" width="500" height="439" /></a><p class="wp-caption-text">Eclipse: Filtered resources in Project Properties, Java Compiler, Building</p></div>
<p style="text-align: center;">
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F07%2F02%2Ffixing-resource-already-exists-on-disk-errors-eclipse%2F&amp;title=Fixing%20Resource%20Already%20Exists%20on%20Disk%20Errors%20in%20Eclipse" id="wpa2a_16"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2006/02/22/import-project-into-eclipse/' rel='bookmark' title='Import A Project Into Eclipse'>Import A Project Into Eclipse</a></li>
<li><a href='http://betweengo.com/2008/04/22/eclipse-does-not-understand-maven2_classpath_container/' rel='bookmark' title='Eclipse does not understand MAVEN2_CLASSPATH_CONTAINER'>Eclipse does not understand MAVEN2_CLASSPATH_CONTAINER</a></li>
<li><a href='http://betweengo.com/2008/07/18/eclipse-ganymede/' rel='bookmark' title='Eclipse Ganymede'>Eclipse Ganymede</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3ZlzhMb4H78:sP0dJ-pbuYA:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3ZlzhMb4H78:sP0dJ-pbuYA:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3ZlzhMb4H78:sP0dJ-pbuYA:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3ZlzhMb4H78:sP0dJ-pbuYA:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3ZlzhMb4H78:sP0dJ-pbuYA:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/3ZlzhMb4H78" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/07/02/fixing-resource-already-exists-on-disk-errors-eclipse/feed/</wfw:commentRss>
		<slash:comments>2</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/07/02/fixing-resource-already-exists-on-disk-errors-eclipse/</feedburner:origLink></item>
		<item>
		<title>Cannot Login To BCC</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/A7EIzDo724k/</link>
		<comments>http://betweengo.com/2012/06/25/cannot-login-to-bcc/#comments</comments>
		<pubDate>Mon, 25 Jun 2012 13:00:00 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Publishing]]></category>
		<category><![CDATA[bcc]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1257</guid>
		<description><![CDATA[Sometimes I can&#8217;t login to the BCC. Usually when that happens I see errors like this in the logs. page seeing error: /atg/templates/page/html/BizUIPageTemplate.jsp error message: null java.lang.NullPointerException at org.apache.pluto.factory.PortletObjectAccess.getRenderRequest(PortletObjectAccess.java:36) at org.apache.pluto.PortletContainerImpl.portletLoad(PortletContainerImpl.java:197) at atg.portal.portletstandard.services.ATGContainerService.portletLoad(ATGContainerService.java:202) at atg.portal.servlet.GearRequestDispatcherImpl.dispatch(GearRequestDispatcherImpl.java:397) at atg.portal.servlet.GearRequestDispatcherImpl.include(GearRequestDispatcherImpl.java:438) at atg.portal.servlet.GearRequestDispatcherImpl.include(GearRequestDispatcherImpl.java:453) at &#8230; <a href="http://betweengo.com/2012/06/25/cannot-login-to-bcc/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2012/04/25/clearing-out-bcc-projects/' rel='bookmark' title='Clearing Out BCC Projects'>Clearing Out BCC Projects</a></li>
<li><a href='http://betweengo.com/2009/02/04/unexplainable-jsp-compilation-problem/' rel='bookmark' title='Unexplainable JSP Compilation Problem'>Unexplainable JSP Compilation Problem</a></li>
<li><a href='http://betweengo.com/2005/08/30/jsp-dynamo-request-retrieval/' rel='bookmark' title='JSP Dynamo Request Retrieval'>JSP Dynamo Request Retrieval</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p><img style="background-image: none; padding-left: 0px; padding-right: 0px; display: block; float: none; margin-left: auto; margin-right: auto; padding-top: 0px; border: 0px;" title="Business Control Center Error" src="http://betweengo.com/wp-content/uploads/2012/06/bcc_login_failure.png" alt="Business Control Center Error" width="515" height="394" border="0" /></p>
<p>Sometimes I can&#8217;t login to the BCC. Usually when that happens I see errors like this in the logs.</p>
<pre>page seeing error: /atg/templates/page/html/BizUIPageTemplate.jsp
error message: null

java.lang.NullPointerException
   at org.apache.pluto.factory.PortletObjectAccess.getRenderRequest(PortletObjectAccess.java:36)
   at org.apache.pluto.PortletContainerImpl.portletLoad(PortletContainerImpl.java:197)
   at atg.portal.portletstandard.services.ATGContainerService.portletLoad(ATGContainerService.java:202)
   at atg.portal.servlet.GearRequestDispatcherImpl.dispatch(GearRequestDispatcherImpl.java:397)
   at atg.portal.servlet.GearRequestDispatcherImpl.include(GearRequestDispatcherImpl.java:438)
   at atg.portal.servlet.GearRequestDispatcherImpl.include(GearRequestDispatcherImpl.java:453)
   at atg.portal.framework.taglib.IncludeTag.doEndTag(IncludeTag.java:162)
   at atg.portal.framework.taglib.elwrap.IncludeTagWrapper.doEndTag(IncludeTagWrapper.java:36)
   at org.apache.jsp.templates.layout.html.BizUILayout_jsp._jspx_meth_paf_005finclude_005f0(BizUILayout_jsp.java:708)
   at org.apache.jsp.templates.layout.html.BizUILayout_jsp._jspService(BizUILayout_jsp.java:263)
....stack trace CROPPED after 10 lines.
ATG Business Control Center 
© ATG 2005-2011</pre>
<p>When this happens I first try clearing my cookies and then reloading the BCC login page.</p>
<p>When that doesn’t work I then remove the tmp and work directories.</p>
<pre>$ cd /opt/jboss/home/server/merch
$ rm -rf tmp work</pre>
<p>Then I restart the BCC and things seem happy again.</p>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F06%2F25%2Fcannot-login-to-bcc%2F&amp;title=Cannot%20Login%20To%20BCC" id="wpa2a_18"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2012/04/25/clearing-out-bcc-projects/' rel='bookmark' title='Clearing Out BCC Projects'>Clearing Out BCC Projects</a></li>
<li><a href='http://betweengo.com/2009/02/04/unexplainable-jsp-compilation-problem/' rel='bookmark' title='Unexplainable JSP Compilation Problem'>Unexplainable JSP Compilation Problem</a></li>
<li><a href='http://betweengo.com/2005/08/30/jsp-dynamo-request-retrieval/' rel='bookmark' title='JSP Dynamo Request Retrieval'>JSP Dynamo Request Retrieval</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=A7EIzDo724k:dHz8Sv4PQWA:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=A7EIzDo724k:dHz8Sv4PQWA:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=A7EIzDo724k:dHz8Sv4PQWA:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=A7EIzDo724k:dHz8Sv4PQWA:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=A7EIzDo724k:dHz8Sv4PQWA:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/A7EIzDo724k" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/06/25/cannot-login-to-bcc/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/06/25/cannot-login-to-bcc/</feedburner:origLink></item>
		<item>
		<title>Fixing Existing Repository ID Errors</title>
		<link>http://feedproxy.google.com/~r/betweengo/~3/3Os-iEl_3Bw/</link>
		<comments>http://betweengo.com/2012/06/11/fixing-existing-repository-id-errors/#comments</comments>
		<pubDate>Mon, 11 Jun 2012 23:42:55 +0000</pubDate>
		<dc:creator>Frank Kim</dc:creator>
				<category><![CDATA[Repository]]></category>
		<category><![CDATA[bcc]]></category>
		<category><![CDATA[sql]]></category>

		<guid isPermaLink="false">http://betweengo.com/?p=1253</guid>
		<description><![CDATA[I was feeling part of the scenery. I walked right out of the machinery. by Neal. The other day I was trying to create a page repository item using the BCC when I got an error saying it could not &#8230; <a href="http://betweengo.com/2012/06/11/fixing-existing-repository-id-errors/">Continue reading <span class="meta-nav">&#8594;</span></a><div class='yarpp-related-rss'>

Related posts:<ol>
<li><a href='http://betweengo.com/2005/08/11/mysterious-404-errors-atg-j2ee-apps/' rel='bookmark' title='Mysterious 404 errors in ATG J2EE applications'>Mysterious 404 errors in ATG J2EE applications</a></li>
<li><a href='http://betweengo.com/2009/11/12/the-dangers-of-custom-atg-repository-ids/' rel='bookmark' title='The Dangers of Custom ATG Repository ID&rsquo;s.'>The Dangers of Custom ATG Repository ID&rsquo;s.</a></li>
<li><a href='http://betweengo.com/2012/07/02/fixing-resource-already-exists-on-disk-errors-eclipse/' rel='bookmark' title='Fixing Resource Already Exists on Disk Errors in Eclipse'>Fixing Resource Already Exists on Disk Errors in Eclipse</a></li>
</ol>
</div>
]]></description>
				<content:encoded><![CDATA[<p align="center"><a href="http://www.flickr.com/photos/31878512@N06/4384619817/"><img title="I was feeling part of the scenery. I walked right out of the machinery. | Flickr" src="http://farm5.staticflickr.com/4056/4384619817_0f5ea1fee8.jpg" alt="I was feeling part of the scenery. I walked right out of the machinery. | Flickr" /></a></p>
<p align="center"><a title="I was feeling part of the scenery. I walked right out of the machinery. | Flickr" href="http://www.flickr.com/photos/31878512@N06/4384619817/">I was feeling part of the scenery. I walked right out of the machinery.</a> by <a title="Flickr: Neal.'s photostream" href="http://www.flickr.com/photos/31878512@N06/">Neal.</a></p>
<p>The other day I was trying to create a page repository item using the BCC when I got an error saying it could not create the item. Looking in the logs I saw this exception.</p>
<pre>16:13:59,909 ERROR [RepositoryAssetService]
atg.repository.RepositoryException: createItem() was called with an existing ID : '3100007' for type 'page'. Use getItemForUpdate() instead.
        at atg.adapter.version.VersionRepository.createItem(VersionRepository.java:1903)
        at atg.adapter.version.VersionRepository.createItem(VersionRepository.java:1125)
        at atg.remote.assetmanager.editor.service.RepositoryAssetServiceImpl.doCreateAsset(RepositoryAssetServiceImpl.java:476)
        at atg.remote.assetmanager.editor.service.AssetServiceImpl.createAsset(AssetServiceImpl.java:331)
        at atg.remote.assetmanager.editor.service.AssetEditorService.createAssetAndLink(AssetEditorService.java:555)
        at atg.remote.assetmanager.editor.service.AssetEditorService.createAsset(AssetEditorService.java:508)</pre>
<p>The problem was the ID generator was producing ID’s that already existed in the database. This sometimes happens when things are imported into the BCC.</p>
<p>To fix this problem do the following.</p>
<ol>
<li>Look for the row in the das_id_generator table which has the item descriptor that is causing the error.</li>
<li>Change the seed value (typically upwards) or put a prefix or suffix on it.</li>
<li>Restart the server.</li>
</ol>
<p>In this case I ended up running this SQL to fix the existing ID error:</p>
<pre>UPDATE DAS_ID_GENERATOR SET PREFIX = 'pg_' WHERE id_space_name = ‘page’;</pre>
<p><a class="a2a_dd a2a_target addtoany_share_save" href="http://www.addtoany.com/share_save#url=http%3A%2F%2Fbetweengo.com%2F2012%2F06%2F11%2Ffixing-existing-repository-id-errors%2F&amp;title=Fixing%20Existing%20Repository%20ID%20Errors" id="wpa2a_20"><img src="http://betweengo.com/wp-content/plugins/add-to-any/share_save_171_16.png" width="171" height="16" alt="Share"/></a></p><div class='yarpp-related-rss'>
<p>Related posts:<ol>
<li><a href='http://betweengo.com/2005/08/11/mysterious-404-errors-atg-j2ee-apps/' rel='bookmark' title='Mysterious 404 errors in ATG J2EE applications'>Mysterious 404 errors in ATG J2EE applications</a></li>
<li><a href='http://betweengo.com/2009/11/12/the-dangers-of-custom-atg-repository-ids/' rel='bookmark' title='The Dangers of Custom ATG Repository ID&rsquo;s.'>The Dangers of Custom ATG Repository ID&rsquo;s.</a></li>
<li><a href='http://betweengo.com/2012/07/02/fixing-resource-already-exists-on-disk-errors-eclipse/' rel='bookmark' title='Fixing Resource Already Exists on Disk Errors in Eclipse'>Fixing Resource Already Exists on Disk Errors in Eclipse</a></li>
</ol></p>
</div>
<div class="feedflare">
<a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:yIl2AUoC8zA"><img src="http://feeds.feedburner.com/~ff/betweengo?d=yIl2AUoC8zA" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:D7DqB2pKExk"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3Os-iEl_3Bw:n48C06apnvI:D7DqB2pKExk" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:F7zBnMyn0Lo"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3Os-iEl_3Bw:n48C06apnvI:F7zBnMyn0Lo" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:V_sGLiPBpWU"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3Os-iEl_3Bw:n48C06apnvI:V_sGLiPBpWU" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:qj6IDK7rITs"><img src="http://feeds.feedburner.com/~ff/betweengo?d=qj6IDK7rITs" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:gIN9vFwOqvQ"><img src="http://feeds.feedburner.com/~ff/betweengo?i=3Os-iEl_3Bw:n48C06apnvI:gIN9vFwOqvQ" border="0"></img></a> <a href="http://feeds.feedburner.com/~ff/betweengo?a=3Os-iEl_3Bw:n48C06apnvI:TzevzKxY174"><img src="http://feeds.feedburner.com/~ff/betweengo?d=TzevzKxY174" border="0"></img></a>
</div><img src="http://feeds.feedburner.com/~r/betweengo/~4/3Os-iEl_3Bw" height="1" width="1"/>]]></content:encoded>
			<wfw:commentRss>http://betweengo.com/2012/06/11/fixing-existing-repository-id-errors/feed/</wfw:commentRss>
		<slash:comments>0</slash:comments>
		<feedburner:origLink>http://betweengo.com/2012/06/11/fixing-existing-repository-id-errors/</feedburner:origLink></item>
	</channel>
</rss><!-- WP Super Cache is installed but broken. The path to wp-cache-phase1.php in wp-content/advanced-cache.php must be fixed! -->
