JDBC for SQL Server - Herong's Tutorial Examples - v3.14, by Herong Yang
Compile and Run Java Programs
This section describes how to compile and run Java programs.
When JDK is installed on your machine, it provides two commands for you to compile and run Java programs.
Let's try these commands with a very simple Java program. Use NotePad to enter the following Java program into a file called Hello.java:
class Hello { public static void main(String[] a) { System.out.println("Hello world!"); } }
Then compile this program in a command window with the "javac" command:
herong> javac Hello.java
To execute the program, use the java command:
herong> java Hello Hello world!
Congratulations, you have successfully entered, compiled and executed your first Java program.
Table of Contents
JDBC (Java Database Connectivity) Introduction
Downloading and Installing JDK
Adding JDK "bin" Directory to Path Setting
Downloading and Installing JDK on Mac
Downloading and Installing JDK on Linux
►Compile and Run Java Programs
-cp or -classpath Syntax on Different Systems
JDK Documentation Installation
Microsoft SQL Server Express Edition
Microsoft JDBC Driver for SQL Server
Microsoft JDBC Driver - Query Statements and Result Sets
Microsoft JDBC Driver - DatabaseMetaData Object
Microsoft JDBC Driver - DDL Statements
Microsoft JDBC Driver - DML Statements
SQL Server - PreparedStatement
SQL Server CLOB (Character Large Object) - TEXT
SQL Server BLOB (Binary Large Object) - BLOB
Using Connection Pool with JDBC
JDBC-ODBC Bridge Driver - sun.jdbc.odbc.JdbcOdbcDriver
JDBC-ODBC Bridge Driver - Flat Text Files
JDBC-ODBC Bridge Driver - MS Access