Skip to main content
Glama
aliyun

Hologres MCP Server

Official
by aliyun

show_hg_table_ddl

Generate the DDL script for a table, view, or foreign table in a Hologres database by specifying the schema and table names.

Instructions

Show DDL script for a table, view, or foreign table in Hologres database.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
schemaYesSchema name in Hologres database
tableYesTable name in Hologres database

Implementation Reference

  • Handler logic for the 'show_hg_table_ddl' tool: extracts 'schema' and 'table' from input arguments, validates presence, constructs SQL query using hg_dump_script function, and delegates execution to handle_call_tool.
    elif name == "show_hg_table_ddl": schema = arguments.get("schema") table = arguments.get("table") if not all([schema, table]): raise ValueError("Schema and table are required") query = f"SELECT hg_dump_script('\"{schema}\".\"{table}\"')" else:
  • Registration of the 'show_hg_table_ddl' tool in the list_tools() function, including name, description, and input schema definition requiring 'schema' and 'table' parameters.
    # 新增 show_hg_table_ddl 工具 Tool( name="show_hg_table_ddl", description="Show DDL script for a table, view, or foreign table in Hologres database.", inputSchema={ "type": "object", "properties": { "schema": { "type": "string", "description": "Schema name in Hologres database" }, "table": { "type": "string", "description": "Table name in Hologres database" } }, "required": ["schema", "table"] } )
  • Input schema definition for the 'show_hg_table_ddl' tool, specifying required string parameters 'schema' and 'table' with descriptions.
    inputSchema={ "type": "object", "properties": { "schema": { "type": "string", "description": "Schema name in Hologres database" }, "table": { "type": "string", "description": "Table name in Hologres database" } }, "required": ["schema", "table"] }

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/aliyun/alibabacloud-hologres-mcp-server'

If you have feedback or need assistance with the MCP directory API, please join our Discord server