File: use.md

package info (click to toggle)
libpgjava 42.2.5-2%2Bdeb10u1
  • links: PTS, VCS
  • area: main
  • in suites: buster
  • size: 8,136 kB
  • sloc: java: 57,821; xml: 1,135; sh: 307; perl: 99; makefile: 7
file content (34 lines) | stat: -rw-r--r-- 830 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
---
layout: default_docs
title: Chapter 3. Initializing the Driver
header: Chapter 3. Initializing the Driver
resource: media
previoustitle: Creating a Database
previous: your-database.html
nexttitle: Chapter 3. Loading the Driver
next: load.html
---
		
**Table of Contents**


* [Importing JDBC](use.html#import)
* [Loading the Driver](load.html)
* [Connecting to the Databas](connect.html)
   * [Connection Parameters](connect.html#connection-parameters)

This section describes how to load and initialize the JDBC driver in your programs.

<a name="import"></a>
# Importing JDBC

Any source that uses JDBC needs to import the `java.sql` package, using:

```java
import java.sql.*;
```

### Note

You should not import the `org.postgresql` package unless you are not using standard
PostgreSQL™ extensions to the JDBC API.