Skip to content

Commit

Permalink
docs: update README
Browse files Browse the repository at this point in the history
  • Loading branch information
lzdyes committed May 8, 2022
1 parent 56f4f8a commit 088227c
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,10 +68,11 @@ await db.execute('INSERT INTO users VALUES (?1, ?2)', [
/** select count */
const rows = await db.select<Array<{ count: number }>>('SELECT COUNT(*) as count FROM users')

/** select with params */
/** select with param */
const rows = await db.select<Array<{ name: string }>>('SELECT name FROM users WHERE age > ?', [20])

const rows = await db.select<Array<any>>('SELECT * FROM users LIMIT ?1 OFFSET ?2', [10, 0])
/** select with params */
const rows = await db.select<Array<{ name: string, age: number }>>('SELECT * FROM users LIMIT ?1 OFFSET ?2', [10, 0])
```

## License
Expand Down

0 comments on commit 088227c

Please sign in to comment.