in reply to Re^2: DBD::Mock and DBD-specific attributes
in thread DBD::Mock and DBD-specific attributes
After looking more closely at the source of DBD::Mock, I agree, it should work as you expect. After reading DBI::DBD I am convinced it should work as you expect. However, it does not. The really weird part of course is that it seems to works for other attributes like PrintError, RaiseError, etc. I am trying to figure it out right now, I will keep you updated.
UPDATE
Found this in the trace output:
So it seems that DBI will skip over driver specific attributes. According to line 1554 of DBI.xs, only those attributes that start with 'private_', 'dbi_' or 'dbd_' are allowed, all others are ignored. However, this seems to contradict what it says in DBI::DBD$h->{'mysql_insertid'}=10 ignored for invalid driver-specific attribut +e
The DBI will actually store and fetch driver-specific attributes (with all lowercase names) without warning or error, so there's actually no need to implement driver-specific any code in your FETCH and STORE methods unless you need extra logic/checks, beyond getting or setting the value.Hmmmm.
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: DBD::Mock and DBD-specific attributes
by jZed (Prior) on Aug 16, 2004 at 20:37 UTC | |
Re^4: DBD::Mock and DBD-specific attributes
by dragonchild (Archbishop) on Aug 16, 2004 at 20:04 UTC | |
by stvn (Monsignor) on Aug 17, 2004 at 01:09 UTC | |
by lachoy (Parson) on Aug 17, 2004 at 02:12 UTC |