@@ -58,7 +58,7 @@ settings_from_cpp AS
5858),
5959main_content AS
6060(
61- SELECT format('## {} {}\\ n{}\\ n\\ nType: {}\\ n\\ nDefault value: {} \\ n\\ n{}\\ n\\ n',
61+ SELECT format('## {} {}\\ n{}\\ n\\ nType: \` {}\`\\ n\\ nDefault: \` {} \` \\ n\\ n{}\\ n\\ n',
6262 name, '{#'||name||'}', multiIf(tier == 'Experimental', '<ExperimentalBadge/>', tier == 'Beta', '<BetaBadge/>', ''), type, default, trim(BOTH '\\ n' FROM description))
6363 FROM system.settings WHERE name IN settings_from_cpp
6464 ORDER BY name
@@ -134,25 +134,38 @@ WITH
134134 (
135135 SELECT
136136 name,
137- replaceRegexpAll(description, '(?m)^[ \t]+', '') AS description
137+ replaceRegexpAll(description, '(?m)^[ \t]+', '') AS description,
138+ type,
139+ default
138140 FROM system.server_settings
139141 ),
140142 combined_server_settings AS
141143 (
142144 SELECT
143145 name,
144- description
146+ description,
147+ type,
148+ default
145149 FROM server_settings_in_source
146150 UNION ALL
147151 SELECT
148152 name,
149- doc AS description
153+ doc AS description,
154+ '' AS type,
155+ '' AS default
150156 FROM server_settings_outside_source
151157 ),
152158 formatted_settings AS
153159 (
154160 SELECT
155- format('## {} {}\n\n{}\n\n', name, lcase('{#'||name||'}'), description) AS formatted_text
161+ format(
162+ '## {} {}\n\n{}{}{}\n\n',
163+ name,
164+ lcase('{#'||name||'}'),
165+ if(type != '', concat('Type: \` ', type, '\` \n\n'), ''),
166+ if(default != '', concat('Default: \` ', default, '\` \n\n'), ''),
167+ description
168+ ) AS formatted_text
156169 FROM combined_server_settings
157170 ORDER BY name ASC
158171 ),
0 commit comments