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

Ò»¸öÊý¾Ý¿â²Ù×÷À࣬ÊÊÓÃÓÚOracle£¬ACCESS,SQLSERVER

     ×î½ü×öÁËÒ»¸öÊý¾ÝÕï¶ÏµÄÏîÄ¿£¬ÀïÃæ×Ô¼ºÐ´ÁËÒ»¸öÊý¾Ý¿âµÄ²Ù×÷À࣬°üº¬£ºÁ¬½ÓÊý¾Ý¿â¡¢¶ÁÊý¾Ý±í¡¢Ö´ÐÐSQL²Ù×÷£¬ÊÍ·ÅÊý¾Ý¿âµÈ×é³É£¬Ï£Íû¶Ô´ó¼ÒÓÐÓã¬ÓÉÓÚˮƽÓÐÏÞ£¬ÈôÓдíÎó»òÕß´úÂë²»×ãµØ·½»¶Ó­Ö¸Õý£¬Ð»Ð»¡£
ADOOperate.H
//////////////////////////////////////////////////////////////////////
// À๦ÄÜ£ºÓÃÓÚÊý¾Ý¿âµÄ²Ù×÷ Ö÷ҪʵÏÖ Á¬½ÓÊý¾Ý¿â ¶ÁÊý¾Ý±í ¼ì²éÊý¾Ý±í Ö´ÐÐSQLÓï¾ä
//
// Ëï¸ß³¯ 2010.03.25
//////////////////////////////////////////////////////////////////////
#if !defined(AFX_ADOOPERATE_H__EB4AC016_15D4_46E9_A754_E1C1A036DAAE__INCLUDED_)
#define AFX_ADOOPERATE_H__EB4AC016_15D4_46E9_A754_E1C1A036DAAE__INCLUDED_
#if _MSC_VER > 1000
#pragma once
#endif // _MSC_VER > 1000
#include "stdafx.h"
class CADOOperate
{
public:
CString m_DataSource; // Êý¾ÝÔ´
CString m_PassWord; // ÃÜÂë
CString m_UserName; // Êý¾Ý¿âÃû
_ConnectionPtr m_pConn; // ADOÁ¬½Ó
CString strTableName; // ±íÃû Íâ±ß´«Èë
_RecordsetPtr m_pRst; // ¼Ç¼¼¯
public:
BOOL funCheckTable(CString strName,CString strDBType);
BOOL ExecuteSQL(CString strSQL,LPCSTR strDBType = ORACLE);
_RecordsetPtr& ReadTable(LPCSTR strSQL1 = NULL,LPCSTR strDBType = ORACLE); // ¶Á±í ·µ»Ø¼Ç¼¼¯
BOOL OpenDataBase(CString lpDBType); // Á¬½ÓÊý¾Ý¿â
void ExitADO();
CADOOperate();
virtual ~CADOOperate();
};
#endif // !defined(AFX_ADOOPERATE_H__EB4AC016_15D4_46E9_A754_E1C1A036DAAE__INCLUDED_)
 
ADOOperate.C
// ADOOperate.cpp: implementation of the CADOOperate class.
//
//////////////////////////////////////////////////////////////////////
#include "stdafx.h"
#include "ADOOperate.h"
#include "h_Const.h"
#include "ShareFun.h"
#include "FileLog.h"
//////////////////////////////////////////////////////////////////////
// Construction/Destruction
//////////////////////////////////////////////////////////////////////
CADOOperate::CADOOperate()
{
strTableName = " "; // ³õʼ»¯±íÃû
m_DataSource = " "; // Êý¾ÝÔ´
m_PassWord = " "; // ÃÜÂë
m_UserName = " "; // Êý¾


Ïà¹ØÎĵµ£º

Oracle job ¹ÜÀí

SVRMGR> select * from dba_jobs;
³õʼ»¯Ïà¹Ø²ÎÊýjob_queue_processes
alter system set job_queue_processes=39 scope=spfile;//×î´óÖµ²»Äܳ¬¹ý1000  ;job_queue_interval = 10  //µ÷¶È×÷ҵˢÐÂÆµÂÊÃëΪµ¥Î»
DBA_JOBS describes all jobs in the database.
USER_JOBS describes all jobs owned by the c ......

oracleËÀËø²éѯ¼°´¦Àí

²éѯ·¢ÉúËÀËøµÄselectÓï¾ä
select sql_text from v$sql where hash_value in
(select sql_hash_value from v$session where sid in
(select session_id from v$locked_object))
---------------------------------------------------------
¹ØÓÚÊý¾Ý¿âËÀËøµÄ¼ì²é·½·¨
Ò»¡¢        ......

Oracle ÓαêµÄʹÓÃÓë¹ÜÀí

1¡¢²é¿´ORACLE×î´óÓαêÊý
C:\Documents and Settings\Administrator>sqlplus "sys/admin@test151 as sysdba"     £¨sysÒÔdbaµÇ¼test151·þÎñ£©
SQL*Plus: Release 9.2.0.1.0 - Production on ÐÇÆÚËÄ 11ÔÂ 5 09:08:04 2009
Copyright (c) 1982, 2002, Oracle Corporation.  All rights ......

oracle²éѯÁ·Ï°

empÔ±¹¤±í
(empnoÔ±¹¤ºÅ/enameÔ±¹¤ÐÕÃû/job¹¤×÷/mgrÉϼ¶±àºÅ/hiredateÊܹÍÈÕÆÚ/salн½ð/commÓ¶½ð/deptno²¿ÃűàºÅ)
------1.Ñ¡Ôñ²¿ÃÅ30ÖеÄËùÓÐÔ±¹¤.
select ename
from emp
where deptno = 30;
------2.ÁгöËùÓаìÊÂÔ±(CLERK)µÄÐÕÃû£¬±àºÅºÍ²¿ÃűàºÅ.
select ename,empno,deptno
from emp
where job='CLERK';
--- ......

ORACLE 10gÏÂÔØµØÖ·

Oracle Database 10g Release 2 (10.2.0.1.0) Enterprise/Standard Edition for Microsoft Windows (32-bit)
http://download.oracle.com/otn/nt/oracle10g/10201/10201_database_win32.zip
http://download.oracle.com/otn/nt/oracle10g/10201/10201_client_win32.zip
http://download.oracle.com/otn/nt/oracle10g/10 ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØÍ¼ | ¸ÓICP±¸09004571ºÅ