added table parameter for multiple reference fields