Gets a datasource

Gets a datasource based on the code passed