I am having an issue loading the data from a rest connection. The problem is there is a column which repeated twice with exact name in the source because of which the qlik is not letting me select Header as true (It is not accepting duplicates). If I do not select header as true then it is going to assign col1,col2, so on as column names. However, I went getting the data with columns as col1, col2, col3 etc. Later, I am trying to change the column names with peek function by considering the first row value as the column name. but, it is not accepting the peek function. Is there any solution for this? Please find the sample code:
NoConcatenate [abc]: load [col_1] as peek('col_1',0,'test'), [col_2] as peek('col_2',0,'test'), [col_3] as peek('col_3',0,'test'), [col_4] as peek('col_4',0,'test'), [col_5] as peek('col_5',0,'test'), [col_6] as peek('col_6',0,'test'), [col_7] as peek('col_7',0,'test'), [col_8] as peek('col_8',0,'test'), [col_9] as peek('col_9',0,'test'), [col_10] as peek('col_10',0,'test')
DROP TABLE RestConnectorMasterTable;
The above code is showing error at peek function. Please note that for simplicity purpose i have taken only few columns, but in the data I have more than 200 columns.