diff --git a/dozer-sql/src/pipeline_builder/from_builder.rs b/dozer-sql/src/pipeline_builder/from_builder.rs index 7cf1974e69..e14c63b7b9 100644 --- a/dozer-sql/src/pipeline_builder/from_builder.rs +++ b/dozer-sql/src/pipeline_builder/from_builder.rs @@ -361,6 +361,9 @@ pub fn is_table_operator( ) -> Result, PipelineError> { match relation { TableFactor::Table { name, args, .. } => { + if args.is_none() { + return Ok(None); + } let operator = get_table_operator_descriptor(name, args)?; Ok(operator) diff --git a/dozer-sql/src/tests/builder_test.rs b/dozer-sql/src/tests/builder_test.rs index 9242e0fdab..ec227a72e3 100644 --- a/dozer-sql/src/tests/builder_test.rs +++ b/dozer-sql/src/tests/builder_test.rs @@ -111,7 +111,7 @@ impl Source for TestSource { fw: &mut dyn SourceChannelForwarder, _last_checkpoint: SourceState, ) -> Result<(), BoxedError> { - for n in 0..10000 { + for n in 0..10 { fw.send( IngestionMessage::OperationEvent { table_index: 0, @@ -194,9 +194,9 @@ impl Sink for TestSink { async fn test_pipeline_builder() { let mut pipeline = AppPipeline::new_with_default_flags(); let context = statement_to_pipeline( - "SELECT Spending \ - FROM TTL(TUMBLE(users, timestamp, '5 MINUTES'), timestamp, '1 MINUTE') \ - WHERE Spending >= 1", + "SELECT t.Spending \ + FROM TTL(TUMBLE(users, timestamp, '5 MINUTES'), timestamp, '1 MINUTE') t JOIN users u on t.CustomerID=u.CustomerID \ + WHERE t.Spending >= 1", &mut pipeline, Some("results".to_string()), vec![],