enum PointType {
Point
}
type Point {
type PointType
coordinates Float[] //manually index as: '2dsphere'
}
type FeatureProperties {
id String
unit String
number String
street String
city String
district String
region String
postcode String
hash String
}
enum FeatureType {
Feature
}
model Feature {
id String @id @default(auto()) @map("_id") @db.ObjectId
type FeatureType
county County @relation(fields: [county_id], references: [id])
county_id String @db.ObjectId
properties FeatureProperties
geometry Point
zip_boundary ZipBoundary @relation(fields: [zip_boundary_id], references: [id])
zip_boundary_id String @db.ObjectId
houses House[]
created_at DateTime @default(now())
updated_at DateTime @updatedAt
@@map("features")
}
enum PointType {
Point
}
type Point {
type PointType
coordinates Float[] //manually index as: '2dsphere'
}
type FeatureProperties {
id String
unit String
number String
street String
city String
district String
region String
postcode String
hash String
}
enum FeatureType {
Feature
}
model Feature {
id String @id @default(auto()) @map("_id") @db.ObjectId
type FeatureType
county County @relation(fields: [county_id], references: [id])
county_id String @db.ObjectId
properties FeatureProperties
geometry Point
zip_boundary ZipBoundary @relation(fields: [zip_boundary_id], references: [id])
zip_boundary_id String @db.ObjectId
houses House[]
created_at DateTime @default(now())
updated_at DateTime @updatedAt
@@map("features")
}