Hi Tejo,
I suppose you are creating the JSON messages inside Control procedures. Here you have full control over how you combine information from your model. You could make use of the Column alias field, but it may be better to use Tags for this on your columns. This could even be generated automatically using Dynamic model procedure, creating Tags with the column name as default for example, and leaving the generated_by_control_proc_id empty so you can make exceptions for the columns that need it.
Hope that helps!
Example out of the Export project version task:
--Export [TAB]
insert into @data (data_tab_name, json_data)
select '[TAB]',
(select
[COL] as [COL_NAME][COMMA]
from [TAB] t1
for json path)
[TAB] → Table name - tab_id
[COL] → Column name - col_id
[COL_NAME] → Column alias - alias_col_id / tag value
[COMMA] → Add a comma after every row except the last one
Replace these [TEXT] using Control procedure code
Thanks Mark, I’m gonna try this!