I have a search result like below: { [-] dt: 2021-06-24T22:46:40.7013297Z flds: [ [-] { [-] fn: username nv: LearningRegApplication } { [-] fn: dbQu...
See more...
I have a search result like below: { [-] dt: 2021-06-24T22:46:40.7013297Z flds: [ [-] { [-] fn: username nv: LearningRegApplication } { [-] fn: dbQueries nv: SQL_QUERIES=Select emp.fieldA, emp.fieldB, emp.fieldC, emp.fieldD from Template.table emp WHERE (UPPER(emp.fieldA) = UPPER(:emp.fieldA)) AND (UPPER(emp.fieldB) = UPPER(:emp_fieldB)) AND (UPPER(emp.fieldC) IN (UPPER('aaa'), UPPER('bbb'), UPPER('ccc'), UPPER('ddd'))) } ] sf: EmployeeLogic sid: T1-SECURITY-{A-8FE-76E9-C3A2-ED890B} sm: GetAsync stat: Success tid: yb6Any-PG00IG53 } I used |SPATH OUTPUT=status PATH=stat | SPATH OUTPUT=nv PATH=flds{}.nv | SPATH OUTPUT=fn PATH=flds{}.fn | Table fn nv host status. The results return 4 columns. Each row has the array of the 2 sets of key-value pair in the fn/nv stacked together. But host and status has only hostname and status values as follows: fn nv host status (Row 1) username LearningRegApplication MyHost Success (Row 1) dbQueries SQL_QUERIES=Select emp.fieldA, emp.fieldB, emp.fieldC, emp.fieldD from Template.table emp WHERE (UPPER(emp.fieldA) = UPPER(:emp.fieldA)) AND (UPPER(emp.fieldB) = UPPER(:emp_fieldB)) AND (UPPER(emp.fieldC) IN (UPPER('aaa'), UPPER('bbb'), UPPER('ccc'), UPPER('ddd'))) And I have uploaded a CSV file that contains all query fields name. I want to see each field was queried by which application and insert them in that field row (not sure what is the best way to present this information). So the output may look like something below: fieldA LearningRegApplication fieldB LearningRegApplication, AThirdApp fieldC LearningRegApplication, ASecondApp fieldD LearningRegApplication fieldE ASecondApp, AThirdApp fieldF AForthApp : : What is the way to use the full CSV list of field names to insert the app to each SQL field name?