Skip to content

Commit a8eaa32

Browse files
authored
Merge pull request #7 from alexandear/readme-typos
Fix typos in README
2 parents a09ebf5 + 61b1cad commit a8eaa32

File tree

1 file changed

+5
-5
lines changed

1 file changed

+5
-5
lines changed

README.md

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -125,7 +125,7 @@ for {
125125
}
126126
fmt.Println("name:", name, "age:", age)
127127
}
128-
// Remember to Reset the statement if you would like to Bind new arguments and reuse the prepared staement
128+
// Remember to Reset the statement if you would like to Bind new arguments and reuse the prepared statement
129129
```
130130

131131
### Using Transactions
@@ -176,19 +176,19 @@ func insertStudents(conn *sqlite3.Conn) error {
176176
* RawString and RawBytes can be used to reduce copying between Go and SQLite. Please use with caution.
177177

178178
## Credit
179-
This project begain as a fork of https://github.com/mxk/go-sqlite/
179+
This project began as a fork of https://github.com/mxk/go-sqlite/
180180

181181
## FAQ
182182

183183
* **Why is there no `database/sql` interface?**
184184

185185
If a `database/sql` interface is required, please use https://github.com/mattn/go-sqlite3 . In my experience, using a `database/sql` interface with SQLite is painful. Connection pooling causes unnecessary overhead and weirdness. Transactions using `Exec("BEGIN")` don't work as expected. Your connection does not correspond to SQLite's concept of a connection. PRAGMA commands do not work as expected. When you hit SQLite errors, such as locking or busy errors, it's difficult to discover why since you don't know which connection received which SQL and in what order.
186186

187-
* **What are the differences betwen this driver and the mxk/go-sqlite driver?**
187+
* **What are the differences between this driver and the mxk/go-sqlite driver?**
188188

189189
This driver was forked from `mxk/go-sqlite-driver`. It hadn't been maintained in years and used an ancient version of SQLite. A large number of features were removed, reworked, and renamed. A lot of smartness and state was removed. It is now much easier to upgrade to newer versions of SQLite since the `codec` feature was removed. The behavior of methods now lines up closely with the behavior of SQLite's C API.
190190

191-
* **What are the differences betwen this driver and the crawshaw/sqlite driver?**
191+
* **What are the differences between this driver and the crawshaw/sqlite driver?**
192192

193193
The crawshaw driver is pretty well thought out and solves a lot of the same problems as this
194194
driver. There are a few places where our philosophies differ. The crawshaw driver defaults (when flags of 0 are given) to SQLite shared cache mode and WAL mode. The default WAL synchronous mode is changed. Prepared statements are transparently cached. Connection pools are provided. I would be opposed to making most of these changes to this driver. I would like this driver to provide a default, light, and unsurprising SQLite experience.
@@ -199,7 +199,7 @@ No finalizers are used in this driver. You are responsible for closing connecti
199199

200200
* **Is it thread safe?**
201201

202-
go-sqlite-lite is as thread safe as SQLite. SQLite with this driver is compiled with `-DSQLITE_THREADSAFE=2` which is **Multi-thread** mode. In this mode, SQLite can be safely used by multiple threads provided that no single database connection is used simultaneously in two or more threads. This applies to goroutines. A single database conneciton should not be used simultaneously between two goroutines.
202+
go-sqlite-lite is as thread safe as SQLite. SQLite with this driver is compiled with `-DSQLITE_THREADSAFE=2` which is **Multi-thread** mode. In this mode, SQLite can be safely used by multiple threads provided that no single database connection is used simultaneously in two or more threads. This applies to goroutines. A single database connection should not be used simultaneously between two goroutines.
203203

204204
It is safe to use separate connection instances concurrently, even if they are accessing the same database file. For example:
205205
```go

0 commit comments

Comments
 (0)