Skip to content
This repository has been archived by the owner on Jun 21, 2019. It is now read-only.

go-xorm/tidb

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

18 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

tidb driver and dialect for github.com/go-xorm/xorm

Currently, we can support tidb for allmost all the operations.

How to use

Just like other supports of xorm, but you should import the three packages:

import (
    _ "github.com/pingcap/tidb"
    _ "github.com/go-xorm/tidb"
    "github.com/go-xorm/xorm"
)

//The formate of DataSource name is store://uri/dbname
// for goleveldb as store
xorm.NewEngine("tidb", "goleveldb://./tidb/tidb")
// for memory as store
xorm.NewEngine("tidb", "memory://tidb/tidb")
// for boltdb as store
xorm.NewEngine("tidb", "boltdb://./tidb/tidb")

About

Xorm dialect for github.com/pingcap/tidb

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages