Re: Cycling through open handles

2005-06-21 Thread Tim Bunce
On Mon, Jun 20, 2005 at 08:27:57PM -0400, Sam Tregar wrote: > On Tue, 21 Jun 2005, Tim Bunce wrote: > > > > $handles = DBI->ChildHandles(); > > > > $drh = DBI->install_driver('mysql'); > > $all_mysql_dbh = $drh->{ChildHandles}; >

Makefile.PL problems on windows

2005-06-21 Thread Tim Bunce
I'd appreciate it if someone could look into why sometimes Makefile.PL fails on windows. There are four reports here http://testers.cpan.org/show/DBI.html#DBI-1.48 For example http://www.nntp.perl.org/group/perl.cpan.testers/204712 It's not consistent though, as there are reports of success as wel

Re: connected() doesn't get all attributes

2005-06-21 Thread Tim Bunce
On Sun, Jun 19, 2005 at 06:16:25AM -0700, Peter Scott wrote: > On Sat, 18 Jun 2005 15:34:36 +0100, Tim Bunce wrote: > > > On Fri, Jun 17, 2005 at 05:49:01PM -0700, Peter Scott wrote: > >> The connected() method of subclasses doesn't get all the attribute > >> th

Re: Cycling through open handles

2005-06-21 Thread Tim Bunce
On Mon, Jun 20, 2005 at 01:38:42PM -0400, Sam Tregar wrote: > 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(

Re: connected() doesn't get all attributes

2005-06-18 Thread Tim Bunce
On Fri, Jun 17, 2005 at 05:49:01PM -0700, Peter Scott wrote: > The connected() method of subclasses doesn't get all the attribute > that were set by the caller; three of them are deleted first: > > DBI.pm: >643 foreach $a (qw(RaiseError PrintError AutoCommit)) { # do > the > se f

Re: RFC: New methods for DBI::ProfileDumper - reset() and File()

2005-06-15 Thread Tim Bunce
On Wed, Jun 15, 2005 at 02:15:51PM -0400, Sam Tregar wrote: > 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) > >

Re: Problem with Profile: invalid data leaf

2005-06-13 Thread Tim Bunce
Thanks, applied. Tim. On Sun, Jun 12, 2005 at 06:59:47PM -0400, Sam Tregar wrote: > 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 n

Re: Problem with Profile: invalid data leaf

2005-06-12 Thread Tim Bunce
Thanks, applied. Change 1079. Any chance you could patch a test into t/41prof_dump.t? Tim. On Sun, Jun 12, 2005 at 02:18:41AM -0400, Sam Tregar wrote: > On Sun, 12 Jun 2005, Sam Tregar wrote: > > > So the question is, what is assigning an empty array to {Path}? > > Of course right after sendin

Re: Problem with Profile: invalid data leaf

2005-06-08 Thread Tim Bunce
No bells here. Keep digging! Tim. On Tue, Jun 07, 2005 at 04:43:53PM -0400, Sam Tregar wrote: > 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 f

Re: PATCH: Segfault with selecting intervals

