Questions tagged [dbd]

DBD is a common prefix for all perl modules used as database drivers by the DBI module. These drivers hide the internals of different relational database management systems by providing a common API through the DBI module.

Access to relational databases in Perl is usually accomplished by the CPAN DBI module. See also DBI tag wiki entry.

DBI provides a common API for database access that uses separate drivers (DBD::*) internally to handle the specifics of different database management system implementations.

Some of the most popular DBD modules available on CPAN are:

DBD::MySQL
DBD::Oracle
DBD::Pg       (PostgreSQL)
DBD::ODBC
DBD::SQLite
DBD::Informix
DBD::Mock     (for testing purposes) 
DBD::CSV      (limited SQL access for CSV files)
DBD::JDBC
169 questions
0
votes
2 answers

What is the maximum NUM_OF_PARAMS in Perl DBI placeholders

What is the maximum number of placeholders is allowed in a single statement? I.e. the upper limit of attribute NUM_OF_PARAMS. I'm experiencing odd issue where I try to tune the maximum number of multiple rows insert, ie set the number to 20,000…
est
  • 557
  • 1
  • 4
  • 17
0
votes
1 answer

error in running cpanm --installdeps on ubuntu 18.04

I'm trying to intall defects4j on ubuntu 18.04. but when I run the command:cpanm --installdeps . I get errors on jason and DBD. faeze@ubuntu:~/defects4j$ cpanm --installdeps . --> Working on . Configuring /home/faeze/defects4j ... OK ==> Found…
faeze
  • 11
  • 1
0
votes
2 answers

Special character handling when fetching data from MS SQL Server using Perl DBD

I have an MS SQL Server 2008 Database, from which I am fetching data using perl DBD::Sybase module. But there are some special characters in the DB, like the Copyright symbol, Trademark symbol etc., which are not getting imported properly. Perl…
Hari Menon
  • 33,649
  • 14
  • 85
  • 108
0
votes
1 answer

Read all records from the database using call functions in ims

I want to write a batch program with IMS that can get all the records in the database. The structure of my database is as follows: a root segment and a segment below it that has several occurrences and another segment under the second segment that…
0
votes
0 answers

Does DBD::DB2 have an option to enable automatic decoding?

Does DBD::DB2 have a switch that performs automatic decoding from UTF-8, such as mysql_enable_utf8mb4 in DBD::mysql?
sid_com
  • 24,137
  • 26
  • 96
  • 187
0
votes
2 answers

Is there a bug with mysql's (or DBD's) handling of umlaute in a Primary Key?

I have something that I don't understand. Here is a piece of code: use warnings; use strict; my $db_name = 'xxx'; my $user = 'xxx'; my $pw = 'xxx'; use DBI; my $dbh = DBI->connect("DBI:mysql:$db_name", $user, $pw) || die "Could…
René Nyffenegger
  • 39,402
  • 33
  • 158
  • 293
0
votes
1 answer

Getting compilation error Can not load Mysql.pm in @INC

I am using RHEL 8 server where perl v5.26.0 has been installed. In my project there are lots of legacy perl modules who are using Mysql.pm as below. require 5.004; require Exporter; use Mysql; While compiling those modules, I am getting errors…
0
votes
1 answer

How to build DBD::mysql with DBI in a custom @INC?

I'm building DBI and DBD::mysql in a continuous integration build server. The build of DBI is successful, as seen in the excerpt of the build log below. It clearly installs DBI/DBD.pm in the correct location. pushd DBI-1.643 perl Makefile.PL…
Bill Karwin
  • 538,548
  • 86
  • 673
  • 828
0
votes
2 answers

DBD::mysql installation on Catalina/Big Sur fail with 'EXTERN.h' file not found?

I install DBD::mysql on Catalina preparing: perl Makefile.PL --testpassword=s3kr1t --testhost=localhost --testport 3306 --testuser=test --libs="-L/usr/local/opt/openssl/lib -lssl -lcrypto -L/usr/local/lib -L/usr/local/Cellar/mysql/8.0.12/lib…
Gerd
  • 2,265
  • 1
  • 27
  • 46
0
votes
0 answers

Ruby: Gem dbd-pg(0.3.9) not working with Ruby 2.7

I'm trying to migrate very old script to ruby 2.7, gem seems to be installed correctly but its throwing out error i am assuming that error is because the script is expecting PG gem version to be 0.9.0 but for some reason on ruby 2.7 this is version…
0
votes
1 answer

How to install DBD::Sybase in linux server

I am not able to install DBD::Sybase module using Makefile.PL in linux. It's showing error Please set the SYBASE in CONFIG, or set the $SYBASE environment variable I am not able to identify which path need to set for SYBASE env variable as I set…
0
votes
1 answer

Rewrite directory path based on authentication data

I'm trying to provide my users a unique directory under one common URL (https://example.com/sync). Previously I managed this with a rewrite rule which just appended the remote users name to the root directory for "sync". Now, the users login ID…
0
votes
1 answer

Can't call method "execute" on an undefined value at D:\ImageMark\opt\siips\classa\patches\alter_db.pl line 421

if ($insert_ver) { $sth = $dbh->prepare(qq| insert into db_change (database_version, script_name, run_date) values (?,?,?) |); $sth->execute("$SQLFILES{$serverType[$serverIndex]}{DBVERSION}[$fileIndex]", …
0
votes
2 answers

Perl DBI: uneven-number of bind variables with OR Statement (called with x bind variables when y are needed)

Definition of task: Fetch data from two different columns using OR. Problem: While its working with the plain (MySQL) query, Perl DBI throws an exception due to the uneven-number of bind variables. Let's assume the following DB schema: customer …
HRitter
  • 183
  • 1
  • 6
0
votes
3 answers

Executing DB2 commands '' db2start: command not found ''

I have one virtual server running on centos7. I configure it for the Nagios monitoring tool. I created the config file etc. I have 9 DB instances. When I migrated the DB config file with Nagios(adding to the Nagios ) I saw this error code on…