mirror of
https://github.com/tencentmusic/supersonic.git
synced 2025-12-12 20:51:48 +00:00
(improvement)(headless)Add timeFormat to dimension metadata of the Text2SQL prompt.
(improvement)(headless)Add `timeFormat` to dimension metadata of the Text2SQL prompt. #1621.
This commit is contained in:
@@ -114,6 +114,9 @@ public class PromptHelper {
|
|||||||
dimension.getAlias().stream().forEach(a -> alias.append(a + ","));
|
dimension.getAlias().stream().forEach(a -> alias.append(a + ","));
|
||||||
dimensionStr.append(" ALIAS '" + alias + "'");
|
dimensionStr.append(" ALIAS '" + alias + "'");
|
||||||
}
|
}
|
||||||
|
if (StringUtils.isNotEmpty(dimension.getTimeFormat())) {
|
||||||
|
dimensionStr.append(" FORMAT '" + dimension.getTimeFormat() + "'");
|
||||||
|
}
|
||||||
if (StringUtils.isNotEmpty(dimension.getDescription())) {
|
if (StringUtils.isNotEmpty(dimension.getDescription())) {
|
||||||
dimensionStr.append(
|
dimensionStr.append(
|
||||||
" COMMENT '" + dimension.getDescription() + "'");
|
" COMMENT '" + dimension.getDescription() + "'");
|
||||||
|
|||||||
Reference in New Issue
Block a user