2005-06-07 Thread Tim Bunce
On Mon, Jun 06, 2005 at 10:48:56AM +0200, Honza Pazdziora wrote: > > which got me happy since it gives me the interval value alright. > > Please let me know if I should do some more tests for other rare > types of 10g. If you give me a hint how 10g-specific tests should be > done in t/*.t, I can

Re: ParamTypes attribute ?

2005-05-13 Thread Tim Bunce
Thanks, applied (reversed :) Tim. On Thu, May 12, 2005 at 12:43:42PM -0700, Dean Arnold wrote: > Tim Bunce wrote: > > > > > >Okay. You send, I'll apply. > > > >Thanks Dean! > > > >Tim. > > > > Here 'tis. (diff'd a

Re: ParamTypes attribute ?

2005-05-13 Thread Tim Bunce
On Thu, May 12, 2005 at 09:48:04AM -0700, Dean Arnold wrote: > Tim wrote: > > >> > >>[ NOTE TO TIM: Your note in the roadmap shows both the scalar and > >>hashref form of type info...in the interest of simplicity, I'd prefer > >>a single form (hashrefs); do you have a strong opinion one way > >>or

Re: PATCH: Consting & compiler pickiness in DBI

2005-04-12 Thread Tim Bunce
On Mon, Apr 11, 2005 at 01:42:48PM -0500, Andy Lester wrote: > On Mon, Apr 11, 2005 at 01:34:11PM -0400, Stas Bekman ([EMAIL PROTECTED]) > wrote: > > Tim Bunce wrote: > > [...] > > >I've applied the patch (change #970) and make a few tweaks. I needed to > &

Re: PATCH: Consting & compiler pickiness in DBI

2005-04-11 Thread Tim Bunce
On Mon, Apr 11, 2005 at 12:26:20PM +0200, H.Merijn Brand wrote: > On Mon, 11 Apr 2005 11:15:44 +0100, Tim Bunce <[EMAIL PROTECTED]> wrote: > > > On Sun, Apr 10, 2005 at 05:03:58PM -0500, Andy Lester wrote: > > > Attached is a patch that does for DBI what I've been

Re: PATCH: Consting & compiler pickiness in DBI

2005-04-11 Thread Tim Bunce
On Sun, Apr 10, 2005 at 05:03:58PM -0500, Andy Lester wrote: > Attached is a patch that does for DBI what I've been doing in the Perl > core the past few weeks: > > * Apply const qualifiers where possible > * Localize auto variables to internal blocks where possible > * Clean up complaints from hi

Re: one more issue with take_imp_data

2005-04-10 Thread Tim Bunce
On Sun, Apr 10, 2005 at 03:08:04PM -0400, Stas Bekman wrote: > Tim Bunce wrote: > >On Sat, Apr 09, 2005 at 01:08:40AM -0400, Stas Bekman wrote: > > > >>Tim, > >> > >>I've a pretty well working prototype now. There is one problem though. > >>

Re: one more issue with take_imp_data

2005-04-10 Thread Tim Bunce
On Sat, Apr 09, 2005 at 01:08:40AM -0400, Stas Bekman wrote: > Tim, > > I've a pretty well working prototype now. There is one problem though. > > Before take_imp_data can be called all $sth must be destroyed. for example > the following code: > > my $dbh = DBI->connect('dbi:mysql:test', ''

Re: [patch DBI.xs] dbi_imp_data

2005-04-10 Thread Tim Bunce
Thanks applied. Tim. On Fri, Apr 08, 2005 at 06:49:54PM -0400, Stas Bekman wrote: > this patch allows correctly handling magical imp_data scalars (which is > the case when a variable is coming from a thread::shared variable. > > Index: DBI.xs > ==

Re: Suppress warning when duplicates in @INC

2005-04-10 Thread Tim Bunce
Thanks, applied. Tim. On Sat, Apr 09, 2005 at 12:12:36PM +0100, Avis, Ed wrote: > DBI has a warning about multiple copies of Driver.xst found in @INC, but > this warning also fires when @INC has the same directory in it twice, > which isn't something to worry about. This patch quietens the warni

Re: Problem with bind_param using DBD::mysql

2005-04-07 Thread Tim Bunce
On Thu, Apr 07, 2005 at 09:21:19AM +0100, Steve Hay wrote: > Patrick Galbraith wrote: > > >As well, he said to avoid > >strcasencmp. I will take a look through the perl API to see if there is > >a similar function. > > > I couldn't see one at a quick glance. There are strnEQ and strnNE, but

Re: warning in dbi's svn build

2005-04-06 Thread Tim Bunce
Fixed in revision 959. Thanks. Tim. On Wed, Apr 06, 2005 at 10:15:15AM -0400, Stas Bekman wrote: > The svn of DBI has this warning: > > cc -c -D_REENTRANT -D_GNU_SOURCE -DTHREADS_HAVE_PIDS > -DDEBUG_LEAKING_SCALARS -DDEBUGGING -fno-strict-aliasing -pipe > -I/usr/local/include -D_LARGEFILE_SO

Re: Problem with bind_param using DBD::mysql

2005-04-06 Thread Tim Bunce
On Tue, Apr 05, 2005 at 07:27:10PM -0700, Patrick Galbraith wrote: > Tim, > > I have a fix to the emulated code that throws an error if you try to > bind a non-numeric value as a numeric - is this the desired behaviour? > I tested my fix, and it works fine, but perhaps you have pointers to > ma

Re: Problem with bind_param using DBD::mysql

2005-04-05 Thread Tim Bunce
On Tue, Apr 05, 2005 at 09:29:59AM +0100, Steve Hay wrote: > Stephen Clouse wrote: > >On Mon, Apr 04, 2005 at 03:41:56PM +0100, Steve Hay wrote: > > > >>Binding parameters: UPDATE foo SET str = 'one', num = 1.#INF WHERE > >>id = 1 > > > >You're being bitten by two things: > > > >1. MySQL doesn't a

Re: [patch] take_imp_data support for DBD::mysql

2005-03-30 Thread Tim Bunce
On Wed, Mar 30, 2005 at 11:02:12AM -0500, Stas Bekman wrote: > Tim Bunce wrote: > > > >The DBIc_ACTIVE_off isn't needed. In fact, looking at DBD::Mysql's > >struct imp_dbh_st, mysql_take_imp_data isn't needed at all. > >There's no 'preparation

Re: [patch DBI.xs] fix the take_imp_data case

2005-03-30 Thread Tim Bunce
On Tue, Mar 29, 2005 at 11:32:45PM -0500, Stas Bekman wrote: > Tim Bunce wrote: > >Still no time to dig, but it sounds like an tie inner vs outer issue. > >If you're using the outer handle then you'll need to mg_get() to fire > >FETCH. > >If that's not

Re: [patch] take_imp_data support for DBD::mysql

2005-03-30 Thread Tim Bunce
On Tue, Mar 29, 2005 at 11:46:26PM -0500, Stas Bekman wrote: > take_imp_data support for DBD::mysql. it seems to be too simple, The sign of a good solution... if it works :) > Index: lib/DBD/mysql.pm > -# Call msqlConnect func in mSQL.xs file > -# and populate internal handle data. > -

Re: [general] how to figure out the connection id?

2005-03-30 Thread Tim Bunce
On Tue, Mar 29, 2005 at 11:46:28PM -0500, Stas Bekman wrote: > In order to properly test take_imp_data implementation, one needs to be > able to test that when a second connect is issued and dbi_imp_data is > passed: > > my $dbh = DBI->connect($test_dsn, $test_user, $test_password, >

Re: Callback support is oin

2005-03-29 Thread Tim Bunce
On Tue, Mar 29, 2005 at 11:55:57AM -0800, David Wheeler wrote: > On Mar 29, 2005, at 2:39 AM, Tim Bunce wrote: > > >>Callbacks should only apply to the database handle, I think. > > > >I don't see any reason to limit them in that way. They already work > >for

Re: Callback support is oin

2005-03-29 Thread Tim Bunce
On Fri, Mar 25, 2005 at 03:06:56PM -0800, David Wheeler wrote: > > >>>1. callbacks are only passed the handle, not the other method args. > >> > >>That seems smart to me. If you passed it via method args (I assume you > >>mean \%attrs), then would it last only for the execution of that > >>method,

Re: Callback support is oin

2005-03-29 Thread Tim Bunce
On Sat, Mar 26, 2005 at 01:55:13AM +0100, Steven Schubiger wrote: > > On 23 Mar, Tim Bunce wrote: > > >>> >Any volunteers for any of those? > >>> > >>> Docs coming soon. > >> > >> Let's let Steven have a crack at the docs

Re: DBI::Pool

2005-03-29 Thread Tim Bunce
2005 at 06:03:12PM -0500, Stas Bekman wrote: > Tim Bunce wrote: > >I've no time to dig, but this works: > > > >$ perl -MDBI -wl -e 'print > >DBI->connect("dbi:Sponge:",undef,undef,{dbi_imp_data=>42})->{dbi_imp_data}' > >42 > &

Re: DBI::Pool

2005-03-28 Thread Tim Bunce
I've no time to dig, but this works: $ perl -MDBI -wl -e 'print DBI->connect("dbi:Sponge:",undef,undef,{dbi_imp_data=>42})->{dbi_imp_data}' 42 Tim. On Mon, Mar 28, 2005 at 05:09:21PM -0500, Stas Bekman wrote: > Stas Bekman wrote: > > Tim, connect() never uses "dbi_imp_data" attribute > > in DB

Re: DBI::Pool

2005-03-25 Thread Tim Bunce
On Fri, Mar 25, 2005 at 04:37:29PM -0500, Stas Bekman wrote: > > >>Should it be something like (and replace ??): > >> > >> SV *dbd_take_imp_data(SV *h, imp_xxh_t *imp_xxh, ?? ??) > > > >It can return a plain int as all it's doing is 'preparing' for > >the DBIs default take_imp_data to do the actua

Re: DBI::Pool

2005-03-25 Thread Tim Bunce
On Thu, Mar 24, 2005 at 02:36:51PM -0500, Stas Bekman wrote: > Also I'm not sure what was the intended prototype for dbd_take_imp_data? > All I see is: > > dbd_take_imp_data(h, imp_xxh, NULL) > > what's that NULL stand for? Probably just future-proofing-paranoia. > Should it be something lik

Re: Callback support is oin

2005-03-23 Thread Tim Bunce
On Tue, Mar 22, 2005 at 04:46:33PM -0800, David Wheeler wrote: > YES! :-) :) > On Mar 22, 2005, at 4:21 PM, Tim Bunce wrote: > > >The return; is because I've not decided how to interpret return values > >so to avoid problems later I've mandated that callbacks must

Re: Callback support is oin

2005-03-23 Thread Tim Bunce
On Wed, Mar 23, 2005 at 01:46:14AM +0100, Steven Schubiger wrote: > On 23 Mar, Tim Bunce wrote: > > > What's missing, roughly in order of importance... > > > > 0. Documentation. > > 1. callbacks are only passed the handle, not the other method args. > >

Callback support is oin

2005-03-22 Thread Tim Bunce
On Tue, Feb 22, 2005 at 09:12:00AM -0800, David Wheeler wrote: > > >That's great. You've got it to the point were I can't ignore it any > >more :-) I'll apply it and finish it up. > > Woo! That's what I was looking for! Time well spent, then. :-) I'll > have to look at the diff after you've don

Re: DBD::Sponge: When malloc throws in the sponge

2005-03-22 Thread Tim Bunce
On Tue, Mar 22, 2005 at 10:41:19AM +0100, Steffen Goeldner wrote: > Attached is a small benchmark script. The test platform is: > > The output looks like: > 47638 rows > Finally, let's use the new subroutine approach: > > my $rows = sub { > return if $rs->{EOF}; > my $row = [ map { $

Re: DBI 1.48: Warning: something's wrong at t/zvpp_11fetch.t line 3.

2005-03-16 Thread Tim Bunce
Ah, phooey. Guess I'll have to work on finishing the callbaks now ;) Thanks Steffen. Tim. On Wed, Mar 16, 2005 at 01:35:23PM +0100, Steffen Goeldner wrote: > Looks like t/11fetch.t should return a true value. > Patch attached. > > > Steffen > Index: t/11fetch.t > =

Re: DBD::Sponge: When malloc throws in the sponge

2005-03-16 Thread Tim Bunce
On Wed, Mar 16, 2005 at 01:13:00AM +0100, Steffen Goeldner wrote: > Currently, a result set has to be completely materialized > on the client before it can be fetched via DBD::Sponge: > Large result sets may exhaust available memory. We could > reduce memory usage at the cost of CPU time: > In DB

Re: Patch for fetchall_hashref with multiple column key

2005-03-14 Thread Tim Bunce
On Mon, Mar 14, 2005 at 12:52:57PM -0800, David Wheeler wrote: > On Mar 14, 2005, at 12:25 PM, Tim Bunce wrote: > > >DBI 1.48 is out now. I added a t/11fetch.t file with some basic tests. > >That's the one to patch. > > Aw, no callbacks yet? ;-) No, sorry

Re: Patch for fetchall_hashref with multiple column key

2005-03-14 Thread Tim Bunce
On Mon, Mar 14, 2005 at 10:06:51AM -0800, Zhuang Li wrote: > Sure, Tim. I'll do it as soon as I get a chance. DBI 1.48 is out now. I added a t/11fetch.t file with some basic tests. That's the one to patch. Tim. > Thanks, > > john > > > -Original Message---

Re: Patch for fetchall_hashref with multiple column key

2005-03-12 Thread Tim Bunce
Thanks John. Any chance you could add some tests in the relevant t/*.t file? [John has polished up the rough code I sketched out last January on dbi-dev in response to a request from Daniel Lewart.] Tim. On Thu, Mar 10, 2005 at 10:32:35AM -0800, Zhuang Li wrote: >I've made a patch to fetcha

Re: Savepoint support proposal

2005-03-10 Thread Tim Bunce
On Thu, Mar 10, 2005 at 10:54:37AM -, Martin J. Evans wrote: > > On 10-Mar-2005 Tim Bunce wrote: > > On Thu, Mar 10, 2005 at 08:54:54AM -, Martin J. Evans wrote: > >> > >> although ODBC does not define what happens if one of the commits on a > >>

Re: Savepoint support proposal

2005-03-10 Thread Tim Bunce
On Thu, Mar 10, 2005 at 08:54:54AM -, Martin J. Evans wrote: > > although ODBC does not define what happens if one of the commits on a > connection fails (this alone probably makes commiting on an environment > unpopular if used at all). Exactly. This (commit_all etc) won't make it into the D

Re: Savepoint support proposal

2005-03-10 Thread Tim Bunce
On Thu, Mar 10, 2005 at 04:45:06AM -, Greg Sabino Mullane wrote: > > > My position is that I'm open to being persuaded, but you'll have > > to put in the leg work. The best place for that at this stage is > > dbi-users as I'd like you to be able to show wider support for the > > proposals from

Re: Savepoint support proposal

2005-03-08 Thread Tim Bunce
On Mon, Mar 07, 2005 at 11:47:32PM -, Greg Sabino Mullane wrote: > > > While I don't have any particular objections, doesn't > > Pg (and most other DBMSs supporting savepoints) have > > SQL syntax to implement them ? If so, isn't just > > > > $dbh->do() > > > > sufficient ? > > Sure, but th

Re: patch for DBI 1.47

2005-03-07 Thread Tim Bunce
On Mon, Mar 07, 2005 at 01:24:43PM +0100, Jens Hinrichs wrote: > Hallo, > > in an older version of DBI (i think it was 1.43) there was an warning > in line 1317. > "Use of uninitialized value in concatencation (.) or string at..." > > in the 1.47 Version the bug is fixed in an (for me) unclean wa

Re: Savepoint support proposal

2005-03-07 Thread Tim Bunce
On Sun, Mar 06, 2005 at 08:41:01PM -0800, Dean Arnold wrote: > Greg Sabino Mullane wrote: > > > >We are working on implementing savepoint support in DBD::Pg, and > >someone pointed out (quite rightly) that perhaps there should be > >DBI method support for savepoints, as they are a standard SQL > >c

Re: [Fwd: Re: Handle Creation with new_child()]

2005-02-22 Thread Tim Bunce
On Mon, Feb 21, 2005 at 04:10:29PM -0800, David Wheeler wrote: > On Feb 21, 2005, at 2:17 PM, Tim Bunce wrote: > > >>Which is also pretty easily done, eh? Something like this? > > > >Yes, though I wouldn't bother validating the contents of the hash. > >Just

Re: new DBD::Yaswi

2005-02-21 Thread Tim Bunce
On Mon, Feb 21, 2005 at 05:23:47PM +, Salvador FandiƱo wrote: > Hi, > > I am working on a DBD backend for SWI-Prolog > (http://www.swi-prolog.org). As it runs on top of my module > Language::Prolog::Yaswi, I have called it DBD::Yaswi and I would > like to register it and the "yaswi_" prefix on

Re: [Fwd: Re: Handle Creation with new_child()]

2005-02-21 Thread Tim Bunce
[sorry for the delay] On Tue, Feb 15, 2005 at 10:32:52AM -0800, David Wheeler wrote: > On Feb 14, 2005, at 3:14 AM, Tim Bunce wrote: > > >In relation to connect_cached it boiled down to just the difference > >between: > > > > if ($dbh and my $oc = $dbh->{O

Re: Handle Creation with new_child()

2005-02-15 Thread Tim Bunce
On Tue, Feb 15, 2005 at 10:38:20AM -0800, David Wheeler wrote: > On Feb 14, 2005, at 3:09 AM, Tim Bunce wrote: > > >[On the roadmap/todo there's an item about recording the names of > >all attributes that have been set on a handle. That may also be > >useful here

Re: [Fwd: Re: Handle Creation with new_child()]

2005-02-14 Thread Tim Bunce
On Sun, Feb 13, 2005 at 05:48:26PM -0800, David Wheeler wrote: > On Feb 13, 2005, at 2:51 PM, Tim Bunce wrote: > > >>>Maybe the answer it to not allow changing attributes on a cached > >>>handle. > >> > >>That's already the rule and would not

Re: Handle Creation with new_child()

2005-02-14 Thread Tim Bunce
On Sun, Feb 13, 2005 at 05:54:40PM -0800, David Wheeler wrote: > On Feb 13, 2005, at 2:44 PM, Tim Bunce wrote: > > >The DBD::_::connect method then becomes just something like > > > > my $dbh = $drh->new_child($attr) or return; > > $dbh->connect

Re: DBI::DBD::Metadata: type_info_all

2005-02-13 Thread Tim Bunce
Thanks Steffen, applied. Tim. On Thu, Feb 10, 2005 at 11:59:38AM +0100, Steffen Goeldner wrote: > A DBI driver should pass the following tests: > > my @ti = $dbh->type_info; > ok( @ti,'type_info'); > > my $tia = $dbh->type_info_all; > is( ref $tia,'ARRAY','type_info_all'); > > my $id

Re: [Fwd: Re: Handle Creation with new_child()]

2005-02-13 Thread Tim Bunce
On Sun, Feb 13, 2005 at 09:31:19AM -0800, David Wheeler wrote: > On Feb 13, 2005, at 5:24 AM, Michael A Chase tech wrote: > > >Does a handle know its cached? No. > >Maybe the answer it to not allow changing attributes on a cached handle. > > That's already the rule and would not change. Er, th

Re: Handle Creation with new_child()

2005-02-13 Thread Tim Bunce
On Sat, Feb 12, 2005 at 04:35:40PM -0800, David Wheeler wrote: > On Feb 12, 2005, at 10:11 AM, Tim Bunce wrote: > > >>>That's starting to get might complex, isn't it? > >> > >>Uh, "mite". :-) > > > >Or "mighty", perhaps

Re: Callbacks

2005-02-12 Thread Tim Bunce
On Fri, Feb 11, 2005 at 11:18:34AM -0800, David Wheeler wrote: > On Feb 4, 2005, at 10:38 AM, David Wheeler wrote: > > >That's starting to get might complex, isn't it? > > Uh, "mite". :-) Or "mighty", perhaps. Tim.

Callbacks

2005-02-04 Thread Tim Bunce
On Thu, Feb 03, 2005 at 03:49:11PM -0800, David Wheeler wrote: > On Feb 3, 2005, at 3:30 PM, Tim Bunce wrote: > > >>Should be pretty straight-forward. Are there other events for which > >>you'd like to add callbacks? OnPrepare, perhaps? OnExecute? OnFetch? > >

DBI v2 - or not

2005-02-03 Thread Tim Bunce
On Thu, Feb 03, 2005 at 08:40:48AM -0800, David Wheeler wrote: > >That's planned for DBI v2, but it seems DBI v2 isn't going to happen > >anytime soon so I'm wondering if it's something I should squeeze > >into DBI v1. > > What's happened on the DBI v2 front? Nothing much. The call for funding wa

Re: AutoCommit and connect_cached()

2005-02-03 Thread Tim Bunce
On Thu, Feb 03, 2005 at 08:40:48AM -0800, David Wheeler wrote: > On Feb 3, 2005, at 7:45 AM, Tim Bunce wrote: > > >>+ my $no_reset = delete $attr->{NoReset}; > >> > >>+ %$attr = () if $no_reset; > >> > >>If this looks good to you, I

Re: AutoCommit and connect_cached()

2005-02-03 Thread Tim Bunce
On Wed, Feb 02, 2005 at 10:50:20AM -0800, David Wheeler wrote: > On Feb 2, 2005, at 2:59 AM, Tim Bunce wrote: > > Ah, I see. But loking at DBI::_::dr::connect_cached, it looks as though > connect() isn't called if it finds an active, pingable driver in the > cache. Tha

Re: problems building DBD::Oracle 1.16 - help - please

2005-02-03 Thread Tim Bunce
On Wed, Feb 02, 2005 at 10:20:32PM -0500, Adam Stoller wrote: > PREAMBLE: > This may be the wrong address to send this to, if so I appologize > and hope some kind soul will help direct me to whom/where I can > get some assistance. > And yes, I did read the README files - and I eith

Re: AutoCommit and connect_cached()

2005-02-02 Thread Tim Bunce
On Tue, Feb 01, 2005 at 09:16:49AM -0800, David Wheeler wrote: > On Feb 1, 2005, at 2:44 AM, Tim Bunce wrote: > > >Depends what you mean by wrong. I don't see any 'bugs' here. > > No, I wouldn't call it a bug, but it was unexpected behavior (for me

Re: AutoCommit and connect_cached()

2005-02-01 Thread Tim Bunce
On Mon, Jan 31, 2005 at 10:28:30PM -0800, David Wheeler wrote: > Fellow DBIers, > > This script reveals two issues, one with DBD::SQLite and one with the > DBI itself: > > #!/usr/bin/perl > > use strict; > > use DBI; > my $dbh = DBI->connect_cached('dbi:SQLite:dbname=test.db', {RaiseError > =

Re: [PATCH] Explain Trailing Spaces

2005-01-27 Thread Tim Bunce
Thanks, applied. Tim. On Wed, Jan 26, 2005 at 08:21:49PM -0500, Michael A Chase tech wrote: > Last month I answered questions twice in a week concerning trailing > spaces being removed in placholders and one of the questioners > referenced a message where I had answered the same question years

Re: [Full-Disclosure] [USN-70-1] Perl DBI module vulnerability

2005-01-25 Thread Tim Bunce
Many thanks for the notice Jonathan. I hadn't heard about it. I've patched the source and will make a release soon as I was preparing one anyway. For anyone worried about this it's very much "urgency=low", to quote their own changelog. But still, gott'a keep a clean slate... Tim. On Tue, Jan 25

Re: Proposing an API for the extension for simplifying database connections

2005-01-14 Thread Tim Bunce
On Fri, Jan 14, 2005 at 03:30:33PM -0600, David Nicol wrote: > wow I did not expect such negativity... See Yves Orton's dicsussion > on dbi-users > for what this does. I'm simply convinced of the correctness of the feature > and > proposing a low-impact way to fit it into the larger DBI pictur

Re: DBD::JDBC autoload/func implementation question

2005-01-14 Thread Tim Bunce
On Thu, Jan 13, 2005 at 04:04:57PM -0800, Gennis Emerson wrote: > I'm trying to get DBD::JDBC functional with the latest DBI release. Great. > Architecturally, it's a Perl DBD layer which marshals requests and sends > them to a Java server which then uses JDBC to talk to the underlying > databa

Re: DBD::JDBC prefix registration request

2005-01-14 Thread Tim Bunce
On Thu, Jan 13, 2005 at 03:17:28PM -0800, Gennis Emerson wrote: > Could the prefix jdbc_ be registered for DBD::JDBC? Done. Tim.

Re: JPL v/s Java Inline

2005-01-12 Thread Tim Bunce
On Wed, Jan 12, 2005 at 02:56:47PM +0530, Manoj Kumar wrote: > Hi, > > Would any one plz tell me what is difference between JPL and Java > Inline. Which one is best..? . This is not the right forum for such questions. The dbi-dev@perl.org list is for issues related to developing the Per

Re: How to call a java method in PERL

2005-01-11 Thread Tim Bunce
On Tue, Jan 11, 2005 at 02:46:46PM +0530, Manoj Kumar wrote: > I would like to know from Perl community , how to I give call > to a java method from perl . > > Thanks > > --mksheoran http://www.catb.org/~esr/faqs/smart-questions.html Tim.

Re: ANNOUNCE: DBD::Pg 1.40 release candidate 1 request for testing

2004-12-22 Thread Tim Bunce
On Tue, Dec 21, 2004 at 11:55:54PM -, Greg Sabino Mullane wrote: > > - Added $dbh->func($filehandle, 'server_trace') [Greg Sabino Mullane] Just a reminder: driver-private functions should have the drivers prefix pg_server_trace and, if they do, you can use the install_method

Re: DBI::DBD: attribute handling (outer/inner handles, $h->STORE vs. $h->{})

2004-12-17 Thread Tim Bunce
On Thu, Dec 16, 2004 at 10:58:35AM +0100, Steffen Goeldner wrote: > However, it's placed below the connect() method: > > > > > where we have an outer handle by way of an exception! > Instead of changing the

Re: DBI::DBD: Other statement methods

2004-12-17 Thread Tim Bunce
On Fri, Dec 17, 2004 at 02:15:57PM +0100, Steffen Goeldner wrote: > > P.S.: This was my last patch this year. Thanks, applied. > I wish all a Merry Christmas and a Happy New Year! Thanks Steffen. And many thanks for all your well-considered and well-presented patches. Tim.

Re: DBI::DBD: attribute handling (outer/inner handles, $h->STORE vs. $h->{})

2004-12-17 Thread Tim Bunce
Thanks, applied. On Fri, Dec 17, 2004 at 10:30:18AM +0100, Steffen Goeldner wrote: > > - sub rows { shift->FETCH('drv_rows') } > + sub rows { shift->{drv_rows} } I've added this note: The rows method for this driver can be implemented like this: sub rows { shift->{drv_rows} } because it

Re: DBD::ExampleP: attribute handling (outer/inner handles, $h->STORE vs. $h->{})

2004-12-17 Thread Tim Bunce
Thanks, applied. Tim. On Fri, Dec 17, 2004 at 11:33:24AM +0100, Steffen Goeldner wrote: > Changed DBD::ExampleP to reflect the recent changes to DBI::DBD. > > > Steffen > Index: lib/DBD/ExampleP.pm > === > --- lib/DBD/ExampleP.pm

Re: Re: Re: DBD::Pg vs Pg

2004-12-17 Thread Tim Bunce
On Thu, Dec 16, 2004 at 07:25:13PM -0500, Rudy Lippan wrote: > On Tue, 14 Dec 2004, Tim Bunce wrote: > > > On Tue, Dec 14, 2004 at 02:54:39PM +0900, [EMAIL PROTECTED] wrote: > > > Hi. > > > if (PQgetisnull(imp_sth->result, imp_sth->cur_tuple, i)) { &g

Parse/Compose DSNs

2004-12-17 Thread Tim Bunce
On Thu, Dec 16, 2004 at 10:39:17PM +0100, Jochen Wiedmann wrote: > Jeff Zucker wrote: > > >>After the "dbi:AnyData:"; everything should be in "name=value;" format. > >>So "dbi:AnyData:format=XML;table=Test;file=test.xml"; > > Btw, Tim, how about the following suggestion: The discussion on the DSN

Re: RFC: changes in DBD::Anydata DSNs

2004-12-16 Thread Tim Bunce
On Thu, Dec 16, 2004 at 08:11:44AM +, Jeff Zucker wrote: > Tim Bunce wrote: > > >After the "dbi:AnyData:"; everything should be in "name=value;" format. > >So "dbi:AnyData:format=XML;table=Test;file=test.xml"; > > Ok, I thought one addi

Re: DBI::DBD: attribute handling (outer/inner handles, $h->STORE vs. $h->{})

2004-12-16 Thread Tim Bunce
On Thu, Dec 16, 2004 at 03:19:57PM +0100, Steffen Goeldner wrote: > Tim Bunce wrote: > > > [...] > >+ # add driver prefix to attribute name if it doesn't have it > >already > >+ $attr_name = $driver_prefix.$attr_name > >+

Re: DBI::DBD: attribute handling (outer/inner handles, $h->STORE vs. $h->{})

2004-12-16 Thread Tim Bunce
I've added this: + $my $driver_prefix = "drv_"; # the assigned prefix for this driver + + # Process attributes from the DSN; we assume ODBC syntax + # here, that is, the DSN looks like var1=val1;...;varN=valN + foreach my $var ( split /;/, $dbname ) { + my ($attr_name,

Re: RFC: changes in DBD::Anydata DSNs

2004-12-16 Thread Tim Bunce
On Wed, Dec 15, 2004 at 12:28:49PM +, Jeff Zucker wrote: > I am thinking of extending the DBD::AnyData DSN in three ways and would > appreciate comments. If these are good, there will be equivalent > changes for DBD::DBM and DBD::CSV. > > 1. Allow db and dbname as aliases for f_dir for comp

Re: DBI::DBD: err/errstr/state - and how it has helped DBD::Informix

2004-12-15 Thread Tim Bunce
On Wed, Dec 15, 2004 at 07:27:59AM -0800, Jonathan Leffler wrote: > Sorry for this flurry of half-researched questions... :-( > > I'll probably be able to submit another patch to DBI::DBD.pm out of this. Great! Thanks. Tim. p.s. Patch against subversion if possible. If not grab the latest from

Re: DBI::DBD: err/errstr/state - and how it has helped DBD::Informix

2004-12-15 Thread Tim Bunce
On Tue, Dec 14, 2004 at 06:24:40PM -0800, Jonathan Leffler wrote: > On Tue, 14 Dec 2004 16:47:39 +0000, Tim Bunce <[EMAIL PROTECTED]> wrote: > > On Tue, Dec 14, 2004 at 07:08:08AM -0800, Jonathan Leffler wrote: > > > I had certainly managed to miss this change - which co

Re: Perl complaining when I pass a list of nulls (undef) to $sth->execute() - workaround?

2004-12-15 Thread Tim Bunce
macro such as SvPV(sv), on the undef value. All you've got to do is find it. If you compile/link DBD::Informix with the -g option the stack trace should give you the line number. Tim. > On Wed, 15 Dec 2004 01:00:38 +, Tim Bunce <[EMAIL PROTECTED]> wrote: > > On Tue, Dec 14,

Re: Perl complaining when I pass a list of nulls (undef) to $sth->execute() - workaround?

2004-12-14 Thread Tim Bunce
On Tue, Dec 14, 2004 at 02:13:17PM -0800, Jonathan Leffler wrote: > On Fri, 3 Dec 2004 20:54:00 +0000, Tim Bunce <[EMAIL PROTECTED]> wrote: > > On Fri, Dec 03, 2004 at 12:15:06PM -0800, Jonathan Leffler wrote: > > > > > > Use of uninitialized value in subrou

Re: DBI::DBD: err/errstr/state

2004-12-14 Thread Tim Bunce
On Tue, Dec 14, 2004 at 07:08:08AM -0800, Jonathan Leffler wrote: > I had certainly managed to miss this change - which could easily > account for some of the weirdnesses I'd been seeing in DBD::Informix. > (I haven't had a chance to do a thing for a week and more.) This sort > of backwards incom

Re: DBI::DBD: err/errstr/state

2004-12-13 Thread Tim Bunce
Thanks, applied. Tim. On Tue, Dec 14, 2004 at 10:12:54AM +0100, Steffen Goeldner wrote: > DBI 1.31 suggests that lexically scoped variables should > be passed to _new_dbh(): > > > > > DBI 1.33 suggests that dr

Re: Perl 5.6.1 - What changed in error handling between DBI 1.42 and DBI 1.43 that would affect $SIG{__WARN__} handling?

2004-12-06 Thread Tim Bunce
On Mon, Dec 06, 2004 at 09:10:33AM -0800, Jonathan Leffler wrote: > On Fri, 3 Dec 2004 21:04:11 +0000, Tim Bunce <[EMAIL PROTECTED]> wrote: > > On Thu, Dec 02, 2004 at 04:07:13PM -0800, Jonathan Leffler wrote: > > > > unless ($dbh = $drh->$connect_

Re: Perl complaining when I pass a list of nulls (undef) to $sth->execute() - workaround?

2004-12-06 Thread Tim Bunce
On Mon, Dec 06, 2004 at 10:30:03AM +, Tim Bunce wrote: > I've appended a provisional patch. Here's one that works: @@ -2870,7 +2872,11 @@ sprintf(intro,"%s %s %s: ", HvNAME(DBIc_IMP_STASH(imp_xxh)), err_meth_name, SvTRUE(err_sv) ? "fai

Re: DBI::DBD: Should DESTROY() call finish()?

2004-12-06 Thread Tim Bunce
On Mon, Dec 06, 2004 at 09:46:06AM +0100, Steffen Goeldner wrote: > DBI::DBD informs us that > > The DBI Driver.xst code will call dbd_st_finish for you, if the > sth has the ACTIVE flag set, before calling dbd_st_destroy. > > However, a pure perl DBD doesn't operate in such a luxurious > env

Re: Perl complaining when I pass a list of nulls (undef) to $sth->execute() - workaround?

2004-12-06 Thread Tim Bunce
On Mon, Dec 06, 2004 at 10:09:25AM +0100, Steffen Goeldner wrote: > Jonathan Leffler wrote: > > >Testing null handling in DBD::Informix 2004.02 (pre-release), I'm > >getting a warning from Perl: > > > >Use of uninitialized value in subroutine entry at t/t91udts.t line 97. > > Some day I got the s

Re: Perl 5.6.1 - What changed in error handling between DBI 1.42 and DBI 1.43 that would affect $SIG{__WARN__} handling?

2004-12-03 Thread Tim Bunce
On Thu, Dec 02, 2004 at 04:07:13PM -0800, Jonathan Leffler wrote: > Dear Tim, > > I was just getting ready to ship DBD::Informix 2004.02 when I made the > mistake of testing it with Perl 5.6.1 and DBI 1.46. > I ran into problems with a DBD::Informix test that was expecting an error > code to be

Re: Perl complaining when I pass a list of nulls (undef) to $sth->execute() - workaround?

2004-12-03 Thread Tim Bunce
On Fri, Dec 03, 2004 at 12:15:06PM -0800, Jonathan Leffler wrote: > Testing null handling in DBD::Informix 2004.02 (pre-release), I'm > getting a warning from Perl: > > Use of uninitialized value in subroutine entry at t/t91udts.t line 97. > > OK - it's a valid comment: the code reads: > > $sth-

Re: what does it take to make DBI:: DBD::* thread-safe?

2004-12-03 Thread Tim Bunce
On Fri, Dec 03, 2004 at 10:05:50AM -0500, Stas Bekman wrote: > Michael Peppler wrote: > >On Thu, 2004-12-02 at 18:28, Stas Bekman wrote: > > > >>Hi, > >> > >>As mod_perl 2 is going to be released shortly the issue with DBI and > >>friends not being thread-safe (I believe DBI is fine, but DBDs are

Re: what does it take to make DBI:: DBD::* thread-safe?

2004-12-03 Thread Tim Bunce
On Fri, Dec 03, 2004 at 07:55:39AM +0100, Michael Peppler wrote: > On Thu, 2004-12-02 at 18:28, Stas Bekman wrote: > > Hi, > > > > As mod_perl 2 is going to be released shortly the issue with DBI and > > friends not being thread-safe (I believe DBI is fine, but DBDs are not) > > becomes a proble

Re: DBURL name scheme

2004-11-29 Thread Tim Bunce
On Tue, Nov 30, 2004 at 12:33:40AM +0100, Hans Schou wrote: > On Mon, 29 Nov 2004, Darren Duncan wrote: > > > On Mon, 29 Nov 2004, Hans Schou wrote: > > > But making dbi:// a default prefix will probably restrict the use of > > > DBURL to only DBI. It is not realistic to think that MySQL and > > >

Re: DBI, DBURL

2004-11-29 Thread Tim Bunce
On Mon, Nov 29, 2004 at 05:45:07PM +0100, Hans Schou wrote: > > Hi Tim > > Before I go implement DBURL into DBI.pm you write that I should ask > you first about it. > > In short, DBURL is one line string which looks like a http URL. > A connection in DBI PostgreSQL could look like: > $dbh = D

<    5   6   7   8   9   10   11   12   13   14   >