I am using MS SQL database. I need to selected rows as per Max value without duplicate. Tried SQL QUERY given below
Select CId,
Rate,
Max(FDateTime)
from FTable
Where OId = 1413 and type = 'C'
Group by CId,Rate
But it gives duplicate values.
I need Rate value and CID as per MAX(FDateTime)
. How can I achieve this output?
I have tried Inner join concept also but I have faced some errors on that concept.