NAME

DBIO::Storage::Debug::PrettyTrace - Pretty Tracing DebugObj

VERSION

version 0.900000

SYNOPSIS

DBIO_TRACE_PROFILE=~/dbio.json perl -Ilib ./foo.pl

Where dbio.json contains:

{
  "profile":"console",
  "show_progress":1,
  "squash_repeats":1
}

METHODS

new

my $pp = DBIO::Storage::Debug::PrettyTrace->new({
  show_progress  => 1,             # tries it's best to make it clear that a SQL
                                   # statement is still running
  executing      => '...',         # the string that is added to the end of SQL
                                   # if show_progress is on.  You probably don't
                                   # need to set this
  clear_line     => '<CR><ESC>[J', # the string used to erase the string added
                                   # to SQL if show_progress is on.  Again, the
                                   # default is probably good enough.

  squash_repeats => 1,             # set to true to make repeated SQL queries
                                   # be ellided and only show the new bind params
  # any other args are passed through directly to SQL::Abstract::Tree
});

new

Constructs a pretty-trace statistics/debug object.

print

Formats SQL and bind values into a readable trace output line.

query_start

Emits a formatted trace line when SQL execution starts.

query_end

Cleans up progress marker output after SQL execution finishes.

AUTHOR

DBIO & DBIx::Class Authors

COPYRIGHT AND LICENSE

Copyright (C) 2026 DBIO Authors Portions Copyright (C) 2005-2025 DBIx::Class Authors Based on DBIx::Class, heavily modified.

This is free software; you can redistribute it and/or modify it under the same terms as the Perl 5 programming language system itself.