Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Appearance settings

Commit beadcf1

Browse filesBrowse files
avivkelleraduh95
authored andcommitted
doc: createSQLTagStore -> createTagStore
PR-URL: #60182 Refs: https://discord.com/channels/425824580918181889/425824580918181891/1425966053242048584 Reviewed-By: Colin Ihrig <cjihrig@gmail.com> Reviewed-By: Luigi Pinca <luigipinca@gmail.com>
1 parent a56aa9f commit beadcf1
Copy full SHA for beadcf1

File tree

Expand file treeCollapse file tree

1 file changed

+4
-4
lines changed
Open diff view settings
Filter options
Expand file treeCollapse file tree

1 file changed

+4
-4
lines changed
Open diff view settings
Collapse file

‎doc/api/sqlite.md‎

Copy file name to clipboardExpand all lines: doc/api/sqlite.md
+4-4Lines changed: 4 additions & 4 deletions
  • Display the source diff
  • Display the rich diff
Original file line numberDiff line numberDiff line change
@@ -426,7 +426,7 @@ added: v22.5.0
426426
Compiles a SQL statement into a [prepared statement][]. This method is a wrapper
427427
around [`sqlite3_prepare_v2()`][].
428428

429-
### `database.createSQLTagStore([maxSize])`
429+
### `database.createTagStore([maxSize])`
430430

431431
<!-- YAML
432432
added: v24.9.0
@@ -450,7 +450,7 @@ avoid the overhead of repeatedly parsing and preparing the same SQL statements.
450450
import { DatabaseSync } from 'node:sqlite';
451451

452452
const db = new DatabaseSync(':memory:');
453-
const sql = db.createSQLTagStore();
453+
const sql = db.createTagStore();
454454

455455
db.exec('CREATE TABLE users (id INT, name TEXT)');
456456

@@ -625,14 +625,14 @@ added: v24.9.0
625625
This class represents a single LRU (Least Recently Used) cache for storing
626626
prepared statements.
627627

628-
Instances of this class are created via the database.createSQLTagStore() method,
628+
Instances of this class are created via the database.createTagStore() method,
629629
not by using a constructor. The store caches prepared statements based on the
630630
provided SQL query string. When the same query is seen again, the store
631631
retrieves the cached statement and safely applies the new values through
632632
parameter binding, thereby preventing attacks like SQL injection.
633633

634634
The cache has a maxSize that defaults to 1000 statements, but a custom size can
635-
be provided (e.g., database.createSQLTagStore(100)). All APIs exposed by this
635+
be provided (e.g., database.createTagStore(100)). All APIs exposed by this
636636
class execute synchronously.
637637

638638
### `sqlTagStore.all(sqlTemplate[, ...values])`

0 commit comments

Comments
0 (0)
Morty Proxy This is a proxified and sanitized view of the page, visit original site.