Forum Discussion

Shivaranjini's avatar
Shivaranjini
Frequent Visitor
4 years ago

How to add the headers to the json content

Hello All,

I'm stuck trying to add the headers to the json content.

My source is the list of the json data i.e. the table is this format

Column
Records1
Records2
Records3
Records4
Records5
Records6

And each records of the table have json data like

object1:value1
object2:value2
object3:value3
object4:value4
object5:value5
object6:value6

 

I want to give the header to all of the records content like this:

ColumnNameValue
object1:value1
object2:value2
object3:value3
object4:value4
object5:value5
object6:value6

How do I achieve this?

2 Replies

  • artemus's avatar
    artemus
    Icon for Microsoft Employee rankMicrosoft Employee

    The easiest way is to do a splitcolumns operation in the transform tab. Just split on the colon (:) and rename the resulting columns.

  • mahoneypat's avatar
    mahoneypat
    Icon for Microsoft Employee rankMicrosoft Employee

    The simplest thing to try would be to expand it all out so that each Object is a column, and then unpivot your data to get an Attribute and Value column like you are looking for. If you provide some sample JSON, a more specific solution can be suggested.

     

    Pat