컴퓨터/JAVA
-
Oracle BLOB컴퓨터/JAVA 2006. 7. 5. 13:21
Oracle에 접속해서 BLOB 타입의 데이터를 가져와 파일로 저장한다.package database;import java.io.*; import java.sql.*;import oracle.sql.*; /** * Database:Oracle * IP: 127.0.0.1:1521 * SID: o10g * USER: scott * PASS: tiger * @author hikasiru * */ public class OracleTest { public static void main(String[] args) throws SQLException, ClassNotFoundException, IOException { Connection con; Statement stmt = null; ResultSet rst ..
-
The Finalize Method컴퓨터/JAVA 2006. 6. 15. 11:08
객체가 서비스로부터 제거 되었을 때 작동할 행동을 정의 하자. (번역 하니까 이상하군...) 예제. public class ShutdownDemo { public static void main(String[] args) throws Exception { // Create an Object with a finalize() method. Object f = new Object() { public void finalize() { System.out.println("Running finalize()"); } }; // Add a shutdownHook to the JVM Runtime.getRuntime().addShutdownHook(new Thread() { public void run() { System...
-
Cannot Start a Cloned Connection While in Manual Transaction Mode컴퓨터/JAVA 2006. 5. 4. 14:07
link:http://support.microsoft.com/default.aspx?scid=kb%3Ben-us%3B313181 SYMPTOMSWhile using the Microsoft SQL Server 2000 Driver for JDBC, you may experience the following exception: java.sql.SQLException: [Microsoft][SQLServer 2000 Driver for JDBC]Can't start a cloned connection while in manual transaction mode. CAUSEThis error occurs when you try to execute multiple statements against a SQL Se..
-
HOW TO: Get Started with microsoft JDBC컴퓨터/JAVA 2006. 5. 4. 09:30
link: http://support.microsoft.com/default.aspx?scid=kb;en-us;313100 link: http://support.microsoft.com/default.aspx?scid=kb%3Bko%3B313100 Set your system CLASSPATH variable to include the following entries: • \Your installation path\Lib\Msbase.jar • \Your installation path\Lib\Msutil.jar • \Your installation path\Lib\Mssqlserver.jar To Pass the Connection URL con = DriverManager.getConnection("..
-
[Java]chatting server & client.컴퓨터/JAVA 2006. 3. 24. 23:55
원문: http://www.javaworld.com/javaworld/jw-01-1997/jw-01-chat_p.html 한글문서: http://www.javastudy.co.kr/docs/jm/jm8.html ChatServer.java import java.net.*; import java.io.*; import java.util.*; public class ChatServer { public ChatServer (int port) throws IOException { ServerSocket server = new ServerSocket (port); while (true) { Socket client = server.accept (); System.out.println ("Accepted from ..