Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

61 segments had to be manually inserted into prod table #95

Closed
danrademacher opened this issue Sep 13, 2019 · 0 comments
Closed

61 segments had to be manually inserted into prod table #95

danrademacher opened this issue Sep 13, 2019 · 0 comments
Assignees

Comments

@danrademacher
Copy link
Collaborator

When ECG did an edit>prod update today, they saw big breaks in the trail. I did the update myself and saw the same issue.

We use this SQL:
https://github.com/EastCoastGreenwayAlliance/ecg-map/blob/master/sql/ecg_lines_update_prod_table.sql

I checked the edit table and those segments were present, renderable both in QGIS and in CARTO web UI, and I couldn't see anything obviously wrong with them.

I wondered if they were newest edits. They were not, but they were the newest ADDED -- the max pline_id in the prod table was 1126507 while the max in the edit table was 1126644

Here's a map preview:

image

When I ran segments of the SQL that should find and insert all plines that are in the ecg_route_lines table but not in ecg_route_lines_prod, I got null results. As if they'd all been synced over.

But when I queried for any of the larger pline_id values in teh prod table, I got nothing.

Had to run this SQL to drag them over:

INSERT INTO ecg_route_lines_prod (
  the_geom,
  pline_id,
  ecg_review,
  direction,
  title,
  line_type,
  meters,
  datetime_modified
)
SELECT
  the_geom,
  pline_id,
  ecg_review,
  direction,
  title,
  line_type,
  meters,
  current_timestamp
FROM ecg_route_lines a
WHERE a.pline_id IN (
  '1126507','1126509','1126510','1126512','1126513','1126514','1126515','1126516','1126517','1126518','1126519','1126520','1126521','1126522','1126523','1126524','1126526','1126527','1126528','1126529','1126533','1126534','1126535','1126536','1126537','1126538','1126539','1126542','1126547','1126548','1126553','1126554','1126558','1126559','1126560','1126561','1126562','1126563','1126564','1126565','1126566','1126567','1126568','1126569','1126570','1126571','1126572','1126573','1126574','1126575','1126576','1126577','1126578','1126579','1126580','1126582','1126606','1126607','1126608','1126643','1126644'
);
@danrademacher danrademacher self-assigned this Sep 13, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant