DBSchema::Index(3pm)
π DBSchema::Index π
okay bestie so this is a page from the User Contributed Perl Documentation, and it's literally about DBIx::DBSchema::Index β the little object that holds one single database index. slay.
β¨ NAME β¨
DBIx::DBSchema::Index β Index objects. that's it. that's the whole vibe. π
π¦ SYNOPSYS π¦
(it's spelled like that in the original, don't @ me π) here's the whole thing verbatim, no notes:
use DBIx::DBSchema::Index;
$index = new DBIx::DBSchema::Index (
{
}
);
iconic. empty hashref. main character energy. π
πΈ DESCRIPTION πΈ
so like, a DBIx::DBSchema::Index object represents a unique or non-unique database index. that's literally the whole job. it's giving very focused, very demure, very mindful. π«Ά
π METHODS π
new HASHREF | OPTION, VALUE, ...
Creates a new DBIx::DBschema::Index object. β¨
ngl it's flexible β it accepts either a hashref or a list of options and values. your choice, bestie, both are valid. π
the options are:
nameβ Index nameusingβ Optional index methoduniqueβ Boolean indicating whether or not this is a unique index.columnsβ List reference of column names (or expressions)
name [ INDEX_NAME ]
Returns or sets the index name. renaming? slay. π
using [ INDEX_METHOD ]
Returns or sets the optional index method. (optional optional, we love a low-commitment queen.) π
unique [ BOOL ]
Returns or sets the unique flag. yes/no, iconic behavior only. π₯
columns [ LISTREF ]
Returns or sets the indexed columns (or expressions). expressions?? we love a flexible listref. π¦
columns_sql
Returns a comma-joined list of columns, suitable for an SQL statement. she's ready for the group project fr fr. π
sql_create_index TABLENAME
Returns an SQL statment to create this index on the specified table. give her a table name and she's off. β¨
(yes, "statment" β that's the original's spelling, keeping it exact, no cap. π)
cmp OTHER_INDEX_OBJECT
Compares this object to another supplied object. Returns true if they are identical, or false otherwise. full-on twin check. π
cmp_noname OTHER_INDEX_OBJECT
Compares this object to another supplied object. Returns true if they are identical, disregarding index name, or false otherwise. same energy, name excluded, we don't care what she's called. π«Ά
π AUTHOR π
Ivan Kohler <ivan-dbix-dbschema@420.am>
Copyright (c) 2007 Ivan Kohler Copyright (c) 2007 Freeside Internet Services, Inc. All rights reserved. This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
(so like β legally speaking, same terms as Perl itself. free software bestie behavior. π)
π BUGS π
Is there any situation in which sql_create_index needs to return a list of multiple statements?
genuinely asking. open question. if you know, you know (iykyk). π
π SEE ALSO π
DBIx::DBSchema::TableDBIx::DBSchemaDBI
go read those next, bestie, it's a whole cinematic universe. π§
okay that's the whole page!! this came from perl v5.36.0, dated 2022-09-10, and it belongs to DBSchema::Index(3pm). mwah, go build some indexes. π
β¨πΈ
π¦ where this page comes from
- ubuntu noble: libdbix-dbschema-perl 0.47-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu resolute: libdbix-dbschema-perl 0.47-1 Β· Artistic-1.0-Perl OR GPL-1.0-or-later
- ubuntu stonking: libdbix-dbschema-perl 0.47-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