]>
Commit | Line | Data |
---|---|---|
48b031fa | 1 | go-sqlite3 |
2 | ========== | |
3 | ||
16484897 | 4 | [![Build Status](https://travis-ci.org/mattn/go-sqlite3.png?branch=master)](https://travis-ci.org/mattn/go-sqlite3) |
1450ef9d | 5 | [![Coverage Status](https://coveralls.io/repos/mattn/go-sqlite3/badge.png?branch=master)](https://coveralls.io/r/mattn/go-sqlite3?branch=master) |
16484897 | 6 | |
e8799fe7 | 7 | Description |
48b031fa | 8 | ----------- |
9 | ||
28bd73b5 | 10 | sqlite3 driver conforming to the built-in database/sql interface |
48b031fa | 11 | |
e8799fe7 | 12 | Installation |
bba20942 | 13 | ------------ |
14 | ||
73ea0ad0 | 15 | This package can be installed with the go get command: |
28bd73b5 | 16 | |
17 | go get github.com/mattn/go-sqlite3 | |
e8799fe7 | 18 | |
90af0d57 DG |
19 | _go-sqlite3_ is *cgo* package. |
20 | If you want to build your app using go-sqlite3, you need gcc. | |
0ad9f0ce | 21 | However, if you install _go-sqlite3_ with `go install github.com/mattn/go-sqlite3`, you don't need gcc to build your app anymore. |
90af0d57 | 22 | |
e8799fe7 P |
23 | Documentation |
24 | ------------- | |
25 | ||
26 | API documentation can be found here: http://godoc.org/github.com/mattn/go-sqlite3 | |
27 | ||
28 | Examples can be found under the `./_example` directory | |
08b7452f | 29 | |
716b2f56 | 30 | FAQ |
31 | --- | |
32 | ||
b4142c44 YM |
33 | * Want to build go-sqlite3 with libsqlite3 on my linux. |
34 | ||
35 | Use `go build --tags "libsqlite3 linux"` | |
36 | ||
715f5e5d PZ |
37 | * Want to build go-sqlite3 with icu extension. |
38 | ||
39 | Use `go build --tags "icu"` | |
40 | ||
919cf414 | 41 | * Can't build go-sqlite3 on windows 64bit. |
716b2f56 | 42 | |
82c791ba | 43 | > Probably, you are using go 1.0, go1.0 has a problem when it comes to compiling/linking on windows 64bit. |
919cf414 | 44 | > See: https://github.com/mattn/go-sqlite3/issues/27 |
716b2f56 | 45 | |
919cf414 | 46 | * Getting insert error while query is opened. |
716b2f56 | 47 | |
82c791ba | 48 | > You can pass some arguments into the connection string, for example, a URI. |
919cf414 | 49 | > See: https://github.com/mattn/go-sqlite3/issues/39 |
716b2f56 | 50 | |
764faa85 | 51 | * Do you want cross compiling? mingw on Linux or Mac? |
52 | ||
53 | > See: https://github.com/mattn/go-sqlite3/issues/106 | |
d9881e4d | 54 | > See also: http://www.limitlessfx.com/cross-compile-golang-app-for-windows-from-linux.html |
764faa85 | 55 | |
1b2a5560 | 56 | * Want to get time.Time with current locale |
57 | ||
58 | Use `loc=auto` in SQLite3 filename schema like `file:foo.db?loc=auto`. | |
59 | ||
e8799fe7 | 60 | License |
48b031fa | 61 | ------- |
62 | ||
bba20942 | 63 | MIT: http://mattn.mit-license.org/2012 |
060db06a | 64 | |
3d6c6f93 SG |
65 | sqlite3-binding.c, sqlite3-binding.h, sqlite3ext.h |
66 | ||
67 | The -binding suffix was added to avoid build failures under gccgo. | |
060db06a | 68 | |
69 | In this repository, those files are amalgamation code that copied from SQLite3. The license of those codes are depend on the license of SQLite3. | |
70 | ||
71 | Author | |
72 | ------ | |
73 | ||
74 | Yasuhiro Matsumoto (a.k.a mattn) |