{
    "mode": "perldoc",
    "parameter": "DBD::Mem",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/DBD%3A%3AMem/json",
    "generated": "2026-06-12T13:28:11Z",
    "synopsis": "use DBI;\n$dbh = DBI->connect('dbi:Mem:', undef, undef, {});\n$dbh = DBI->connect('dbi:Mem:', undef, undef, {RaiseError => 1});\n# or\n$dbh = DBI->connect('dbi:Mem:');\n$dbh = DBI->connect('DBI:Mem(RaiseError=1):');\nand other variations on connect() as shown in the DBI docs and <DBI::DBD::SqlEngine\nmetadata|DBI::DBD::SqlEngine/Metadata>.\nUse standard DBI prepare, execute, fetch, placeholders, etc., see \"QUICK START\" for an example.",
    "sections": {
        "NAME": {
            "content": "DBD::Mem - a DBI driver for Mem & MLMem files\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "use DBI;\n$dbh = DBI->connect('dbi:Mem:', undef, undef, {});\n$dbh = DBI->connect('dbi:Mem:', undef, undef, {RaiseError => 1});\n\n# or\n$dbh = DBI->connect('dbi:Mem:');\n$dbh = DBI->connect('DBI:Mem(RaiseError=1):');\n\nand other variations on connect() as shown in the DBI docs and <DBI::DBD::SqlEngine\nmetadata|DBI::DBD::SqlEngine/Metadata>.\n\nUse standard DBI prepare, execute, fetch, placeholders, etc., see \"QUICK START\" for an example.\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "DBD::Mem is a database management system that works right out of the box. If you have a standard\ninstallation of Perl and DBI you can begin creating, accessing, and modifying simple database\ntables without any further modules. You can add other modules (e.g., SQL::Statement) for\nimproved functionality.\n\nDBD::Mem doesn't store any data persistently - all data has the lifetime of the instantiated\n$dbh. The main reason to use DBD::Mem is to use extended features of SQL::Statement where\ntemporary tables are required. One can use DBD::Mem to simulate \"VIEWS\" or sub-queries.\n\nBundling \"DBD::Mem\" with DBI will allow us further compatibility checks of DBI::DBD::SqlEngine\nbeyond the capabilities of DBD::File and DBD::DBM. This will ensure DBI provided basis for\ndrivers like DBD::AnyData2 or DBD::Amazon are better prepared and tested for not-file based\nbackends.\n",
            "subsections": [
                {
                    "name": "Metadata",
                    "content": "There're no new meta data introduced by \"DBD::Mem\". See \"Metadata\" in DBI::DBD::SqlEngine for\nfull description.\n\nGETTING HELP, MAKING SUGGESTIONS, AND REPORTING BUGS\nIf you need help installing or using DBD::Mem, please write to the DBI users mailing list at\n<mailto:dbi-users@perl.org> or to the comp.lang.perl.modules newsgroup on usenet. I cannot\nalways answer every question quickly but there are many on the mailing list or in the newsgroup\nwho can.\n\nDBD developers for DBD's which rely on DBI::DBD::SqlEngine or DBD::Mem or use one of them as an\nexample are suggested to join the DBI developers mailing list at <mailto:dbi-dev@perl.org> and\nstrongly encouraged to join our IRC channel at <irc://irc.perl.org/dbi>.\n\nIf you have suggestions, ideas for improvements, or bugs to report, please report a bug as\ndescribed in DBI. Do not mail any of the authors directly, you might not get an answer.\n\nWhen reporting bugs, please send the output of \"$dbh->memversions($table)\" for a table that\nexhibits the bug and as small a sample as you can make of the code that produces the bug. And of\ncourse, patches are welcome, too :-).\n\nIf you need enhancements quickly, you can get commercial support as described at\n<http://dbi.perl.org/support/> or you can contact Jens Rehsack at rehsack@cpan.org for\ncommercial support.\n"
                }
            ]
        },
        "AUTHOR AND COPYRIGHT": {
            "content": "This module is written by Jens Rehsack < rehsack AT cpan.org >.\n\nCopyright (c) 2016- by Jens Rehsack, all rights reserved.\n\nYou may freely distribute and/or modify this module under the terms of either the GNU General\nPublic License (GPL) or the Artistic License, as specified in the Perl README file.\n",
            "subsections": []
        },
        "SEE ALSO": {
            "content": "DBI for the Database interface of the Perl Programming Language.\n\nSQL::Statement and DBI::SQL::Nano for the available SQL engines.\n\nSQL::Statement::RAM where the implementation is shamelessly stolen from to allow DBI bundled\nPure-Perl drivers increase the test coverage.\n\nDBD::SQLite using \"dbname=:memory:\" for an incredible fast in-memory database engine.\n",
            "subsections": []
        }
    },
    "summary": "DBD::Mem - a DBI driver for Mem & MLMem files",
    "flags": [],
    "examples": [],
    "see_also": []
}