diff options
| author | schneefux <schneefux+commit@schneefux.xyz> | 2017-07-02 20:57:23 +0200 |
|---|---|---|
| committer | schneefux <schneefux+commit@schneefux.xyz> | 2017-07-02 20:57:23 +0200 |
| commit | 2be09e2ce40e60a452d865fbec6cd969c29ea42a (patch) | |
| tree | 36b086e57ee52b810980261cea2e22859d6db7a6 /worker.js | |
| parent | c60aeb4bb9e4381182ed0c30793ea6612ceaa283 (diff) | |
| download | cruncher-2be09e2ce40e60a452d865fbec6cd969c29ea42a.tar.gz cruncher-2be09e2ce40e60a452d865fbec6cd969c29ea42a.zip | |
fix table name via env var -> sql error
Diffstat (limited to 'worker.js')
| -rw-r--r-- | worker.js | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -74,7 +74,8 @@ if (LOGGLY_TOKEN) // for the `participant_api_id` array const player_script = fs.readFileSync("crunch_player.sql", "utf8"), team_script = fs.readFileSync("crunch_team.sql", "utf8"), - global_script = fs.readFileSync("crunch_global.sql", "utf8"); + global_script = fs.readFileSync("crunch_global.sql", "utf8") + .replace("`global_point`", CRUNCH_TABLE); // fill a buffer and execute an SQL on a bigger (> 1o) batch const participants_player = new Set(), @@ -126,7 +127,6 @@ if (LOGGLY_TOKEN) replacements: { build_regex_start: '^([[:digit:]]+;[[:digit:]]+,)*(', build_regex_end: ')+(,[[:digit:]]+;[[:digit:]]+)*$', - crunch_table: CRUNCH_TABLE, participant_api_ids: api_ids_global }, type: seq.QueryTypes.UPSERT |
