Skip to content

Commit 25d7308

Browse files
committed
fix
1 parent 89de5cd commit 25d7308

File tree

3 files changed

+3
-3
lines changed

3 files changed

+3
-3
lines changed

bun.lockb

0 Bytes
Binary file not shown.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@sqlitecloud/drivers",
3-
"version": "1.0.339",
3+
"version": "1.0.340",
44
"description": "SQLiteCloud drivers for Typescript/Javascript in edge, web and node clients",
55
"main": "./lib/index.js",
66
"types": "./lib/index.d.ts",

test/1brc.test.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,7 +173,7 @@ async function testChallenge(numberOfRows: number, insertChunks = BRC_INSERT_CHU
173173

174174
if (dataChunk.length === insertChunks || rowCount + 1 === numberOfRows) {
175175
const insertOn = Date.now()
176-
const values = dataChunk.map(({ city, temp }) => `('${city.replaceAll("'", "''")}', ${temp})`).join(',\n')
176+
const values = dataChunk.map(({ city, temp }) => `('${city.replace(/'/g, "''")}', ${temp})`).join(',\n')
177177
const insertSql = `INSERT INTO measurements (city, temp) VALUES \n${values};`
178178

179179
// insert values into database
@@ -203,7 +203,7 @@ async function testChallenge(numberOfRows: number, insertChunks = BRC_INSERT_CHU
203203
fs.writeFileSync(selectCsvPathname, selectCsv)
204204
} catch (error) {
205205
console.error(`Error: ${error}`)
206-
if (numberOfRows < 500000 ) {
206+
if (numberOfRows < 500000) {
207207
throw error
208208
}
209209
} finally {

0 commit comments

Comments
 (0)