Here is a list of client libraries and code examples to connect to a TimescaleDB instance.
Language | Client | Download |
---|---|---|
Go | pq | https://github.com/lib/pq |
Java | JDBC Driver | https://jdbc.postgresql.org/ |
Node.js | pg package | https://www.npmjs.com/package/pg |
Python | psycopg2 | https://pypi.org/project/psycopg2/ |
Include Maven dependency for PostgreSQL JDBC Driver
<dependency>
<groupId>org.postgresql</groupId>
<artifactId>postgresql</artifactId>
<version>42.2.0</version>
</dependency>
Java sample code here.
Install node-postgres pg package:
npm install pg
Run the sample:
node tsdb-node-client.js
Install Python PostgreSQL Database Adapter psycopg package:
pip install psycopg2
Run the sample:
python tsdb-python-client.py