All Records from All SEDE Reference tables

1

Please login or register to vote for this query.

(click on this box to dismiss)

The Great Outdoors

Q&A for people who love outdoor activities, excursions, and outdoorsmanship

--select name as [Table] from sys.tables
--where (name like '%Types' or name like '%Reasons' or name like '%States')
--order by name
/*
select distinct
  table_name as [Table],
from information_schema.columns

where (table_name like '%Types' or table_name like '%Reasons' or table_name like '%States')
and column_name in ('Id','Name')
order by table_name
--case when table_name like '%OffTopic&' then `MarkdownMini` else 'Name'
*/


select 'FlagTypes' as [table], id, name from FlagTypes union 
select 'ReviewTaskStates' as [table], id, name from ReviewTaskStates union 
select 'PostTypes' as [table], id, name from PostTypes union 
select 'ReviewTaskTypes' as [table], id, name from ReviewTaskTypes union 
select 'CloseReasonTypes' as [table], id, name from CloseReasonTypes union 
select 'PostNoticeTypes' as [table], id, name from PostNoticeTypes union 
select 'VoteTypes' as [table], id, name from VoteTypes union 
select 'ReviewRejectionReasons' as [table], id, name from ReviewRejectionReasons union 
select 'ReviewTaskResultTypes' as [table], id, name from ReviewTaskResultTypes union 
select 'PostHistoryTypes' as [table], id, name from PostHistoryTypes 

order by [table]


--maybe? https://www.red-gate.com/simple-talk/sql/t-sql-programming/creating-cross-tab-queries-and-pivot-tables-in-sql/

Enter Parameters

Options:
Switch sites:
loading Hold tight while we fetch your results