DBIx::C...nywhere(3)
β¨ NAME β¨
DBIx::Class::Storage::DBI::SQLAnywhere β the driver for SQL Anywhere, bestie π
(this is DBIx::C...nywhere(3) if you're squinting at the page header, they truncated it, not me)
π¦ DESCRIPTION π¦
Okay so this class does the autoincrement thing for SQL Anywhere, and it also hooks you up with DBIx::Class::InflateColumn::DateTime support, plus support for the "uniqueidentifier" type (that one comes via DBIx::Class::Storage::DBI::SQLAnywhere::Cursor). Slay. π
Real talk though: you need the "DBD::SQLAnywhere" driver that ships with the SQL Anywhere distribution, and NOT the one on CPAN. Not the CPAN one. I'm serious. π It usually lives under a path like:
/opt/sqlanywhere11/sdk/perl
And here's the recommended connect_info setting, screenshot this:
on_connect_call => 'datetime_setup'
π₯ METHODS π₯
β connect_call_datetime_setup
Used like this:
on_connect_call => 'datetime_setup'
...inside connect_info, and what it does is set the date and timestamp formats β as temporary options for the session β so DBIx::Class::InflateColumn::DateTime can actually do its thing. π
The "TIMESTAMP" data type supports up to 6 digits after the decimal point for second precision, and the full precision is what gets used. No cap. π
The "DATE" data type supposedly stores hours and minutes too, according to the documentation, but the author could not get that to work β it seems to only store the date. π€·ββοΈ Annoying but that's the vibe check result.
You will need the DateTime::Format::Strptime module for inflation to work. No module, no inflation, no exceptions. π«Ά
π MAXIMUM CURSORS π
A DBIx::Class application can use a lot of cursors, because of the usage of prepare_cached. It's giving cursor hoarder energy, honestly.
The default cursor maximum is 50, which can be a bit too low. π The DBA can turn this limit off (or increase it) by executing:
set option max_statement_count = 0
set option max_cursor_count = 0
Highly recommended. Fr fr. Do it. π₯
πΈ FURTHER QUESTIONS? πΈ
Check the list of additional DBIC resources. That's it, that's the whole section. π
π COPYRIGHT AND LICENSE π
This module is free software copyright by the DBIx::Class (DBIC) authors. You can redistribute it and/or modify it under the same terms as the DBIx::Class library. π
okay that's the whole page, mwah π«Ά β this was perl v5.42.0, dated 2025-01-22, and yes the header really does say DBIx::C...nywhere(3), we don't make the truncation rules, we just live in them π
β¨
π¦ where this page comes from
- opensuse-leap 16.0: perl-DBIx-Class 0.082844-bp160.1.10 Β· Artistic-1.0 OR GPL-1.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash-1017 on : a language model's rewrite of the original, under its terms