Files
osm2pgsql/tests/data/test_output_flex_relations.lua
Jochen Topf 3ad48b7f59 Replace add_row() by insert() in some tests
At some point we'll deprecate add_row(), tests that don't explicitly
test add_row() should use insert().
2023-01-23 11:47:33 +01:00

25 lines
501 B
Lua

local tables = {}
tables.t1 = osm2pgsql.define_relation_table('osm2pgsql_test_t1', {
{ column = 'tags', type = 'hstore' }
})
tables.t2 = osm2pgsql.define_relation_table('osm2pgsql_test_t2', {
{ column = 'tags', type = 'hstore' }
})
function osm2pgsql.process_relation(object)
if object.tags.t1 then
tables.t1:insert({
tags = object.tags
})
end
if object.tags.t2 then
tables.t2:insert({
tags = object.tags
})
end
end