Closed Kistor closed 2 months ago
Hi! I use your lib fo project and use this code:
#[derive(Row, Serialize, Deserialize)] #[serde(rename_all = "camelCase")] pub struct RowSpeedLane { #[serde(rename = "id")] #[serde(with = "clickhouse::serde::uuid")] pub uuid: Uuid, #[serde(rename = "fixationTime")] pub detect_time: i64, #[serde(rename = "extComplexId")] pub complex_id: String, #[serde(rename = "extDetectorId")] pub detector_id: String, pub ext_lane_number: i8, pub ext_vehicle_speed: f64, }
After Serialize i expext, that field ext_lane_number will be extLaneNumber (worked [serde(rename_all = "camelCase")) , but i get this:
ext_lane_number
extLaneNumber
[serde(rename_all = "camelCase")
Err(bad response: Code: 16, e.displayText() = DB::Exception: No such column ext_lane_number in table tda_demo.count_by_lane (143a1954-1aed-4b87-943a-19541aed8b87) (version 21.7.4.18 (official build)))
Thank for attantion!
Hi, Row doesn't support rename_all for now, only rename. It's not a big problem to implement it by using the heck crate, but I have no time for it for now.
Row
rename_all
rename
heck
Hi! I use your lib fo project and use this code:
After Serialize i expext, that field
ext_lane_number
will beextLaneNumber
(worked[serde(rename_all = "camelCase")
) , but i get this:Thank for attantion!