繁体   English   中英

如何在Teradata SQL中列出表的列

[英]How to list the columns of a table in Teradata SQL

我一直在使用Google搜索和搜索该网站,但找不到这个简单问题的答案。

如何在Teradata中列出或选择表的所有列?

不同的可能性

Help table <TableName> -- All columns of a table 
Help columns  <ViewName>.* -- All columns of a View
Show table <TableName> -- DDL of table
Show view <ViewName> -- DDL of View
show select * from  <ViewName>-- DDL of base table in a view

或从系统表中选择。

SELECT ColumnName 
FROM dbc.columnsV
WHERE DatabaseName = 'DB_NAME' and
TableName = 'table_name';

搜索teradata column name list会提供更多答案。

暂无
暂无

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM