Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Support Cases coming to Qlik Community Oct. 4! Start chats, open cases, explore resources: READ DETAILS
cancel
Showing results for 
Search instead for 
Did you mean: 
andreyfcdk91
Creator
Creator

Delete records from VBS array

Hi community!

Trying to figure out with the following taks:

I have source 2-dimensional array in VBS script, which i need to read in the loop and save only those records, which have the max TimeStamp per each Name:

Source:

  

NameTypeTimeStamp
AndrewType145678
AndrewType245679
AndrewType146678
AndrewType245660
MikeType36543
MikeType4653
TomType1643

Expected array:


  

NameTypeTimeStamp
AndrewType146678
MikeType36543
TomType1643

I tried to use  a classic way of fetching the max element using following code, but for not a bit confused how to apply it for 2-dim array:

Dim arr,max

arr=array(6,5,8,2,0,9)

max=arr(0)

for i=0 to ubound(arr)

if max< arr(i) then
max=arr(i)

end if

next

Thanks for your help!

0 Replies