Add a table to hold only the Symbols
to improve performance.
This commit is contained in:
@@ -31,7 +31,7 @@ module.exports = compress(async (req, res) => {
|
||||
if (func === "/getSymbols") {
|
||||
console.log("Request for Symbols");
|
||||
const db = new Database('./quoteDBs/consolidated.sqlite3', { verbose: console.log });
|
||||
const stmt = db.prepare("SELECT distinct Symbol FROM OptionQuotes order by 1");
|
||||
const stmt = db.prepare("SELECT distinct Symbol FROM Symbols order by 1");
|
||||
let allDates = stmt.all();
|
||||
//console.log(JSON.stringify(allDates));
|
||||
db.close();
|
||||
|
||||
Reference in New Issue
Block a user