JAVAÁ¬½ÓACCESS£¬SQL Server,MySQL,Oracle
import java.sql.*;
/*
* JAVAÁ¬½ÓACCESS£¬SQL Server,MySQL,OracleÊý¾Ý¿â
*
* */
public class JDBC {
public static void main(String[] args)throws Exception {
Connection conn=null;
//====Á¬½ÓACCESSÊý¾Ý¿â====
//Á¬½ÓACCESS(·ÇODBCÁ¬½Óģʽ)
//String dbURL ="jdbc:odbc:Driver={MicroSoft Access Driver (*.mdb)};DBQ=f:/db1.mdb";
//Á¬½ÓACCESS(ODBC -ϵͳDSNÁ¬½Óģʽ)
//String dbURL="jdbc:odbc:odbcName";
//conn = DriverManager.getConnection(dbURL);//´´½¨Á¬½Ó¶ÔÏó
//System.out.println("ACCESSÊý¾Ý¿âÁ¬½Ó³É¹¦£¡");
//====Á¬½ÓSQLÊý¾Ý¿â====
/*
* String dbURL="jdbc:microsoft:sqlserver://localhost:Êý¾Ý¿â¶Ë¿Ú;DatabaseName=Êý¾Ý¿âÃû";
*
* */
//String dbURL="jdbc:microsoft:sqlserver://localhost:7788;DatabaseName=msdb";
//String userName = "sa";
//String userPwd = "admin";
//Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver");//¼ÓÔØÇý¶¯
//conn = DriverManager.getConnection(dbURL,userName,userPwd);//´´½¨Á¬½Ó¶ÔÏó
//System.out.println("SQLÊý¾Ý¿âÁ¬½Ó³É¹¦£¡");
//====Á¬½ÓMySQlÊý¾Ý¿â====
/*
* "jdbc:mysql://localhost/Êý¾Ý¿âÃû×Ö?user=Óû§Ãû&password=ÃÜÂë&useUnicode=true&characterEncoding=gb2312";
*
* */
//String dbURL="jdbc:mysql://localhost/hackwang?user=root&password=hackwang&useUnicode=true&characterEncoding=gb2312";
//Class.forName("org.gjt.mm.mysql.Driver");//¼ÓÔØÇý¶¯
//conn = DriverManager.getConnection(dbURL);//´´½¨Á¬½Ó¶ÔÏó
//System.out.printl
Ïà¹ØÎĵµ£º
ÊìϤSQL SERVER 2000µÄÊý¾Ý¿â¹ÜÀíÔ±¶¼ÖªµÀ£¬ÆäDTS¿ÉÒÔ½øÐÐÊý¾ÝµÄµ¼Èëµ¼³ö£¬Æäʵ£¬ÎÒÃÇÒ²¿ÉÒÔʹÓÃTransact-SQLÓï¾ä½øÐе¼Èëµ¼³ö²Ù×÷¡£ÔÚTransact-SQLÓï¾äÖУ¬ÎÒÃÇÖ÷ҪʹÓÃOpenDataSourceº¯Êý¡¢OPENROWSET º¯Êý£¬¹ØÓÚº¯ÊýµÄÏêϸ˵Ã÷£¬Çë²Î¿¼SQLÁª»ú°ïÖú¡£ÀûÓÃÏÂÊö·½·¨£¬¿ÉÒÔÊ®·ÖÈÝÒ×µØʵÏÖSQL SERVER¡¢ACCESS¡¢EXCELÊý¾Ýת»»£ ......
ýÌå½ÓÈë¿ØÖƲãµÄËõд
ʲôÊÇmac!!!
Èç¹ûÄãÊÇͨ¹ýУ԰Íø»òСÇø½ÓÈëInternet£¬ÄÇôһ¶¨Ìý˵¹ýMACµØÖ·¡£Ê²Ã´ÊÇMACµØÖ·£¬MACµØÖ·ÔÚÕâÖÖ¾ÖÓòÍø»·¾³Öо¿¾¹Æðµ½Ê²Ã´×÷Óã¿ÏÂÃæ¾ÍÀ´½éÉÜÒ»ÏÂMACµØÖ·µÄ֪ʶ£¬MACµØÖ·ºÍIPµØÖ·µÄÇø±ðÒÔ¼°MACµØÖ·ÔÚʵ¼ÊÓ¦ÓÃÖÐËùÉæ¼°µ½µÄ°²È«ÎÊÌâ¡£
¡¡¡¡Ò»¡¢»ù´¡ÖªÊ¶
¡¡¡¡Èç½ñµÄÍøÂçÊÇ·Ö²ãÀ´Êµ ......
ÈçºÎÔÚ Access ÖвåÈëÒ»ÌõеļǼʱ,Ô¤ÏÈÖªµÀËûµÄ×Ô¶¯±àºÅIDÄØ?
Õâ¸öÎÊÌâÀ§ÈÅÁËÎҺܾÃ
ºóÀ´ÎÒÏëÁËÒ»¸öºÜ±¿°ì·¨
¾ÍÊÇÏȲåÈëÒ»Ìõ ËæÒâµÄÊý¾Ý µ±È»ÀïÃæÓÐÓÐÒ»¸öÄãʵÏÖÔ¤¶¨ºÃµÄ±êʶ
±ÈÈç
insert into cmd (classID,cmdType,cmd) values('temp','temp','temp')
È»ºóÕÒµ½Ëü ¶ÁÈ¡ËüµÄID
select * from cmd where classID ......
Èí¼þÃû³Æ: EA2A(Excel/Access to Access)
Èí¼þ°æ±¾: beta2
ÊÚȨÐÎʽ: Ãâ·ÑÈí¼þ
ÔËÐÐƽ̨: Win9x/Me/NT/2000/XP/2003
Êý¾Ý¿âÉý¼¶ºóÔÓбíÖÐ×ֶλáÔö¼Ó£¬´ËʱÎÒÃǾÍÐèÒªµ¼È루ǨÒÆ£©Êý¾Ý£¬´Ë³ÌÐòΪʵÏִ˹¦Äܶø±àд¡£
ͨ³£Èí¼þÉý¼¶ºó£¬Êý¾Ý¿âÒ²»áÓÐËù¸Ä±ä£¬´Ëʱ¾ÍÐèÒª¶Ô¿Í»§Ê¹ÓõÄÊý¾Ý¿â½øÐÐÉý¼¶¡£Éý¼¶¿Í»§Êý¾Ý¿âµÄ·½Ê½Ó ......