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

ASP.NET 2.0Á¬½ÓOracle 10g

using System;
using System.Data;
using System.Configuration;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Web.UI.HtmlControls;
using System.Data.OracleClient;//ÒýÈëÃüÃû¿Õ¼ä
public partial class _Default : System.Web.UI.Page 
{
    protected void Page_Load(object sender, EventArgs e)
    {
        String connstr = "Data Source=orcl;User ID=system;Password=orcl;Unicode=True";
        OracleConnection oraConn = new OracleConnection(connstr);
        OracleDataAdapter da = new OracleDataAdapter("select * from lin", oraConn);
        DataSet ds = new DataSet();
        da.Fill(ds);
        GridView1.DataSource = ds.Tables[0];
        GridView1.DataBind();
    }
}
Á¬½ÓÊôÐÔ»òÔÚweb.confgiÖеÄÅäÖÃ
Æäʵֱ½ÓдÉÏÃæµÄ´úÂë»á³ö²»ÉÙ´íÎóµÄ£¬Òª×öÁ½¸ö¹¤×÷²Å¿ÉÒÔ¡£
1. ASP.NET2.0ÀïĬÈϲ»ÄÜÖ±½ÓÌí¼Óusing System.Data.OracleClient;ÐèÒªÔÚÌî¼ÓÒýÓõÄ.NET×é¼þ¿òÀïÑ¡ÔñSystem.Data.OracleClientÌí¼Óºó²ÅÄÜÓá£
2. ÔÚASP.NET1.1Öе÷ÓÃWeb.configÖеÄÊý¾Ý¿âÁ¬½Ó×Ö·û´®Ê±Ê¹ÓÃÓï¾äSystem.Configuration.ConfigurationSettings.AppSettings["oracle"];,ÔÚ2.0ÀïÐëҪʹÓÃSystem.Configuration.ConfigurationManager.AppSettings["oracleconn"];,²¢ÇÒÐèÏÈÔÚÌî¼ÓÒýÓõÄ.NET×é¼þ¿òÀïÑ¡ÔñSystem.ConfigurationÌí¼Óºó²ÅÄÜÓá£
3.ÒÔÉϲÉÓõÄÊÇ´ÓASP.NETǨÒÆÀ´µÄ´úÂë·ç¸ñ£¬Èç¹û²ÉÓÃ2.0ÖеÄconnectionStrings,ÐèÒªÐ޸ĵĴúÂëÈçÏÂ:
Web.Config
<connectionStrings>
    <add name="oracleconn" connectionString="User ID=Óû§Ãû;Password=ÃÜÂë;Data Source=Êý¾Ý¿â·þÎñÃû" providerName="System.Data.OracleClient"/>
</connectionStrings>
´úÂëÈçÏÂÐèÒªÐÞ¸Ä,ÆäËû¶¼²»±ä:
string strcon = Syste


Ïà¹ØÎĵµ£º

ÃüÁîÐÐά»¤Oracle AWR

ÃüÁîÐÐά»¤Oracle AWR
 
 ÓÐʱºòÓÉÓÚÖÖÖÖÔ­Òò£¬Ö»ÄÜʹÓÃÃüÁîÐÐÀ´Î¬»¤Oracle10g¡£µ±È»ÎÒÃÇÒÀÈ»¿ÉÒÔʹÓÃstatspack£¬µ«ÓÉÓÚstatspack¹¦Äܲ»ÈçAWR£¬¶ø
ÇÒÈç¹ûʹÓÃÁ½ÖÖÐÔÄÜÕï¶Ï¹¤¾ßÒ²ÊÇÒ»ÖÖÀË·Ñ¡£Òò´ËÊÖ¶¯Î¬»¤AWR»¹ÊÇÓбØÒªµÄ£¬ÏÂÃæÁгöһЩ³£ÓõÄAWRÃüÁÒÔ±¸ºó²é¡£
   
