Add distinct clause support