[Bast-commits] r9789 - SQL-Abstract/1.x/trunk/examples

frew at dev.catalyst.perl.org frew at dev.catalyst.perl.org
Sat Oct 23 21:04:36 GMT 2010


Author: frew
Date: 2010-10-23 21:04:36 +0000 (Sat, 23 Oct 2010)
New Revision: 9789

Added:
   SQL-Abstract/1.x/trunk/examples/dbic-console.pl
Log:
try DBIC colorizer!

Added: SQL-Abstract/1.x/trunk/examples/dbic-console.pl
===================================================================
--- SQL-Abstract/1.x/trunk/examples/dbic-console.pl	                        (rev 0)
+++ SQL-Abstract/1.x/trunk/examples/dbic-console.pl	2010-10-23 21:04:36 UTC (rev 9789)
@@ -0,0 +1,15 @@
+#!/sur/bin/env perl
+
+use DBIx::Class::Storage::Debug::PrettyPrint;
+
+my $pp = DBIx::Class::Storage::Debug::PrettyPrint->new({
+   profile => 'console',
+   show_progress => 0,
+});
+
+$pp->txn_begin;
+$pp->query_start("SELECT a, b, c FROM foo WHERE foo.a =1 and foo.b LIKE ?", q('station'));
+sleep 1;
+$pp->query_end("SELECT a, b, c FROM foo WHERE foo.a =1 and foo.b LIKE ?", q('station'));
+$pp->txn_commit;
+




More information about the Bast-commits mailing list