Impl Drivers for User-Defined Functions#77128
Impl Drivers for User-Defined Functions#77128dahbka-lis wants to merge 31 commits intoClickHouse:masterfrom
Conversation
|
|
||
| if (execute_direct) | ||
| { | ||
| boost::split(command_arguments, command_value, [](char c) { return c == ' '; }); |
| const auto & code = query.getFunctionBody(); | ||
| if (command_arguments.empty()) | ||
| { | ||
| command += " \"" + code + '\"'; |
There was a problem hiding this comment.
This won't work for two reasons:
- A limit on the command length.
- Different shells may require different escaping.
This needs a solution with temporary files.
There was a problem hiding this comment.
Double-quoted string in sh or bash is a huge mess, it does interpolation ($var substitution) and even has a special treatment of ! (an obscure feature, I never bothered to check what it is).
| namespace | ||
| { | ||
|
|
||
| String formatCodeBlock(const String & code) |
There was a problem hiding this comment.
But this damages the code, because it can be whitespace-sensitive.
| continue; | ||
|
|
||
| line.erase(0, min_tabs_count); | ||
| boost::replace_all(line, "\"", "\\\""); |
There was a problem hiding this comment.
This is obviously incorrect because you also have to escape backslashes.
|
Dear @vdimir, this PR hasn't been updated for a while. You will be unassigned. Will you continue working on it? If so, please feel free to reassign yourself. |
|
Workflow [PR], commit [f316061] Summary: ❌
|
|
@dahbka-lis Hi, is this PR still ongoing? We really need this feature. |
|
The coursework has finished, but the feature request remains, and this pull request has to be taken over. |
Hi @zoomxi @alexey-milovidov! I would like to refactor |
|
No deadline. |
|
Dear @dahbka-lis, this PR hasn't been updated for a while. Will you continue working on it? If not, please close it. Otherwise, ignore this message. |
1 similar comment
|
Dear @dahbka-lis, this PR hasn't been updated for a while. Will you continue working on it? If not, please close it. Otherwise, ignore this message. |
wip |
|
Dear @dahbka-lis, this PR hasn't been updated for a while. Will you continue working on it? If not, please close it. Otherwise, ignore this message. |
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes to CHANGELOG.md):
Expand
CREATE FUNCTIONquery for easy creating User-Defined Functions and its execution by some driver like #71172....
Documentation entry for user-facing changes