denoDB

denoDB

  • Docs
  • GitHub
  • Help

›Clients

Guides

  • Getting started
  • Connect to a database
  • Clients

    • Using MariaDB
    • Using MongoDB
    • Using MySQL
    • Using PostgreSQL
    • Using SQLite
  • Create models
  • Synchronize database
  • Query models
  • Transactions
  • Relationships

    • Foreign key
    • One-to-one
    • One-to-many
    • Many-to-many
  • Model events

API Reference

    Models

    • Data types
    • Field descriptors
    • Model methods
    • Model records

Using MariaDB

DenoDB is using deno_mysql for MariaDB support. This means the connector we'll use is the same as with MySQL.

import { Database, MySQLConnector } from 'https://deno.land/x/denodb/mod.ts';

const connector = new MySQLConnector({
  database: 'my-database',
  host: 'url-to-db.com',
  username: 'username',
  password: 'password',
  port: 3306, // optional
});

const db = new Database(connector);
Last updated on 1/2/2021 by eveningkid
← Connect to a databaseUsing MongoDB →
Docs
Getting StartedAPI Reference
More
GitHubStar