The Perl Toolchain Summit needs more sponsors. If your company depends on Perl, please support this very important event.

NAME

MySQL::Workbench::Parser::Column - A column of the ER model

VERSION

version 1.10

METHODS

as_hash

return info about a column as a hash

    my %info = $column->as_hash;

returns

    (
        name          => 'id',
        datatype      => 'INT',
        length        => '',
        precision     => '0',
        not_null      => '1',
        autoincrement => '1',
        default_value => '',
    )

as_string

Returns a stringified version of the column information

    (
        name          => 'id',
        datatype      => 'INT',
        length        => '',
        precision     => '0',
        not_null      => '1',
        autoincrement => '1',
        default_value => '',
    )

returns

    id INT NOT NULL AUTOINCREMENT

ATTRIBUTES

  • autoincrement

  • comment

  • datatype

  • default_value

  • flags

    Any extra flags like binary, unsigned and/or zerofill.

  • id

  • length

  • name

  • node

  • not_null

  • precision

  • table

  • type_info

    More information about the datatype:

    • args

      The length, precision or a list of possible values (for enums).

    • gui_name

      The column type as shown in Workbench. For user defined types it is the label shown in the dropdowns.

    • length

      E.g. for VARCHAR columns, the max length of the value

    • name

      The SQL definition name. For user defined types, this is the underlying data type.

    • precision

MISC

BUILD

AUTHOR

Renee Baecker <reneeb@cpan.org>

COPYRIGHT AND LICENSE

This software is Copyright (c) 2018 by Renee Baecker.

This is free software, licensed under:

  The Artistic License 2.0 (GPL Compatible)