<?xml version="1.0" encoding="utf-8"?>
<rss version="2.0">
	<channel>
		<title>数据库（Oracle/MySQL）</title>
		<link>http://www.pfeng.org/category/database/</link>
		<description>网络编程，开源，数据库技术，软件开发</description>
		<copyright>Powered by SaBlog-X. Copyright (C) 2003-2010.</copyright>
		<generator>SaBlog-X Version 2.0 Build 20100301</generator>
		<lastBuildDate>Thu, 23 Feb 2012 03:46:15 +0000</lastBuildDate>
		<ttl>30</ttl>
		<item>
			<link>http://www.pfeng.org/archives/67/</link>
			<guid>http://www.pfeng.org/archives/67/</guid>
			<title>SQLite3 返回值解释</title>
			<author>xxmc01@gmail.com(pfeng)</author>
			<description><![CDATA[PF-blog | 我的在线生活志-pfeng.org ( http://www.pfeng.org/ ) : <p>
	&nbsp;</p>
<pre class="brush:cpp;">
//成功返回SQLITE_OK ，即0
#define SQLITE_OK           0   /* Successful result */
/* beginning-of-error-codes */
//SQLITE 错误代码宏
#define SQLITE_ERROR        1   /* SQL error or missing database */
#define SQLITE_INTERNAL     2   /* Internal logic error in SQLite */
#define SQLITE_PERM         3   /* Access permission denied */
#define SQLITE_ABORT        4   /* Callback routine requested an abort */
#define SQLITE_BUSY         5   /* The database file is locked */
#define SQLITE_LOCKED       6   /* A table in the database is locked */
#define SQLITE_NOMEM        7   /* A malloc() failed */
#define SQLITE_READONLY     8   /* Attempt to write a readonly database */
#define SQLITE_INTERRUPT    9   /* Operation terminated by sqlite3_interrupt()*/
#define SQLITE_IOERR       10   /* Some kind of disk I/O error occurred */
#define SQLITE_CORRUPT     11   /* The database disk image is malformed */
#define SQLITE_NOTFOUND    12   /* NOT USED. Table or record not found */
#define SQLITE_FULL        13   /* Insertion failed because database is full */
#define SQLITE_CANTOPEN    14   /* Unable to open the database file */
#define SQLITE_PROTOCOL    15   /* NOT USED. Database lock protocol error */
#define SQLITE_EMPTY       16   /* Database is empty */
#define SQLITE_SCHEMA      17   /* The database schema changed */
#define SQLITE_TOOBIG      18   /* String or BLOB exceeds size limit */
#define SQLITE_CONSTRAINT  19   /* Abort due to constraint violation */
#define SQLITE_MISMATCH    20   /* Data type mismatch */
#define SQLITE_MISUSE      21   /* Library used incorrectly */
#define SQLITE_NOLFS       22   /* Uses OS features not supported on host */
#define SQLITE_AUTH        23   /* Authorization denied */
#define SQLITE_FORMAT      24   /* Auxiliary database format error */
#define SQLITE_RANGE       25   /* 2nd parameter to sqlite3_bind out of range */
#define SQLITE_NOTADB      26   /* File opened that is not a database file */
#define SQLITE_ROW         100  /* sqlite3_step() has another row ready */
#define SQLITE_DONE        101  /* sqlite3_step() has finished executing */
/* end-of-error-codes */</pre>
]]></description>
			<link>http://www.pfeng.org/archives/67/</link>
			<category domain="http://www.pfeng.org/category/database/">数据库（Oracle/MySQL）</category>
			<pubDate>Thu, 08 Dec 2011 17:15:42 +0000</pubDate>
		</item>
		<item>
			<link>http://www.pfeng.org/archives/64/</link>
			<guid>http://www.pfeng.org/archives/64/</guid>
			<title>三步解决Oracle数据库死锁</title>
			<author>xxmc01@gmail.com(pfeng)</author>
			<description><![CDATA[PF-blog | 我的在线生活志-pfeng.org ( http://www.pfeng.org/ ) : <p>
	第一步：查看是否有死锁存在，查出有数据则代表有死锁&nbsp;&nbsp;</p>
<pre class="brush:sql;">
select p.spid,c.object_name,b.session_id,b.oracle_username,b.os_user_name  from v$process p,v$session a,v$locked_object b,all_objects   c  
where  p.addr=a.paddr  
and    a.process=b.process  
and    c.object_id=b.object_id</pre><p><a href="http://www.pfeng.org/archives/64/" target="_blank">阅读全文</a></p>]]></description>
			<link>http://www.pfeng.org/archives/64/</link>
			<category domain="http://www.pfeng.org/category/database/">数据库（Oracle/MySQL）</category>
			<pubDate>Sun, 04 Dec 2011 18:30:19 +0000</pubDate>
		</item>
		<item>
			<link>http://www.pfeng.org/archives/21/</link>
			<guid>http://www.pfeng.org/archives/21/</guid>
			<title>SQL中char，varchar 和nchar，nvarchar的区别</title>
			<author>xxmc01@gmail.com(pfeng)</author>
			<description><![CDATA[PF-blog | 我的在线生活志-pfeng.org ( http://www.pfeng.org/ ) : <p>
	基础知识把握的不牢固，所以又在网上搜这个问题，看到这篇文章讲述的比较清楚，索性转载下来：（原文：olsonlowey）</p>
<p>
	Varchar 对每个英文(ASCII)字符都占用2个字节，对一个汉字也只占用两个字节<br />
	char 对英文(ASCII)字符占用1个字节，对一个汉字占用2个字节<br />
	Varchar 的类型不以空格填满，比如varchar(100)，但它的值只是&quot;qian&quot;,则它的值就是&quot;qian&quot;<br />
	而char 不一样，比如char(100),它的值是&quot;qian&quot;，而实际上它在数据库中是&quot;qian &quot;(qian后共有96个空格，<br />
	就是把它填满为 100个字节)。</p>
<p><a href="http://www.pfeng.org/archives/21/" target="_blank">阅读全文</a></p>]]></description>
			<link>http://www.pfeng.org/archives/21/</link>
			<category domain="http://www.pfeng.org/category/database/">数据库（Oracle/MySQL）</category>
			<pubDate>Sun, 18 Apr 2010 14:22:08 +0000</pubDate>
		</item>
		<item>
			<link>http://www.pfeng.org/archives/19/</link>
			<guid>http://www.pfeng.org/archives/19/</guid>
			<title>MYSQL--事务处理（通俗易懂）</title>
			<author>xxmc01@gmail.com(pfeng)</author>
			<description><![CDATA[PF-blog | 我的在线生活志-pfeng.org ( http://www.pfeng.org/ ) : <p>
	直以来我都以为MYSQL不支持事务处理，所以在处理多个数据表的数据时，一直都很麻烦（我是不得不将其写入文本文件，在系统重新加载得时候才写入数据库 以防出错）～今天发现MYSQL数据库从4.1就开始支持事务功能，据说5.0将引入存储过程^_^</p>
<p><a href="http://www.pfeng.org/archives/19/" target="_blank">阅读全文</a></p>]]></description>
			<link>http://www.pfeng.org/archives/19/</link>
			<category domain="http://www.pfeng.org/category/database/">数据库（Oracle/MySQL）</category>
			<category domain="http://www.pfeng.org/tag/%E4%BA%8B%E5%8A%A1/">事务</category>
			<pubDate>Sun, 18 Apr 2010 14:15:19 +0000</pubDate>
		</item>
		<item>
			<link>http://www.pfeng.org/archives/9/</link>
			<guid>http://www.pfeng.org/archives/9/</guid>
			<title>MYSQL字符乱码问题解决办法</title>
			<author>xxmc01@gmail.com(pfeng)</author>
			<description><![CDATA[PF-blog | 我的在线生活志-pfeng.org ( http://www.pfeng.org/ ) : <p>
	初涉PHP和mysql的新手都可能会遇到一个头疼的问题：乱码！解决和规避乱码问题其实很简单，只要字符集统一，一般不会出现问题。这篇文章从实例讲解了如何解决mysql数据库的乱码问题。</p>
<p><a href="http://www.pfeng.org/archives/9/" target="_blank">阅读全文</a></p>]]></description>
			<link>http://www.pfeng.org/archives/9/</link>
			<category domain="http://www.pfeng.org/category/database/">数据库（Oracle/MySQL）</category>
			<category domain="http://www.pfeng.org/tag/%E4%B9%B1%E7%A0%81/">乱码</category>
			<category domain="http://www.pfeng.org/tag/mysql/">mysql</category>
			<category domain="http://www.pfeng.org/tag/php/">php</category>
			<comments>http://www.pfeng.org/archives/9/#comments</comments>
			<pubDate>Fri, 09 Apr 2010 09:35:04 +0000</pubDate>
		</item>
	</channel>
</rss>

