Information schema for a Table

0

Please login or register to vote for this query.

(click on this box to dismiss)

DON'T EDIT THIS QUERY! YOU HAVE LINKED TO IT FROM HERE: http://meta.stackexchange.com/a/2678/158100 REMEMBER?

Drones and Model Aircraft Meta

Q&A for experienced flyers, pilots, and builders of drones and model aircraft

select 
    ORDINAL_POSITION as [ردیف]
     , column_name as [فیلد]
     , case 
       when ##PK:string?id## = c.column_name then ' (PK)' 
       end as [کلید]
     , data_type as [نوع]
     , is_nullable as [NULL]
     , coalesce(CHARACTER_MAXIMUM_LENGTH
             , numeric_precision
             , datetime_precision) as [طول/اندازه]
from INFORMATION_SCHEMA.Columns c
where c.table_name = ##table:string?users##
order by ordinal_position

Enter Parameters

Options:
Switch to main site
loading Hold tight while we fetch your results