I want to do unit testing by using an in-memory SQLite database (Zend_Db
with Adapter "Pdo_Sqlite" and 'dbname' => ':memory:'). For the moment, I
create the tables, triggers etc. by hand with $db->query() when starting the
test suite. As you can imagine, this is not the way to go from a
maintainability perspective. As there is no method to import .sql-files and
it is seemingly not possible to get the SQLite command ".read" working with
Zend_Db, how do you tackle this issue?
exec() and system() may not be an option everywhere. Is there no other way
than parsing the .sql-file with the create commands and execute every single
query seperately?
Thanks in advance,
Matthias
--
View this message in context: http://www.nabble.com/Import-SQL-dump-to-in-memory-SQLite-database-tp22375788p22375788.html
Sent from the Zend DB mailing list archive at Nabble.com.
没有评论:
发表评论