Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/sail-sail/mysql2
MySQL client for Deno with focus on performance. Supports prepared statements, non-utf8 encodings, binary log protocol, compression much more
https://github.com/sail-sail/mysql2
Last synced: 21 days ago
JSON representation
MySQL client for Deno with focus on performance. Supports prepared statements, non-utf8 encodings, binary log protocol, compression much more
- Host: GitHub
- URL: https://github.com/sail-sail/mysql2
- Owner: sail-sail
- License: mit
- Created: 2022-05-16T09:51:04.000Z (over 2 years ago)
- Default Branch: main
- Last Pushed: 2022-07-05T12:57:30.000Z (over 2 years ago)
- Last Synced: 2024-10-11T00:36:34.753Z (about 1 month ago)
- Language: TypeScript
- Size: 144 KB
- Stars: 7
- Watchers: 3
- Forks: 2
- Open Issues: 5
-
Metadata Files:
- Readme: README.md
- License: License
Awesome Lists containing this project
README
# mysql2
MySQL client for Deno with focus on performance. Supports prepared statements, non-utf8 encodings, binary log protocol, compression much more
fock by https://github.com/sidorares/node-mysql2
## usage
```ts
import * as mysql2 from "https://deno.land/x/mysql2/mod.ts";const pool = mysql2.createPool({
host: "127.0.0.1",
port: 3306,
user: "test_user",
password: "test_password",
database: "nest_database",
connectionLimit: 4,
});
const result = await pool.query("SELECT 1");
console.log(result[0]); // [ { "1": 1 } ]
await pool.end();
```