How can I ignore a file based on the value range in a given attribute in it.

Kumar_Ayush
Kumar_Ayush New Altair Community Member
edited November 5 in Community Q&A
I have multiple files in the repository which I need to read first and then in each of there files there is a attribute called Time which has floating number value. I only want to read those files in which the max value of the Time attribute is between the range of 15 to 25.
Tagged:

Best Answer

  • Eden60
    Eden60 New Altair Community Member
    Answer ✓

    To ignore files based on the value range of a specific attribute called "Time," you can iterate through each file in the repository. Retrieve the "Time" attribute from each file and keep track of the maximum value encountered. After checking all the files, determine if the maximum "Time" value falls within the desired range of 15 to 25. If it does, process the file; otherwise, ignore it.

Answers

  • MartinLiebig
    MartinLiebig
    Altair Employee
    Hi,

    looks like you need to use List Repository Entrys and then filter by hand and use loop values. Something like this should be the solution.

    BR,
    Martin
  • Eden60
    Eden60 New Altair Community Member
    Answer ✓

    To ignore files based on the value range of a specific attribute called "Time," you can iterate through each file in the repository. Retrieve the "Time" attribute from each file and keep track of the maximum value encountered. After checking all the files, determine if the maximum "Time" value falls within the desired range of 15 to 25. If it does, process the file; otherwise, ignore it.