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

<channel>
	<title>P.Linux Laboratory &#187; ROM</title>
	<atom:link href="http://www.penglixun.com/tag/rom/feed" rel="self" type="application/rss+xml" />
	<link>http://www.penglixun.com</link>
	<description>MySQL DBA &#38; Linux SA</description>
	<lastBuildDate>Sun, 22 Jan 2012 16:34:39 +0000</lastBuildDate>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
		<item>
		<title>ORM or ROM？</title>
		<link>http://www.penglixun.com/tech/program/orm_or_rom.html</link>
		<comments>http://www.penglixun.com/tech/program/orm_or_rom.html#comments</comments>
		<pubDate>Wed, 14 Oct 2009 15:49:43 +0000</pubDate>
		<dc:creator>P.Linux</dc:creator>
				<category><![CDATA[程序设计]]></category>
		<category><![CDATA[J2EE]]></category>
		<category><![CDATA[JAVA]]></category>
		<category><![CDATA[ORM]]></category>
		<category><![CDATA[ROM]]></category>

		<guid isPermaLink="false">http://www.penglixun.com/PLX/Blog/?p=424</guid>
		<description><![CDATA[本文内容遵从CC版权协议, 可以随意转载, 但必须以超链接形式标明文章原始出处和作者信息及版权声明网址: http://www.penglixun.com/tech/program/orm_or_rom.html 看了一个网站http://kinghost.mirrors.phpclasses.org/... ]]></description>
			<content:encoded><![CDATA[<p><span style="color: #888888;">本文内容遵从<a href="http://creativecommons.org/licenses/by-nc-sa/3.0/deed.zh" target="_blank">CC版权协议</a>, 可以随意转载, 但必须以超链接形式标明文章原始出处和作者信息及版权声明</br>网址: http://www.penglixun.com/tech/program/orm_or_rom.html </p>
<p></span>看了一个网站http://kinghost.mirrors.phpclasses.org/blog/post/82-<acronym title="Pre-Hypertext Processing">PHP</acronym>-ObjectRelational-Mapping-ORM-or-ROM.html，好东西不少。<br />
又翻看了些博文，http://bighou.javaeye.com/blog/425708，http://luwenpan-gmail-com.javaeye.com/blog/262918。</p>
<p>才发现我一直理解的ORM其实是ROM。我一直以为是先设计表结构，再把表结构映射成对象；看了这些文章，如果我没有理解错的话，先设计表结构（Relationship）再映射成对象（Object）是ROM，并非ORM。Hibernate是ORM工具，也就是先设计对象，再映射为数据库表，实现持久化。<br />
可是这样一来，数据库层面的优化怎么做呢，对象直接映射为表，这是没优化过的模式。实际生产库中应该还是先设计表结构再做ROM吧，Hibernate虽然有ORM，但是实际生产中优化更重要吧，编程上的便捷损失了太多运行效率应该是得不偿失的。<br />
对J2EE不太了解，希望有开发经验的同志们能指点一下。</p><h2  class="related_post_title">类似的文章</h2><ul class="related_post"><li>2010年04月9日 -- <a href="http://www.penglixun.com/tech/system/xfce_zendstudio_error.html" title="Xfce下ZendStudio的报错处理">Xfce下ZendStudio的报错处理</a> (0)</li><li>2009年10月22日 -- <a href="http://www.penglixun.com/tech/program/j2ee_curriculum_design_done.html" title="一个晚上折腾完了J2EE的课设">一个晚上折腾完了J2EE的课设</a> (0)</li></ul>]]></content:encoded>
			<wfw:commentRss>http://www.penglixun.com/tech/program/orm_or_rom.html/feed</wfw:commentRss>
		<slash:comments>0</slash:comments>
		</item>
	</channel>
</rss>

