File tree 3 files changed +6
-6
lines changed
3 files changed +6
-6
lines changed Original file line number Diff line number Diff line change 17
17
18
18
use datafusion_common:: DataFusionError ;
19
19
20
- pub fn byte_to_string ( b : u8 ) -> Result < String , DataFusionError > {
20
+ pub fn csv_delimiter_to_string ( b : u8 ) -> Result < String , DataFusionError > {
21
21
let b = & [ b] ;
22
22
let b = std:: str:: from_utf8 ( b)
23
23
. map_err ( |_| DataFusionError :: Internal ( "Invalid CSV delimiter" . to_owned ( ) ) ) ?;
Original file line number Diff line number Diff line change @@ -96,17 +96,17 @@ pub(crate) fn parse_physical_expr(
96
96
input_schema,
97
97
) ?) ,
98
98
ExprType :: AggregateExpr ( _) => {
99
- return Err ( DataFusionError :: Internal (
99
+ return Err ( DataFusionError :: NotImplemented (
100
100
"Cannot convert aggregate expr node to physical expression" . to_owned ( ) ,
101
101
) ) ;
102
102
}
103
103
ExprType :: WindowExpr ( _) => {
104
- return Err ( DataFusionError :: Internal (
104
+ return Err ( DataFusionError :: NotImplemented (
105
105
"Cannot convert window expr node to physical expression" . to_owned ( ) ,
106
106
) ) ;
107
107
}
108
108
ExprType :: Sort ( _) => {
109
- return Err ( DataFusionError :: Internal (
109
+ return Err ( DataFusionError :: NotImplemented (
110
110
"Cannot convert sort expr node to physical expression" . to_owned ( ) ,
111
111
) ) ;
112
112
}
Original file line number Diff line number Diff line change @@ -58,7 +58,7 @@ use prost::bytes::BufMut;
58
58
use prost:: Message ;
59
59
60
60
use crate :: common:: proto_error;
61
- use crate :: common:: { byte_to_string , str_to_byte} ;
61
+ use crate :: common:: { csv_delimiter_to_string , str_to_byte} ;
62
62
use crate :: from_proto:: parse_expr;
63
63
use crate :: physical_plan:: from_proto:: parse_physical_expr;
64
64
use crate :: protobuf:: physical_expr_node:: ExprType ;
@@ -946,7 +946,7 @@ impl AsExecutionPlan for PhysicalPlanNode {
946
946
protobuf:: CsvScanExecNode {
947
947
base_conf : Some ( exec. base_config ( ) . try_into ( ) ?) ,
948
948
has_header : exec. has_header ( ) ,
949
- delimiter : byte_to_string ( exec. delimiter ( ) ) ?,
949
+ delimiter : csv_delimiter_to_string ( exec. delimiter ( ) ) ?,
950
950
} ,
951
951
) ) ,
952
952
} )
You can’t perform that action at this time.
0 commit comments