Skip to content

Commit f9cf303

Browse files
committed
fix map err
1 parent 1e8646a commit f9cf303

File tree

1 file changed

+2
-14
lines changed
  • rust/cubesql/cubesql/src/compile/engine/df

1 file changed

+2
-14
lines changed

rust/cubesql/cubesql/src/compile/engine/df/scan.rs

Lines changed: 2 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -918,13 +918,7 @@ pub fn transform_response<V: ValueObject>(
918918
field_name,
919919
{
920920
(FieldValue::String(s), builder) => {
921-
let timestamp = parse_date_str(s.as_ref())
922-
.map_err(|e| {
923-
DataFusionError::Execution(format!(
924-
"Can't parse timestamp: '{}': {}",
925-
s, e
926-
))
927-
})?;
921+
let timestamp = parse_date_str(s.as_ref())?;
928922
// TODO switch parsing to microseconds
929923
if timestamp.and_utc().timestamp_millis() > (((1i64) << 62) / 1_000_000) {
930924
builder.append_null()?;
@@ -952,13 +946,7 @@ pub fn transform_response<V: ValueObject>(
952946
field_name,
953947
{
954948
(FieldValue::String(s), builder) => {
955-
let timestamp = parse_date_str(s.as_ref())
956-
.map_err(|e| {
957-
DataFusionError::Execution(format!(
958-
"Can't parse timestamp: '{}': {}",
959-
s, e
960-
))
961-
})?;
949+
let timestamp = parse_date_str(s.as_ref())?;
962950
// TODO switch parsing to microseconds
963951
if timestamp.and_utc().timestamp_millis() > (((1 as i64) << 62) / 1_000_000) {
964952
builder.append_null()?;

0 commit comments

Comments
 (0)