dialect

package
v0.6.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Apr 28, 2019 License: MIT Imports: 4 Imported by: 0

README

dialect GoDoc

The dialect package handles differences in SQL dialects.

There is no backward compatibility guarantee for this package.

Documentation

Overview

Package dialect handles differences in various SQL dialects.

Index

Constants

This section is empty.

Variables

View Source
var (
	ANSI     *Dialect
	MSSQL    *Dialect
	MySQL    *Dialect
	Postgres *PostgresDialect
	SQLite   *Dialect
)

Pre-defined dialects

Functions

This section is empty.

Types

type Dialect

type Dialect struct {
	// contains filtered or unexported fields
}

Dialect provides information about an SQL dialect.

func (*Dialect) Match

func (d *Dialect) Match(drv driver.Driver) bool

Match returns true if the dialect is appropriate for the driver.

func (*Dialect) Placeholder

func (d *Dialect) Placeholder(n int) string

Placeholder returns the string for a placeholder.

func (*Dialect) Quote

func (d *Dialect) Quote(name string) string

Quote quotes a column name.

type PostgresDialect added in v0.6.0

type PostgresDialect struct {
	Dialect
}

PostgresDialect is a dialect for PostgreSQL.

func (*PostgresDialect) Postgres added in v0.6.0

func (d *PostgresDialect) Postgres()

Postgres is a marker method that indicates the dialect is for PostgreSQL.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL