realtor-lp-backend/migrations/2_property.sql

18 lines
498 B
MySQL
Raw Normal View History

2023-05-03 16:59:54 +00:00
CREATE TABLE IF NOT EXISTS "property" (
id UUID PRIMARY KEY,
project_id UUID,
realtor_id UUID NOT NULL,
media TEXT NOT NULL,
2023-05-03 17:35:33 +00:00
property_type VARCHAR NOT NULL,
property_sale_type VARCHAR NOT NULL,
country VARCHAR,
city VARCHAR,
district VARCHAR,
price_usd FLOAT8 NOT NULL,
rooms SMALLINT NOT NULL,
bathrooms FLOAT4 NOT NULL,
area FLOAT4 NOT NULL,
admin_tag VARCHAR,
2023-05-03 16:59:54 +00:00
time_created TIMESTAMPTZ NOT NULL,
last_updated TIMESTAMPTZ NOT NULL
);