On Tue, 10 Sep 2002, Tim Bunce wrote: > > I'm not sure. Wouldn't any fetch() method returning an array behave in > > the same manner? For whatever reason, we did not see this problem until > > Perl 5.8.0, so I'm not convinced it's a problem with the DB2 driver. > > fetch() is an alias for fetchrow_arrayref, so calling it in a scalar context > should make no difference. Can you look into that? May a trace log would help.
I'll let you know. > > > Adding support for non-lazy prepare is a valuable addition - but > > > it needs to be made configurable at the dbh level via an attribute. > > > > I'm not sure I agree with you on this. The Proxy should remain as > > transparent as possible to any client applications. By treating it as a > > another attribute in the DBI_AUTOPROXY dsn string, we can avoid the need > > to make any changes to the application. Unless I'm misunderstanding you, > > there would be no way to avoid this if it's only available through the dbh. > > Ah, I was forgetting that the DBI_AUTOPROXY env var setting currently > forces a "dbi:Proxy:" prefix and so can't be used to set attributes. > So I'll fix that [...later...] done. Now if the DBI_AUTOPROXY env > var matches /^dbi:/i then the dbi will assume it has the full prefix. > > This has two advantages, first we can now set proxy attributes: > > DBI_AUTOPROXY=dbi:Proxy(proxy_lazy_prepare=>1):host=... > > but also we can use DBI_AUTOPROXY to enable the use of any other > driver that works in a similar way: > > DBI_AUTOPROXY=dbi:MyCustomProxy:... It also ensures that autoproxy mode works in the manner implied by the documentation. I wasted a lot of time trying to figure out why setting: DBI_AUTOPROXY='dbi:Proxy:hostname=foo;port=1234' caused a runtime error. Accepting the driver spec is definitely goodness. Any way I can get a patch for that? Can you grant r/o access to CVS or the like? Steve
