From: Dagfinn Ilmari Mannsåker Date: Wed, 10 Dec 2014 17:37:37 +0000 (+0000) Subject: Use SQL-standard quoting in Year2000CDs view X-Git-Url: http://git.shadowcat.co.uk/gitweb/gitweb.cgi?a=commitdiff_plain;h=795c37a39e8807b69a1212275c951e0f750d8001;p=dbsrgits%2FDBIx-Class-Historic.git Use SQL-standard quoting in Year2000CDs view This lets DBICTEST_SQLT_DEPLOY=1 work with non-SQLite DBICTEST_DSN --- diff --git a/t/lib/DBICTest/Schema/Year2000CDs.pm b/t/lib/DBICTest/Schema/Year2000CDs.pm index 3ae7de5..f938d59 100644 --- a/t/lib/DBICTest/Schema/Year2000CDs.pm +++ b/t/lib/DBICTest/Schema/Year2000CDs.pm @@ -11,7 +11,7 @@ __PACKAGE__->table('year2000cds'); # need to operate on the instance for things to work __PACKAGE__->result_source_instance->view_definition( sprintf ( - 'SELECT %s FROM cd WHERE year = "2000"', + 'SELECT %s FROM cd WHERE year = \'2000\'', join (', ', __PACKAGE__->columns), )); diff --git a/t/lib/sqlite.sql b/t/lib/sqlite.sql index 30ffbee..5db7aa1 100644 --- a/t/lib/sqlite.sql +++ b/t/lib/sqlite.sql @@ -372,4 +372,4 @@ CREATE INDEX "fourkeys_to_twokeys_idx_f_foo_f_bar_f_hello_f_goodbye" ON "fourkey CREATE INDEX "fourkeys_to_twokeys_idx_t_artist_t_cd" ON "fourkeys_to_twokeys" ("t_artist", "t_cd"); CREATE VIEW "year2000cds" AS - SELECT cdid, artist, title, year, genreid, single_track FROM cd WHERE year = "2000"; + SELECT cdid, artist, title, year, genreid, single_track FROM cd WHERE year = '2000';