Debugging/trace output control. Allows redirection to different filehandle, more...
[dbsrgits/DBIx-Class.git] / lib / DBIx / Class / Manual / Troubleshooting.pod
1 =head1 NAME
2
3 DBIx::Class::Manual::Troubleshooting - Got a problem? Shoot it.
4
5 =head2  "Can't locate storage blabla"
6
7 =head2 Tracing SQL
8
9 The C<DBIX_CLASS_STORAGE_DBI_DEBUG> environment variable controls
10 SQL tracing, so to see what is happening try
11
12   export DBIX_CLASS_STORAGE_DBI_DEBUG=1
13
14 Alternatively use the C<storage->debug> class method:-
15
16   $class->storage->debug(1);
17
18 To send the output somewhere else set debugfh:-
19
20   $class->storage->debugfh(IO::File->new('/tmp/trace.out', 'w');
21
22 Alternatively you can do this with the environment variable too:-
23
24   export DBIX_CLASS_STORAGE_DBI_DEBUG="1=/tmp/trace.out"
25
26 =cut
27