Skip to content

Commit

Permalink
#285 bye bye correction factor columns
Browse files Browse the repository at this point in the history
  • Loading branch information
radumas committed Apr 19, 2021
1 parent e98182d commit 9858429
Show file tree
Hide file tree
Showing 3 changed files with 253 additions and 254 deletions.
6 changes: 1 addition & 5 deletions here/traffic/here_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -165,11 +165,7 @@ def send_data_to_database(ctx=None, datafile = None, dbsetting=None):
unzip = subprocess.Popen(['gunzip','-c',datafile], stdout=subprocess.PIPE, stderr=subprocess.PIPE)
#Second uses check_call and 'ON_ERROR_STOP=1' to make sure errors are captured and that the third
#process doesn't run befor psql is finished.
copy = r'''"\COPY here.ta (link_dir,tx,epoch_min,length,mean,
stddev,min_spd,max_spd,confidence,pct_5,pct_10,
pct_15,pct_20,pct_25,pct_30,pct_35,pct_40,pct_45,
pct_50,pct_55,pct_60,pct_65,pct_70,pct_75,pct_80,
pct_85,pct_90,pct_95) FROM STDIN WITH (FORMAT csv, HEADER
copy = r'''"\COPY here.ta FROM STDIN WITH (FORMAT csv, HEADER
TRUE);"'''
if os.getenv('here_bot'):
#there's a here_bot environment variable to connect to postgresql.
Expand Down
7 changes: 1 addition & 6 deletions here/traffic/sql/create_tables.sql
Original file line number Diff line number Diff line change
Expand Up @@ -36,12 +36,7 @@ WITH (
);
ALTER TABLE here.ta
OWNER TO here_admins;
CREATE TABLE IF NOT EXISTS here.ta_staging (
LIKE here.ta)
;
ALTER TABLE here.ta_staging
OWNER TO here_admins;*/
*/

/*Loops through the years and then months for which we currently have data in order to create a partitioned table for each month*/

Expand Down
Loading

0 comments on commit 9858429

Please sign in to comment.