查询语句

SELECT
    object_name( id ) AS 表名 ,
    c.name AS 字段名 ,
    t.name 数据类型 ,
    c.prec AS 长度 
FROM
    syscolumns c
    INNER JOIN systypes t ON c.xusertype= t.xusertype 
WHERE
    objectproperty( id, 'IsView' ) = 1 
    AND id = object_id( 'test_view' )

 

注意:其中 test_view为对应视图的名称

 

相关文章:

  • 2021-08-26
  • 2021-06-05
  • 2022-02-13
  • 2022-12-23
  • 2022-12-23
  • 2022-12-23
猜你喜欢
  • 2022-02-15
  • 2021-10-23
  • 2021-06-13
  • 2023-01-12
  • 2021-09-26
  • 2022-12-23
  • 2022-12-23
相关资源
相似解决方案