I have a situation like this :
I have a code giving correct results:
Just one question, performance wise, is using the olap function good ? I have a major concern of performance as my table here is a huge table.
At least OLAP is performing better than a subquery :-)
To avoid it you have to change the table/ETL design, e.g. maintain a flag indicating the row with the max date.