Update config.go

refactored the validate function so that the target validation is performed with shared code. And when exporting to a DB and the table name is not specified then use the package name.