1¡¢ÐÞ¸ÄAWRµÄ´¥·¢ÆµÂÊ
......

OracleϵÁУº¼Ç¼Record

 OracleϵÁУº¼Ç¼£¨Record£©
Ò»£¬Ê²Ã´ÊǼǼ£¨Record£©£¿
 Óɵ¥ÐжàÁеıêÁ¿¹¹³ÉµÄ¸´ºÏ½á¹¹¡£¿ÉÒÔ¿´×öÊÇÒ»ÖÖÓû§×Ô¶¨ÒåÊý¾ÝÀàÐÍ¡£×é³ÉÀàËÆÓÚ¶àάÊý×é¡£
½«Ò»¸ö»ò¶à¸ö±êÁ¿·â×°³ÉÒ»¸ö¶ÔÏó½øÐвÙ×÷¡£ÊÇÒ»ÖÖÁÙʱ¸´ºÏ¶ÔÏóÀàÐÍ¡£
 
 ¼Ç¼¿ÉÒÔÖ±½Ó¸³Öµ¡£RECORD1 :=RECORD2£»
 ¼Ç¼²»¿ÉÒÔÕûÌå±È½Ï. ......

OracleÍⲿ±íСÀý

1)½¨Á¢²Ù×÷ϵͳĿ¼e:\test£¬×¼±¸Êý¾ÝÎļþdept.txt²¢ÖÃÓÚe:\testÖ®ÏÂ
"10","ACCOUNTING","NEW
YORK"
"20","RESEARCH","DALLAS"
"30","SALES","CHICAGO"
"40","OPERATIONS","BOSTON"
2)´´ ......

ÈçºÎÕýȷɾ³ýORACLE¹éµµÈÕÖ¾Îļþ

 ÎÒÃǶ¼¶¼ÖªµÀÔÚcontrolfileÖмǼ×Åÿһ¸öarchivelogµÄÏà¹ØÐÅÏ¢£¬µ±È»ÃÇÔÚOSÏ°ÑÕâЩÎïÀíÎļþdeleteµôºó£¬ÔÚÎÒÃǵÄ
controlfileÖÐÈÔÈ»¼Ç¼×ÅÕâЩarchivelogµÄÐÅÏ¢£¬ÔÚoracleµÄOEM¹ÜÀíÆ÷ÖÐÓпÉÊÓ»¯µÄÈÕÖ¾Õ¹ÏÖ³ö£¬µ±ÎÒÃÇÊÖ¹¤Çå³ýarchiveĿ¼ÏµÄÎļþºó£¬ÕâЩ¼Ç¼²¢Ã»Óб»ÎÒÃÇ´ÓcontrolfileÖÐÇå³ýµô£¬Ò²¾ÍÊÇoracle²¢²» ......

oracle Ìåϵ½á¹¹

Ç°¼¸ÌìÃæÊÔµÄʱºòÃæÊÔ¹Ù²ÅÎʹýÎÒORACLEµÄÌåϵ½á¹¹£¬ÈÃÎÒÔÚÒ»ÕÅ°×Ö½ÉÏ»­³öÀ´¡£»ØÍ·ÏëÏ뵱ʱ´ðµÃ»¹²»´í£¬´ó²¿·ÖÄÚÈݶ¼ÃèÊö³öÀ´ÁË£¬ºÇºÇ£¬¸Õ²ÅÔÚÍøÉÏ¿´µ½Ò»Æª½²½âORACLEÌåϵ½á¹¹µÄÎÄÕ£¬¾õµÃ²»´í£¬×ª¹ýÀ´´æ×Å£¬½«À´¿ÉÄÜ»áÓõ½¡£
=================================================================================
ÔÚ±¾ÎÄÀ ......
© 2009 ej38.com All Rights Reserved. ¹ØÓÚE½¡ÍøÁªÏµÎÒÃÇ | Õ¾µãµØͼ | ¸ÓICP±¸09004571ºÅ