ÔÚweblogic8.14ÀïÃæ²Ù×÷oracle´ó×Ö¶Î
1.Ê×ÏÈ˵Ã÷һϣº
ÔÒòÊÇÒòΪÎÒÔÚ×öÕâ¸öÏîĿʱ£¬±»ÏÞÖÆµÃÌ«¶à£¬weblogicºÍoracleµÄ°æ±¾²»Äܱ䣬ҪʹÓÃÔÀ´µÄ°æ±¾¡£
Òò´ËÄØ¡£²Ù×÷ÆðÀ´±È½ÏÂé·³¡£¶øÇÒ²»Äܸü¸ÄÔ±¾¹¤³ÌÀïÃæµÄJar°ü£¨ËüÀïÃæ´æÔÚÁËoracle14.jar°ü£¬µ«±È½Ï¾É£©
weblogic°æ±¾Îª£º8.14
oracle°æ±¾Îª£º9i
2.ÔÚÕâÀïÄØ£¬Ê¹ÓÃhibernate£¬ÒÔÁ÷µÄÐÎʽ¶ÁÈ¡µ½Êý¾ÝÀïÃæ¡£
3.Êý¾Ý±íÄØ£ºÊÇÒ»Õű£´æÎļþµÄ±í
ÈçÏ£º
CREATE TABLE T_UPLOAD_FILE (
FILE_ID VARCHAR2(60) PRIMARY KEY NOT NULL,
FILE_NAME VARCHAR2(250) NOT NULL,
OLD_FILE_NAME VARCHAR2(250) NOT NULL,
FILE_PATH VARCHAR2(250) NOT NULL,
FILE_TYPE VARCHAR2(10),
FILE_SIZE LONG,
STATUS CHAR(1) NOT NULL,
UPLOAD_TIME TIMESTAMP,
OPERATOR_ID VARCHAR2(30),
FILE_CONTENT BLOB
);
4.Ò»¸öÉÏ´«ÎļþµÄÎļþ¶ÔÏó£º
UploadFileBFO£º
private java.lang.String fileId;
private java.lang.String fileName;
private java.lang.String filePath;
private java.lang.Long fileSize;
private java.lang.String fileType;
private java.lang.String oldFileName;
private java.lang.String status;
private java.sql.Timestamp uploadTime;
private java.lang.String operatorId;
private java.sql.Blob fileContent;
//....get/set·½·¨
5.ÔÚDAOÀïÃæÊµÏÖ£º
/**
* ±£´æÎļþµ½Êý¾Ý¿â±íÖÐ
*/
public boolean saveFileToDatabase(UploadFileBFO uploadFileBFO) {
boolean result = true;
Session s = null;
byte[] buffer = new byte[1];
buffer[0] = 1;
OutputStream out = null;
FileInputStream fin = null;
try {
SessionFactory sf = this.getSessionFactory();
s = sf.openSession();
Transaction tx = s.beginTransaction();
// »ñÈ¡ÒѾ±£´æµ½Êý¾Ý¿âµÄ¶ÔÏó
TUploadFileBO fileBO = getById(uploadFileBFO.getFileId());
fileBO.setFileContent(Hibernate.createBlob(buffer));
s.update(fileBO); // ¸üжÔÏó
s.flush();
s.refresh(fileBO, LockMode.UPGRADE);
SerializableBlob
Ïà¹ØÎĵµ£º
ÔÎĵØÖ·£ºhttp://guyuanli.itpub.net/post/37743/484763
ÿÌì1µãÖ´ÐеÄoracle JOBÑùÀý
DECLARE
X NUMBER;
BEGIN
SYS.DBMS_JOB.SUBMIT
( job =>
X,
what => 'ETL_RUN_D_Date;',
next_date => to_date('2009-08-26
01:00:00','yyyy-mm-dd hh24:mi:ss'),
interval =>
'trunc(sysdate)+1+1/24',
n ......
ÔÚʹÓÃtomcatʱ£¬Èç¹û±¾»ú×°ÔØÁËoracle£¬ÄÇôÊÇÎÞ·¨Æô¶¯µÄ£¬ÒòΪ8080¶Ë¿ÚÒѱ»Õ¼ÓÃÁË¡£µ±È»¿ÉÒÔͨ¹ýÐÞ¸Ä server.mxlµÄ¶Ë¿ÚºÅʹtomcatµÄ¶Ë¿Ú²»ÊÇ8080£¬ÎÒÃÇ»¹¿ÉÒÔÐÞ¸ÄoracleµÄweb·þÎñÆ÷µÄ¶Ë¿Ú£¬²½Ö裺
1£©£¬´ò¿ªoracleµÄsqlÃüÁîÊäÈë´°¿Ú
2£©£¬Á¬½Óµ½Oracle·þÎñÆ÷£¬ÓÃÃüÁîconn sys as SYSDBA
3£©£¬ÓÃÃûÁca ......
¸ÅÊö
ÐéÄâרÓÃÊý¾Ý¿â (VPD) ÌṩÁ˽ÇÉ«ºÍÊÓͼÎÞ·¨ÌṩµÄÐм¶·ÃÎÊ¿ØÖÆ¡£¶ÔÓÚ»¥ÁªÍø·ÃÎÊ£¬ÐéÄâרÓÃÊý¾Ý¿â¿ÉÒÔÈ·±£ÔÚÏßÒøÐеĿͻ§Ö»ÄÜ¿´µ½ËûÃÇ×Ô¼ºµÄÕÊ»§¡£Web Íйܹ«Ë¾¿ÉÒÔÔÚͬһ Oracle Êý¾Ý¿âÖÐά»¤¶à¸ö¹«Ë¾µÄÊý¾Ý£¬µ«Ö»ÔÊÐíÿ¸ö¹«Ë¾²é¿´Æä×ÔÉíÊý¾Ý¡£
ÔÚÆóÒµÄÚ²¿£¬ÐéÄâÊý¾Ý¿â¿ÉÔÚÓ¦ÓóÌÐò²¿Êð·½Ãæ½µµÍÓµÓгɱ¾¡£¿ÉÒÔÔÚÊý ......
¡¡¡¡1. Oracle°²裝Íê³ÉºóµÄ³õʼ¿ÚÁ
¡¡¡¡internal/oracle
¡¡¡¡sys/change_on_install
¡¡¡¡system/manager
¡¡¡¡scott/tiger
¡¡¡¡sysman/oem_temp
¡¡¡¡2. ORACLE9IAS WEB CACHEµÄ³õʼĬÈÏÓû§ºÍÃÜÂ룿
¡¡¡¡administrator/administrator
¡¡¡¡3. oracle 8.0.5Ôõô´´½¨Êý¾Ý¿â£¿
¡¡¡¡ÓÃorainst¡£Èç¹ûÓ ......