TextResultSetParser converts a text result set to a data struct like DBI::selectall_arrayref(). Text result sets are like what SHOW PROCESSLIST and EXPLAIN print, like:
+----+------+
Id | User |
+----+------+
1 | bob |
+----+------+
[ { Id => '1', User => 'bob', }, ]
Both horizontal and vertical (\G) text outputs are supported.
TextResultSetParser | TextResultSetParser converts a text result set to a data struct like DBI::selectall_arrayref(). |
Functions | |
new | |
_pasre_tabular | Parse a line from tabular horizontal output. |
_parse_tabular | |
_pasre_tabular | Parse a line from tab-separated horizontal output. |
_parse_tab_sep | |
parse_vertical_row | Parse records split from vertical output by split_vertical_rows(). |
parse | Parse a text result set. |
parse_horizontal_row | Parse rows from horizontal output (regular MySQL style output). |
parse_horizontal_row | Split records in vertical output (\G style output). |
split_vertical_rows | |
_d |
Parse a line from tabular horizontal output.
$text | Text row from horizontal output, split in parse_horizontal_rows() |
@cols | Column names that text rows are organized by |
A record hashref
Parse a line from tab-separated horizontal output.
$text | Text row from horizontal output, split in parse_horizontal_rows() |
@cols | Column names that text rows are organized by |
A record hashref
sub parse_vertical_row
Parse records split from vertical output by split_vertical_rows().
$text | Text record |
A record hashref
Split records in vertical output (\G style output).
$text | Text result set |
Array of text records, parsed by parse_vertical_row().
sub new
sub _parse_tabular
sub _parse_tab_sep
Parse records split from vertical output by split_vertical_rows().
sub parse_vertical_row
sub split_vertical_rows
Parse a text result set.
sub parse
Parse rows from horizontal output (regular MySQL style output).
sub parse_horizontal_row
sub _d