!6397 解决timescaledb插件,时序表查看指定的SQL执行计划不准确

Merge pull request !6397 from 叶某人/IA5DSZ
This commit is contained in:
opengauss_bot
2024-09-24 06:39:11 +00:00
committed by Gitee

View File

@ -8893,13 +8893,14 @@ static char* get_variable(
/* Identify names to use */
schemaname = NULL; /* default assumptions */
refname = rte->eref->aliasname;
if (NULL != rte->relname && u_sess->hook_cxt.forTsdbHook) {
rte->relname = get_rel_name(rte->relid);
rte->eref->aliasname = rte->relname;
}
refname = rte->eref->aliasname;
/* Exceptions occur only if the RTE is alias-less */
if (rte->alias == NULL) {
if (rte->rtekind == RTE_RELATION || no_alias) {