CREATE TABLE IF NOT EXISTS billionaires (
id UUID DEFAULT uuid_generate_v4() NOT NULL,
place INT,
location GEOGRAPHY(POINT,4326),
PRIMARY KEY (id)
);
postgres = { version = "0.19.9", features = [
"with-uuid-1",
"with-chrono-0_4",
"with-geo-types-0_6",
] }
"geography" => {
let value:String = billionaire.get(name);
// format!("{} {}",value.x(),value.y())
value
}
error retrieving column location: error deserializing column 0: cannot convert between the Rust type alloc::string::String and the Postgres type geography
I don't think there is support for PostGIS' geography type—which is not the same as Postgres' POINT type I just learned—in the postgres crate. There might be something in the georust project, or you have to implement the deserialisation yourself.
[1, 1, 0, 0, 32, 230, 16, 0, 0, 17, 84, 141, 94, 13, 102, 83, 64, 17, 167, 147, 108, 117, 241, 41, 64]
this is not utf8 valid and read to string dosent work for this problem
how can i turn the value of above into readable