CPAN::...pulate(3pm)
π CPAN::SQLite::Populate π
okay bestie, gather round, because this is the CPAN::SQLite::Populate page from the 3pm manual section and it is literally the database-building baddie of the CPAN::SQLite universe. no cap. π«Ά
β¨ VERSION β¨
version 0.220 β she's serving, she's current, she's iconic. π
πΈ DESCRIPTION πΈ
So basically this module has two jobs and she does both flawlessly: she creates the tables (but only if setup gets passed in as an option, okay? we don't do uninvited table-making here π
), and then she handles the inserting, updating, or deleting β whichever one is the moment β of all the relevant info from the indices of CPAN::SQLite::Info plus the state info from CPAN::SQLite::State.
How does she do it? Through the insert, update, and delete methods that live on each table. main character energy fr fr. β¨
π¨ IMPORTANT BESTIE ALERT π¨ the tables get created with thesetupargument that you pass into thenewmethod when you're making theCPAN::SQLite::Indexobject. and likeβ¦ existing tables? they get dropped. gone. bye. π so know what you're doing before you pass that.
π TABLES π
Here's the rundown on every table β the data types shown are the mysql</> ones, with the corresponding adjustments made if you're on a SQLite database instead. iykyk. π¦
π§ mods
This one holds all the module info, and she gets created like this:
mod_id INTEGER NOT NULL PRIMARY KEY
mod_name VARCHAR(100) NOT NULL
dist_id INTEGER NOT NULL
mod_abs TEXT
mod_vers VARCHAR(10)
mod_idβ this is the primary (unique) key of the table. the one and only. πdist_idβ this key matches up with the id of the associated distribution over in thediststable.mod_nameβ the module's name. yeah that's it, that's the vibe.mod_absβ a description of the module, if there's one available. lowkey optional, highkey useful. β¨mod_versβ if it's present, this gives you the version of the module.
π dists
Distribution info lives here, and she's built like:
dist_id INTEGER NOT NULL PRIMARY KEY
dist_name VARCHAR(90) NOT NULL
auth_id INTEGER NOT NULL
dist_file VARCHAR(110) NOT NULL
dist_vers VARCHAR(20)
dist_abs TEXT
dist_idβ the primary (unique) key of the table. iconic behavior. πauth_idβ this one corresponds to the CPAN author id of the distribution, which lives over in theauthstable.dist_nameβ this is the distribution name. like, forMy-Distname-0.22.tar.gz,dist_nameis gonna beMy-Distname. see how that works? πdist_fileβ this corresponds to the CPAN file name.dist_versβ the version of the CPAN file. forMy-Distname-0.22.tar.gz,dist_versis0.22. math is mathing. β¨dist_absβ a description of the distribution. and if one wasn't directly supplied, then the description for, like,Foo::Bar(if present) gets used for theFoo-Bardistribution. recycling queen. π§
π auths
CPAN author info goes here, and she's created as:
auth_id INTEGER NOT NULL PRIMARY KEY
cpanid VARCHAR(20) NOT NULL
fullname VARCHAR(40) NOT NULL
email TEXT
auth_idβ the primary (unique) key of the table, periodt.cpanidβ gives you the CPAN author id.fullnameβ the full name of the author. πemailβ the email address the author supplied. π
π₯ SEE ALSO π₯
CPAN::SQLite::Indexβ go read that one next bestie, they're a set π«Ά
and that's the whole page, you ate it, no crumbs π β¨
this was CPAN::SQLite::Populate, version 0.220, living in the 3pm manual section β the perl she was documented under was perl v5.36.0, and the date on the whole thing was 2022-10-30. thanks for coming to my ted talk, mwah ππ
π¦ where this page comes from
- debian bookworm: libcpan-sqlite-perl 0.220-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- debian trixie: libcpan-sqlite-perl 0.220-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu noble: libcpan-sqlite-perl 0.220-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libcpan-sqlite-perl 0.220-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libcpan-sqlite-perl 0.220-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms