changed method to fetch row