Mercurial > gemma
comparison pkg/imports/fa.go @ 4461:7128741faeb9
Changed fa data to accept "position" as strings, not a 2char "position_code"
author | Sascha Wilde <wilde@intevation.de> |
---|---|
date | Mon, 23 Sep 2019 12:59:48 +0200 |
parents | c811d5da69bd |
children | 9b1e5a3ed3cc |
comparison
equal
deleted
inserted
replaced
4460:ace7c8d6290d | 4461:7128741faeb9 |
---|---|
66 ORDER BY measure_date DESC LIMIT 1 | 66 ORDER BY measure_date DESC LIMIT 1 |
67 ` | 67 ` |
68 | 68 |
69 insertFASQL = ` | 69 insertFASQL = ` |
70 INSERT INTO waterway.fairway_availability ( | 70 INSERT INTO waterway.fairway_availability ( |
71 position_code, | 71 position, |
72 bottleneck_id, | 72 bottleneck_id, |
73 surdat, | 73 surdat, |
74 critical, | 74 critical, |
75 date_info, | 75 date_info, |
76 source_organization | 76 source_organization |
80 $3, | 80 $3, |
81 $4, | 81 $4, |
82 $5, | 82 $5, |
83 $6 | 83 $6 |
84 ) ON CONFLICT (bottleneck_id, surdat) DO UPDATE SET | 84 ) ON CONFLICT (bottleneck_id, surdat) DO UPDATE SET |
85 position_code = EXCLUDED.position_code, | 85 position = EXCLUDED.position, |
86 critical = EXCLUDED.critical, | 86 critical = EXCLUDED.critical, |
87 date_info = EXCLUDED.date_info, | 87 date_info = EXCLUDED.date_info, |
88 source_organization = EXCLUDED.source_organization | 88 source_organization = EXCLUDED.source_organization |
89 RETURNING id` | 89 RETURNING id` |
90 | 90 |