Type Alias sea_orm::DbBackend

source ·
pub type DbBackend = DatabaseBackend;
Expand description

The same as DatabaseBackend just shorter :)

Aliased Type§

enum DbBackend {
    MySql,
    Postgres,
    Sqlite,
}

Variants§

§

MySql

A MySQL backend

§

Postgres

A PostgreSQL backend

§

Sqlite

A SQLite backend

Implementations§

source§

impl DbBackend

source

pub fn is_prefix_of(self, base_url: &str) -> bool

Check if the URI is the same as the specified database backend. Returns true if they match.

§Panics

Panics if base_url cannot be parsed as Url.

source

pub fn build<S>(&self, statement: &S) -> Statement

Build an SQL Statement

source

pub fn get_query_builder(&self) -> Box<dyn QueryBuilder>

A helper for building SQL queries

source

pub fn support_returning(&self) -> bool

Check if the database supports RETURNING syntax on insert and update