Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/database/migration/20260408200000_cria_view_splinker.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export async function run(knex: Knex): Promise<void> {
COALESCE(t.data_coleta_dia::text, '') AS "DayCollected",
COALESCE(t.data_coleta_mes::text, '') AS "MonthCollected",
COALESCE(t.data_coleta_ano::text, '') AS "YearCollected",
(COALESCE(col.nome, '') || COALESCE(cc.complementares, '')) AS "Collector"
(COALESCE(col.nome, '') ||' ' || COALESCE(cc.complementares, '')) AS "Collector",
COALESCE(t.numero_coleta::text, '') AS "CollectorNumber",
'' AS "Continent",
COALESCE(p.nome, '') AS "Country",
Expand Down Expand Up @@ -76,7 +76,7 @@ export async function run(knex: Knex): Promise<void> {
) AS "Notes"
FROM tombos t
LEFT JOIN locais_coleta lc ON t.local_coleta_id = lc.id
LEFT JOIN cidades c ON lc.cidade_id = c.id
LEFT JOIN cidades c ON t.cidade_id = c.id
LEFT JOIN estados est ON c.estado_id = est.id
LEFT JOIN paises p ON est.pais_id = p.id
LEFT JOIN familias f ON t.familia_id = f.id
Expand Down
Loading