Fix for pagination on SQL Server
Added method to get the id of the parent when paginates an associated model