49 lines
977 B
JavaScript
49 lines
977 B
JavaScript
import { extractRowsFromSQLValues } from "./utils.js"
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues("(1,'-)',0),(2,'Demographics_of_American_Samoa',0)"),
|
||
)
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues(
|
||
`(1,'-d\\'ff)',0),(2,'Demographics_of_American_Samoa',0)`,
|
||
),
|
||
)
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues(
|
||
"(1,'-)',0),(2,'Demographics_of_American_Samoa',0),(11,'abc',ddf,123,43,'dff'",
|
||
),
|
||
)
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues(
|
||
"(1,'-)',0),(2,'Demographics_of_American_Samoa',0),(11",
|
||
),
|
||
)
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues(
|
||
"(1,'-)',0),(2,'Demographics_of_American_Samoa',0),(",
|
||
),
|
||
)
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues(
|
||
`(1,'-)',0),(2,'C:\\\\',1,0),(2,'Demographics_of_American_Samoa',0)`,
|
||
),
|
||
)
|
||
|
||
console.log(
|
||
"output:",
|
||
extractRowsFromSQLValues(
|
||
`(1,'-)',0),(2,'Good_Singin\\',_Good_Playin\\'',1,0),(2,'Demographics_of_American_Samoa',0)`,
|
||
),
|
||
)
|