Skip to content

Commit

Permalink
Adding SAP ASE (TDS) driver
Browse files Browse the repository at this point in the history
  • Loading branch information
Kenneth Shaw committed Jan 21, 2019
1 parent 52f01da commit eefdc78
Show file tree
Hide file tree
Showing 5 changed files with 87 additions and 24 deletions.
22 changes: 22 additions & 0 deletions drivers/sapase/sapase.go
Original file line number Diff line number Diff line change
@@ -0,0 +1,22 @@
package sapase

import (
// DRIVER: tds
_ "github.com/thda/tds"

"github.com/xo/usql/drivers"
)

func init() {
drivers.Register("tds", drivers.Driver{
AllowMultilineComments: true,
Version: func(db drivers.DB) (string, error) {
var ver string
err := db.QueryRow(`SELECT @@version`).Scan(&ver)
if err != nil {
return "", err
}
return "SAP ASE " + ver, nil
},
})
}
16 changes: 8 additions & 8 deletions go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ module github.com/xo/usql
require (
cloud.google.com/go v0.34.0 // indirect
github.com/MichaelS11/go-cql-driver v0.0.0-20181029231409-81aad8db3731
github.com/SAP/go-hdb v0.13.1
github.com/SAP/go-hdb v0.13.2
github.com/SermoDigital/jose v0.9.2-0.20180104203859-803625baeddc // indirect
github.com/VoltDB/voltdb-client-go v1.0.1
github.com/alecthomas/chroma v0.6.2
Expand All @@ -19,7 +19,7 @@ require (
github.com/chzyer/logex v1.1.10 // indirect
github.com/chzyer/test v0.0.0-20180213035817-a1ea475d72b1 // indirect
github.com/cockroachdb/apd v1.1.0 // indirect
github.com/couchbase/go-couchbase v0.0.0-20181210201043-bd8e99474993 // indirect
github.com/couchbase/go-couchbase v0.0.0-20190117181324-d904413d884d // indirect
github.com/couchbase/go_n1ql v0.0.0-20160215142504-6cf4e348b127
github.com/couchbase/gomemcached v0.0.0-20181122193126-5125a94a666c // indirect
github.com/couchbase/goutils v0.0.0-20180530154633-e865a1461c8a // indirect
Expand All @@ -32,14 +32,15 @@ require (
github.com/cznic/sortutil v0.0.0-20181122101858-f5f958428db8 // indirect
github.com/cznic/strutil v0.0.0-20181122101858-275e90344537 // indirect
github.com/cznic/zappy v0.0.0-20181122101859-ca47d358d4b1 // indirect
github.com/denisenkom/go-mssqldb v0.0.0-20181014144952-4e0d7dc8888f
github.com/denisenkom/go-mssqldb v0.0.0-20190121005146-b04fd42d9952
github.com/edsrzf/mmap-go v1.0.0 // indirect
github.com/go-ole/go-ole v1.2.2 // indirect
github.com/go-sql-driver/mysql v1.4.1
github.com/gocql/gocql v0.0.0-20181124151448-70385f88b28b
github.com/gohxs/readline v0.0.0-20171011095936-a780388e6e7c
github.com/golang/glog v0.0.0-20160126235308-23def4e6c14b // indirect
github.com/google/go-cmp v0.2.0 // indirect
github.com/hashicorp/go-uuid v1.0.1 // indirect
github.com/jackc/fake v0.0.0-20150926172116-812a484cc733 // indirect
github.com/jackc/pgx v3.3.0+incompatible
github.com/kardianos/osext v0.0.0-20170510131534-ae77be60afb1 // indirect
Expand All @@ -48,29 +49,28 @@ require (
github.com/lib/pq v1.0.0
github.com/mattn/go-adodb v0.0.0-20181006063745-71e75ebd1d86
github.com/mattn/go-isatty v0.0.4
github.com/mattn/go-runewidth v0.0.4 // indirect
github.com/mattn/go-sqlite3 v1.10.0
github.com/nakagami/firebirdsql v0.0.0-20190105130315-4b22b1b6ef76
github.com/pkg/browser v0.0.0-20180916011732-0a3d74bf9ce4 // indirect
github.com/pkg/errors v0.8.1 // indirect
github.com/prestodb/presto-go-client v0.0.0-20190102230415-2f3fb1d8d146
github.com/prestodb/presto-go-client v0.0.0-20190119074633-edfd3c996aa1
github.com/remyoudompheng/bigfft v0.0.0-20170806203942-52369c62f446 // indirect
github.com/satori/go.uuid v1.2.0 // indirect
github.com/shopspring/decimal v0.0.0-20180709203117-cd690d0c9e24 // indirect
github.com/snowflakedb/gosnowflake v1.1.15
github.com/spaolacci/murmur3 v0.0.0-20180118202830-f09979ecbc72 // indirect
github.com/stretchr/testify v1.3.0 // indirect
github.com/xo/dburl v0.0.0-20181118001949-f3ca07bd6afc
github.com/thda/tds v0.1.1
github.com/xo/dburl v0.0.0-20190121004108-4a9410ecb80c
github.com/xo/tblfmt v0.0.0-20181118003015-0b109994b29d
github.com/xo/terminfo v0.0.0-20181215143347-9ba9fdd85c0d
github.com/xo/xoutil v0.0.0-20171112033149-46189f4026a5
github.com/zaf/temp v0.0.0-20170209143821-94e385923345
github.com/ziutek/mymysql v1.5.4
gitlab.com/nyarla/go-crypt v0.0.0-20160106005555-d9a5dc2b789b // indirect
golang.org/x/crypto v0.0.0-20190103213133-ff983b9c42bc // indirect
golang.org/x/net v0.0.0-20190108225652-1e06a53dbb7e // indirect
golang.org/x/sync v0.0.0-20181221193216-37e7f081c4d4 // indirect
golang.org/x/sys v0.0.0-20190109145017-48ac38b7c8cb // indirect
golang.org/x/sys v0.0.0-20190116161447-11f53e031339 // indirect
google.golang.org/appengine v1.4.0 // indirect
gopkg.in/check.v1 v1.0.0-20180628173108-788fd7840127 // indirect
gopkg.in/jcmturner/gokrb5.v6 v6.1.1 // indirect
Expand Down
Loading

0 comments on commit eefdc78

Please sign in to comment.