mirror of https://github.com/citusdata/citus.git
Fixes text search deparser
parent
d95a615907
commit
2e9ea032ce
|
@ -15,8 +15,8 @@
|
|||
#include "pg_version_constants.h"
|
||||
|
||||
#include "distributed/commands.h"
|
||||
#include "distributed/comment.h"
|
||||
#include "distributed/commands/utility_hook.h"
|
||||
#include "distributed/comment.h"
|
||||
#include "distributed/deparser.h"
|
||||
#include "distributed/version_compat.h"
|
||||
|
||||
|
|
|
@ -395,68 +395,6 @@ DeparseAlterTextSearchDictionarySchemaStmt(Node *node)
|
|||
}
|
||||
|
||||
|
||||
/*
|
||||
* DeparseTextSearchConfigurationCommentStmt returns the sql statement representing
|
||||
* COMMENT ON TEXT SEARCH CONFIGURATION ... IS ...
|
||||
*/
|
||||
char *
|
||||
DeparseTextSearchConfigurationCommentStmt(Node *node)
|
||||
{
|
||||
CommentStmt *stmt = castNode(CommentStmt, node);
|
||||
Assert(stmt->objtype == OBJECT_TSCONFIGURATION);
|
||||
|
||||
StringInfoData buf = { 0 };
|
||||
initStringInfo(&buf);
|
||||
|
||||
appendStringInfo(&buf, "COMMENT ON TEXT SEARCH CONFIGURATION %s IS ",
|
||||
NameListToQuotedString(castNode(List, stmt->object)));
|
||||
|
||||
if (stmt->comment == NULL)
|
||||
{
|
||||
appendStringInfoString(&buf, "NULL");
|
||||
}
|
||||
else
|
||||
{
|
||||
appendStringInfoString(&buf, quote_literal_cstr(stmt->comment));
|
||||
}
|
||||
|
||||
appendStringInfoString(&buf, ";");
|
||||
|
||||
return buf.data;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* DeparseTextSearchDictionaryCommentStmt returns the sql statement representing
|
||||
* COMMENT ON TEXT SEARCH DICTIONARY ... IS ...
|
||||
*/
|
||||
char *
|
||||
DeparseTextSearchDictionaryCommentStmt(Node *node)
|
||||
{
|
||||
CommentStmt *stmt = castNode(CommentStmt, node);
|
||||
Assert(stmt->objtype == OBJECT_TSDICTIONARY);
|
||||
|
||||
StringInfoData buf = { 0 };
|
||||
initStringInfo(&buf);
|
||||
|
||||
appendStringInfo(&buf, "COMMENT ON TEXT SEARCH DICTIONARY %s IS ",
|
||||
NameListToQuotedString(castNode(List, stmt->object)));
|
||||
|
||||
if (stmt->comment == NULL)
|
||||
{
|
||||
appendStringInfoString(&buf, "NULL");
|
||||
}
|
||||
else
|
||||
{
|
||||
appendStringInfoString(&buf, quote_literal_cstr(stmt->comment));
|
||||
}
|
||||
|
||||
appendStringInfoString(&buf, ";");
|
||||
|
||||
return buf.data;
|
||||
}
|
||||
|
||||
|
||||
/*
|
||||
* AppendStringInfoTokentypeList specializes in adding a comma separated list of
|
||||
* token_tyoe's to TEXT SEARCH CONFIGURATION commands
|
||||
|
|
|
@ -234,7 +234,6 @@ extern void QualifyAlterRoleSetStmt(Node *stmt);
|
|||
extern char * DeparseCreateRoleStmt(Node *stmt);
|
||||
extern char * DeparseDropRoleStmt(Node *stmt);
|
||||
extern char * DeparseGrantRoleStmt(Node *stmt);
|
||||
extern char * DeparseRoleCommentStmt(Node *node);
|
||||
extern char * DeparseReassignOwnedStmt(Node *node);
|
||||
|
||||
/* forward declarations for deparse_owned_stmts.c */
|
||||
|
@ -256,7 +255,6 @@ extern char * DeparseAlterDatabaseRefreshCollStmt(Node *node);
|
|||
extern char * DeparseAlterDatabaseSetStmt(Node *node);
|
||||
extern char * DeparseCreateDatabaseStmt(Node *node);
|
||||
extern char * DeparseDropDatabaseStmt(Node *node);
|
||||
extern char * DeparseDatabaseCommentStmt(Node *node);
|
||||
extern char * DeparseAlterDatabaseRenameStmt(Node *node);
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue