mysql数据库中查看某个视图的定义的SQL语句
环境描述:
-
mysql版本:5.5.57-log 操作系统版本:Red Hat Enterprise Linux Server release 6.6 (Santiago)
需求描述:
查看某个视图的定义SQL语句
通过information_schema数据库下的views表来进行查询:
SELECT table_name, table_schema, view_definition, check_option, is_updatable FROM information_schema.views WHERE table_name = v_tGSELECT table_name, table_schema, view_definition, check_option, is_updatable FROM information_schema.views WHERE table_name = v_tG
查询结果:
说明:其中view_definition字段就是视图的定义。
文档创建时间:2018年3月8日10:57:18
环境描述: mysql版本:5.5.57-log 操作系统版本:Red Hat Enterprise Linux Server release 6.6 (Santiago) 需求描述: 查看某个视图的定义SQL语句 通过information_schema数据库下的views表来进行查询: SELECT table_name, table_schema, view_definition, check_option, is_updatable FROM information_schema.views WHERE table_name = v_tG 查询结果: 说明:其中view_definition字段就是视图的定义。 文档创建时间:2018年3月8日10:57:18下一篇:
【MySQL】数据处理之 增●删●改