Ò׽ؽØÍ¼Èí¼þ¡¢µ¥Îļþ¡¢Ãâ°²×°¡¢´¿ÂÌÉ«¡¢½ö160KB

¶ÔoracleÖеÄBLOBµÄ²Ù×÷(¶ÁÈ¡£¬Ð´Èë)

 ½«BLOB±£´æÎª±¾µØÎĵµ£º
/// <summary>
/// ¶Á³öBlob×Ö¶Î
/// </summary>
/// <param name="commandText">sqlÓï¾ä£¬Ö´Ðнá¹ûΪBLOBÊý¾Ý</param>
/// <param name="DocumentAddress">½«Òª°ÑBLOBÊý¾Ý±£´æÎªµÄÎĵµµÄ·¾¶</param>
public void ReadBlob(string commandText, string DocumentAddress)
{
try
{
Open();
cmd.Connection = conn;
cmd.CommandType = CommandType.Text;
cmd.CommandText = commandText;
// ÀûÓÃÊÂÎñ´¦Àí£¨±ØÐ룩
OracleTransaction transaction = cmd.Connection.BeginTransaction();
cmd.Transaction = transaction;
reader = cmd.ExecuteReader();
reader.Read();
OracleLob BLOB = reader.GetOracleLob(0);
reader.Close();
FileStream DataStream = new FileStream(DocumentAddress, FileMode.Create);
int length = 30485760;
byte[] Buffer = new byte[length];
int i;
while ((i = BLOB.Read(Buffer, 0, length)) > 0)
{
DataStream.Write(Buffer, 0, i);
}
DataStream.Close();
BLOB.Clone();
cmd.Transaction.Commit();
}
catch (OracleException e)
{
cmd.Transaction.Rollback();
throw e;
}
finally
{
Close();
}
}

½«±¾µØÎĵµ±£´æÎªBLOBÀàÐÍ£º
/// <summary>
/// дÈëBlob×Ö¶Î
/// </summary>
/// <param name="commandText">sqlÓï¾ä£¬Ö´Ðнá¹ûΪBLOBÊý¾Ý</param>
/// <param name="DocumentAddress">±¾µØÎĵµµÄ·¾¶</param>
public void WriteBlob(string commandText, string DocumentAddress


Ïà¹ØÎĵµ£º

½²½âOracleÊý¾Ý¿â×Ô¶¯Ôö³¤ÁеÄʵÏÖ¹ý³Ì

OracleÊý¾Ý¿â×Ô¶¯Ôö³¤ÁеÄʵÏÖ¹ý³Ì:
¡ô1.´´½¨ÐòÁÐ
 
-- Create sequence
create sequence INNERID
minvalue 1
maxvalue 99999999999999
start with 1
increment by 1
cache 20
order;
 
 
 
¡ô2.--INNERID.currval Ö¸µ±Ç°ÐòÁÐ
      --INNERID.nextval Ö¸Ï ......

Oracle¸ßˮλÏß

1. ×¼±¸ÖªÊ¶£ºORACLEµÄÂß¼­´æ´¢¹ÜÀí.
ORACLEÔÚÂß¼­´æ´¢ÉÏ·Ö4¸öÁ£¶È:±í¿Õ¼ä,¶Î,ÇøºÍ¿é.
1.1 ¿é:ÊÇÁ£¶È×îСµÄ´æ´¢µ¥Î»,ÏÖÔÚ±ê×¼µÄ¿é´óСÊÇ8K,ORACLEÿһ´ÎI/O²Ù×÷Ò²Êǰ´¿éÀ´²Ù×÷µÄ,Ò²¾ÍÊÇ˵µ±ORACLE´ÓÊý¾ÝÎļþ¶ÁÊý¾Ýʱ,ÊǶÁÈ¡¶àÉÙ¸ö¿é,¶ø²»ÊǶàÉÙÐÐ.
1.2 Çø:ÓÉһϵÁÐÏàÁÚµÄ¿é¶ø×é³É,ÕâÒ²ÊÇORACLE¿Õ¼ä·ÖÅäµÄ»ù±¾µ¥Î»,¾Ù¸ö ......

Oracle³£¼û´íÎó——ORA 00845


Oracle 11gµÄLinux°æ±¾ÔÚÐÞ¸ÄÁËMEMORY_TARGET»òÕßSGA_TARGETºóÆô¶¯¿ÉÄܻᱨ´í£º
SQL> shutdown immediate
Database closed.
Database dismounted.
ORACLE instance shut down.
SQL> startup
ORA-00845: MEMORY_TARGET not supported on this system
 
 
Õâ¸öÎÊÌâÊÇÓÉÓÚÉèÖÃSGAµÄ´óС³¬¹ýÁ˲Ù×÷Ï ......

Oracle³£¼û´íÎó——TNS 01150

# LISTENER.ORA Network Configuration File: /opt/oracle/product/9.2/network/admin/listener.ora
# Generated by Oracle configuration tools.
ORA92 =
  (DESCRIPTION_LIST =
    (DESCRIPTION =
      (ADDRESS_LIST =
        (ADDRESS ......

¹â»·¾¡Ê§ OracleÔÚÖйúÈ«ÃæÔâÓö¡°»¬Ìú¬¡±

 
¼Ì9Ô·ݹúÄÚÄ³ÖØÒªITÃÅ»§ÍøÕ¾±¬³ö¡¶520ÍòOracle ERPÏîĿʧ°ÜÖ®ÃÕ¡·µÄ“Ìì¼Û·ç²¨”Ö®ºó£¬11Ô·ݣ¬¹úÄÚijӰÏì×î´óµÄITרҵƽýÔÙ±¬¡¶¼×¹ÇÎÄÅöײ±ùɽ£º²¢¹ºSun½øÍËÁ½ÄÑ¡·¡£Á½Æª±¨µÀ´Ó²»Í¬½Ç¶È½Ò¶ÁËOracleÔÚÖйúµÄ¼Û¸ñ“Òþ˽”¡¢ÇþµÀÂÒÏ󡢿ͻ§Á÷ʧµÈ¾½Ïà¡£×ÅʵÈÃOracleÖйú¹«Ë¾µÄ¹«¹ØÃÇæ»îÁ˺ÃÒ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