Skip to content

Commit 1d06e5c

Browse files
authored
Merge pull request #1 from lmangani/where
WHERE condition parser
2 parents 9818c41 + e3209c1 commit 1d06e5c

File tree

9 files changed

+636
-14
lines changed

9 files changed

+636
-14
lines changed

.github/workflows/MainDistributionPipeline.yml

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -12,18 +12,18 @@ concurrency:
1212
cancel-in-progress: true
1313

1414
jobs:
15-
duckdb-next-build:
16-
name: Build extension binaries
17-
uses: duckdb/extension-ci-tools/.github/workflows/_extension_distribution.yml@main
18-
with:
19-
duckdb_version: main
20-
ci_tools_version: main
21-
extension_name: parser_tools
15+
# duckdb-next-build:
16+
# name: Build extension binaries
17+
# uses: duckdb/extension-ci-tools/.github/workflows/_extension_distribution.yml@main
18+
# with:
19+
# duckdb_version: main
20+
# ci_tools_version: main
21+
# extension_name: parser_tools
2222

2323
duckdb-stable-build:
2424
name: Build extension binaries
25-
uses: duckdb/extension-ci-tools/.github/workflows/_extension_distribution.yml@v1.2.1
25+
uses: duckdb/extension-ci-tools/.github/workflows/_extension_distribution.yml@v1.3.0
2626
with:
27-
duckdb_version: v1.2.1
28-
ci_tools_version: v1.2.1
29-
extension_name: parser_tools
27+
duckdb_version: v1.3.0
28+
ci_tools_version: v1.3.0
29+
extension_name: parser_tools

.gitmodules

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@
55
[submodule "extension-ci-tools"]
66
path = extension-ci-tools
77
url = https://github.com/duckdb/extension-ci-tools
8-
branch = main
8+
branch = main

CMakeLists.txt

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@ include_directories(src/include)
1212
set(EXTENSION_SOURCES
1313
src/parser_tools_extension.cpp
1414
src/parse_tables.cpp
15+
src/parse_where.cpp
1516
)
1617

1718
build_static_extension(${TARGET_NAME} ${EXTENSION_SOURCES})

duckdb

Submodule duckdb updated 2460 files

src/include/parse_where.hpp

Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
#pragma once
2+
3+
#include "duckdb.hpp"
4+
#include <string>
5+
#include <vector>
6+
7+
namespace duckdb {
8+
9+
// Forward declarations
10+
class DatabaseInstance;
11+
12+
struct WhereConditionResult {
13+
std::string condition;
14+
std::string table_name; // The table this condition applies to (if determinable)
15+
std::string context; // The context where this condition appears (WHERE, HAVING, etc.)
16+
};
17+
18+
struct DetailedWhereConditionResult {
19+
std::string column_name; // The column being compared
20+
std::string operator_type; // The comparison operator (>, <, =, etc.)
21+
std::string value; // The value being compared against
22+
std::string table_name; // The table this condition applies to (if determinable)
23+
std::string context; // The context where this condition appears (WHERE, HAVING, etc.)
24+
};
25+
26+
void RegisterParseWhereFunction(DatabaseInstance &db);
27+
void RegisterParseWhereScalarFunction(DatabaseInstance &db);
28+
void RegisterParseWhereDetailedFunction(DatabaseInstance &db);
29+
30+
} // namespace duckdb

0 commit comments

Comments
 (0)