fix creation of new shards through a view on postgres 9.3 on rails 3

Change-Id: Ibd25dde8758ebaee3db855fb89fecb72d898457b
Reviewed-on: https://gerrit.instructure.com/29577
Tested-by: Jenkins <jenkins@instructure.com>
Reviewed-by: Jacob Fugal <jacob@instructure.com>
Product-Review: Cody Cutrer <cody@instructure.com>
QA-Review: Cody Cutrer <cody@instructure.com>