On Tue, 19 Sep 2006 [EMAIL PROTECTED] wrote:
And some drivers have a "timeout" parameter that handles this issue at the
vendor API level (e.g. DBD::Sybase's "timeout" parameter that is handled
internally by OpenClient).
Good to know. I'm looking into adding something like this to MySQL,
but d
On Sun, 17 Sep 2006, Dean Arnold wrote:
Er, but how ? Unless/until the DBI is threadsafe, the only way
for kill_session() to work is by breaking the DBD out of the
current blocking request. Which I assume is to be accomplished
by throwing signals around ?
DBIx::Timeout uses a separate fork()ed
Hey guys. This one has bitten me one too many times. Given this
table:
CREATE TABLE foo (
foo_id INT,
barVARCHAR(255)
);
This prepare() and execute() produces a very helpful warning:
my $sth = $dbh->prepare("INSERT INTO foo VALUES (?,?)");
$sth->execute(1, "test 1", "t
On Mon, 31 Oct 2005 [EMAIL PROTECTED] wrote:
Hi,
sorry to bother you again.
I am still trying to load data in my db2 database using class-dbi in a
perl script.
I am blocked on the dbi set_up_table function called in my script:
Chado::Tableinfo->set_up_table('tableinfo');
There are the wrong ma
On Tue, 5 Jul 2005, Ronald J Kimball wrote:
> Total Contributions: $1320.25
>
> I suggest you go back and reread Tim's email. What he said was that he
> donated a little over $500 himself, not that the total raised was $500.
That's good to know. It doesn't really alter my assessment though -
t
On Sat, 2 Jul 2005, Dean Arnold wrote:
> >
> > Relax. I'm just suggesting that Tim not talk about a fund drive that
> > more-or-less failed when trying to drum up volunteers for the new
> > project. It will be obvious to everyone who reads this that $500
> > isn't enough to help in a significan
On Sat, 2 Jul 2005, Dean Arnold wrote:
> Er, marketting in what way ?
I see the email as an attempt to attract new developers to the
project. Hence it is, in some respects, an attempt to "market" DBI v2
to developers.
> Developing DBI/DBDs costs time & resources. Many major for-profit
> orgs a
On Fri, 1 Jul 2005, Tim Bunce wrote:
> Once upon a time I said:
>
>
> http://groups-beta.google.com/group/perl.dbi.users/msg/caf189d7b404a003?dmode=source&hl=en
>
Minor note: these URLs are too long to easily copy and paste. Maybe
use a URL shortening sevrice like tinyurl.com.
> I've not d
Here's a revised version of the ChildHandles patch. I think I've
implemented all the requested changes. I also added an implementation
of Type for DBI::PurePerl which was missing.
-samdiff -Naur DBI-1.48.orig/DBI.pm DBI-1.48/DBI.pm
--- DBI-1.48.orig/DBI.pm2005-03-14 11:45:38.0 -0
On Mon, 27 Jun 2005, Tim Bunce wrote:
> Idea: I was wrong :) Adding ChildHandles to the list of attributes in
> the attribute get code in DBI.xs is the right thing to do.
Ok.
> Did my one-liner not work?
>
> @$ch = grep { $_ } @$ch if @$ch % 120 == 0 && @$ch;
>
> It's much smalle
On Thu, 23 Jun 2005, Sam Tregar wrote:
> That looks do-able. I'll try to work up a patch in the next couple
> days. I'll include the DBI->installed_drivers() method as well, if
> that's ok.
Here it is. I've implemented a ChildHandles attribute and the
installed
On Thu, 23 Jun 2005, Tim Bunce wrote:
> For a driver handle the children are the database handles.
> For a database handle the children are the statement handles.
> $h->{ChildHandles} gives you the children of that handle.
>
> Does that make sense?
Yes it does. Sorry, I should have removed that
On Wed, 22 Jun 2005, Tim Bunce wrote:
> I'd rather go with ChildHandles as per the outline in my previous email.
If you insist. I don't understand the use of "child" here. What is
the "parent"?
> Your patch uses a global $DBI::active_handles which will grow
> without bound.
It is bounded by t
Here's my first pass at an ActiveHandles attribute. With this patch
this code prints all live handles:
foreach my $handle (@{$dbh->{ActiveHandles}}) {
next unless defined $handle;
print $handle, "\n";
}
I'd like to take the next step and add a DBI->ActiveHandles call to do
On Tue, 21 Jun 2005, Tim Bunce wrote:
> > $handles = DBI->ChildHandles();
>
> $drh = DBI->install_driver('mysql');
> $all_mysql_dbh = $drh->{ChildHandles};
>
> (install_driver doesn't reinstall the driver if it's already loaded)
Can I do that if I don't know which driver is alread
On Mon, 20 Jun 2005, Tim Bunce wrote:
> > Can you suggest a good
> > place to put the code to collect open handles? Knowing nothing about
> > the internals I'm guessing connect() is the right spot.
>
> Actually _new_handle() in DBI.pm
>
> But first we need an API. A reasonable first draft would
On Wed, 15 Jun 2005, Tim Bunce wrote:
> Doesn't this work already:
>
> $dbh->{Profile} = DBI::ProfileDumper->new( File => 'dbi.prof' );
>
> Assigning a new value to $dbh->{Profile} would DESTROY the old one
> (flushing it to disk in the process).
Yes, I think it would. However, I only have
Hello all. I'm working on a project to produce a graphical frontend
for DBI::ProfileDumper for use with CGI::Application called
CGI::Application::Plugin::DBIProfile. (Preview here:
http://sam.tregar.com/dbiprof_progress.png)
Things are working fine in mod_cgi but mod_perl is another story. The
On Sun, 12 Jun 2005, Tim Bunce wrote:
> Thanks, applied. Change 1079.
>
> Any chance you could patch a test into t/41prof_dump.t?
Done. Without the prior patch the new test causes:
Invalid Profile data leaf element at depth 1: HASH (type 11) at
t/41prof_dump.t line 45.
# Looks like you p
On Sun, 12 Jun 2005, Sam Tregar wrote:
> So the question is, what is assigning an empty array to {Path}?
Of course right after sending the message I figured it out.
DBI::ProfileDumper was assuming that $profile->{Path} would always
contain an array-ref and it was auto-vivifying that has
On Tue, 7 Jun 2005, Tim Bunce wrote:
> No bells here. Keep digging!
I feel like I'm getting closer. It's not actually the case that
$dbh->{Profile}->{Data} contains a rogue empty hash, it's that
$dbh->{Profile}->{Path} gets assigned a ref to an empty array. This
causes the code in dbi_profile t
Hello all. I've been playing with DBI::ProfileDumper again and I've
been experiencing an odd error. At first I thought it was something
happening in my application but then I got the same error from a very
different app (one uses Class::DBI and lots of magic, the other is a
straight-forward DBI a
The attached patch fixes two bugs in my code spotted by Tim. First, the
unescaping of keys with literal '\n' and '\r' in DBI::ProfileData was
broken. Second, the broken test marked "XXX fix me" in t/42prof_data.t
has been repaired. It was using the count field as an identifier for the
record whe
On Thu, 21 Nov 2002, Tim Bunce wrote:
> DBI::Profile changes:
> Setup fixes thanks to Sam Tregar.
> Added $DBI::err (etc) tied variable lookup time to profile
> Added time for DESTROY method into parent handles profile (used to be ignored)
Do you think DBI::ProfileDu
exclude all prepare entries where key2 is the method name:
+
+ dbi_prof --exclude key2=prepare
+
+Like C<--match>, If the value given starts and ends with slashes
+(C) then it will be treated as a regular expression. For example,
+to exclude UPDATE queries where key1 is the statement:
On Tue, 15 Oct 2002, Henri Asseily wrote:
> In the case of db profiling, I tell it to overload DBI::st::execute
> with a profiling method that does the following:
The DBI::Profile interface actually profiles every DBI method, connect(),
prepare(), execute(), fetch() and everything in-between. A
On Wed, 9 Oct 2002, Tim Bunce wrote:
> I'd guess it's related to the connect.
> Try it with DBI_PROFILE=6.
Here's what I get:
DBI::Profile: 0.00 seconds 0.18% (10 method calls) prof_test.pl
'' =>
'FETCH' =>
0.51s / 2 = 0.26s avg (first 0.10s, min 0.10s, m
This script called prof_test.pl:
use DBI;
my $dbh = DBI->connect("dbi:ExampleP:", '', '', { });
my $sth = $dbh->prepare("SELECT * FROM ?");
$sth->execute(".");
$sth->finish();
Produces this output with DBI_PROFILE set to 2:
$ DBI_PROFILE=2 perl prof_test.pl
DBI::Profile: 0.001105
On Sun, 6 Oct 2002, Tim Bunce wrote:
> Quick thought, add an option to "abstract" the SQL using code like
> this (copied from an app that does something vaguely similar):
Sounds good to me. This also makes me think of the SQL pretty-printer I
wrote for the Bricolage DBI profiler. I might take
On Sun, 6 Oct 2002, Tim Bunce wrote:
> > =head1 USAGE
> >
> > The normal way to use this module is just to enable it in your C<$dbh>:
> >
> > $dbh->{Profile} = "DBI::ProfileDumper";
>
> I'd suggest you suggest that people use the DBI_PROFILE env var.
Ok. I'll also include that in a DBI::Profi
Here is the POD for the proposed dbi_prof script. I've put off
designing the interface for DBI::ProfileData for the moment. It should be
easier to accomplish once the desired functionality in dbi_prof is decided
upon.
-sam
=head1 NAME
dbi_prof - command-line client for DBI::ProfileData
=hea
Here is my proposed interface for DBI::ProfileDumper. Any and all
comments welcome. I would like to begin implementation on Monday, if
possible.
-sam
=head1 NAME
DBI::ProfileDumper - profile DBI usage and output data to a file
=head1 SYNOPSIS
use DBI;
# profile with default path (2) a
On Fri, 4 Oct 2002, Sam Tregar wrote:
> Attached is a new test suite for DBI::Profile.
Or not. Here it is inline with the message. Perhaps that will work.
-sam
#!perl -w
use strict;
#
# test script for DBI::Profile
#
# TODO:
#
# - fix dbi_profile, see below for test that produces a warn
Attached is a new test suite for DBI::Profile. I tried to cover all the
syntax found in the DBI::Profile documentation. This revealed what I
believe to be a bug. Calling:
dbi_profile($dbh, "Hi, mom", "fetchhash_bang", $t1, $t1 + 1);
Results in the warning:
Profile attribute isn't a has
The DBI::Profile docs say that these are all equivalent:
$h->{Profile} = {};
$h->{Profile} = "DBI::Profile";
$h->{Profile} = "2/DBI::Profile";
$h->{Profile} = 2;
However, the first fails to setup the default Path selection of 2 and the
second one causes an error:
Argument "DBI::Profil
35 matches
Mail list logo