Author: timbo
Date: Sun Feb 22 08:28:17 2004
New Revision: 126
Modified:
dbi/trunk/Changes
dbi/trunk/DBI.pm
Log:
Change table_info() and column_info() to check argument count.
Added \%attr parameter to foreign_key_info() method.
Modified: dbi/trunk/Changes
==============================================================================
--- dbi/trunk/Changes (original)
+++ dbi/trunk/Changes Sun Feb 22 08:28:17 2004
@@ -8,7 +8,6 @@
Split keep_err ima into err_keep_call err_ignore_rtn, err_chknew_rtn
FETCH would be err_keep_in and err_chknew_rtn
-Add %attr to more methods, esp metadata
Fixed execute_for_array() so tuple_status parameter is optional
as per docs, thanks to Ed Avis.
@@ -27,6 +26,7 @@
so that fetchall_arrayref(), for example, doesn't flood the trace.
Changed trace level to be a four bit integer (levels 0 thru 15)
and a set of topic flags (no topics have been assigned yet).
+ Change table_info() and column_info() to check argument count.
Extended bind_param() TYPE attribute specification to imply
standard formating of value, eg SQL_DATE implies 'YYYY-MM-DD'.
@@ -44,6 +44,7 @@
Added $h->{ErrCount} attribute, incremented whenever an error is
recorded by the driver via set_err().
Added $h->{Executed} attribute, set if do()/execute() called.
+ Added \%attr parameter to foreign_key_info() method.
Added ref count of inner handle to "DESTROY ignored for outer" msg.
Added Win32 build config checks to DBI::DBD thanks to Andy Hassall.
Added bind_col to Driver.xst so drivers can define their own.
Modified: dbi/trunk/DBI.pm
==============================================================================
--- dbi/trunk/DBI.pm (original)
+++ dbi/trunk/DBI.pm Sun Feb 22 08:28:17 2004
@@ -408,11 +408,11 @@
rows => $keeperr,
tables => { U =>[1,6,'$catalog, $schema, $table, $type [, \%attr ]'
], O=>0x0200 },
- table_info => { U =>[1,6,'$catalog, $schema, $table, $type [, \%attr ]'
], O=>0x0200|0x0800 },
- column_info => { U =>[1,6,'$catalog, $schema, $table, $column [, \%attr
]'],O=>0x0200|0x0800 },
+ table_info => { U =>[5,6,'$catalog, $schema, $table, $type [, \%attr ]'
], O=>0x0200|0x0800 },
+ column_info => { U =>[5,6,'$catalog, $schema, $table, $column [, \%attr
]'],O=>0x0200|0x0800 },
primary_key_info=> { U =>[4,5,'$catalog, $schema, $table [, \%attr ]' ],
O=>0x0200|0x0800 },
primary_key => { U =>[4,5,'$catalog, $schema, $table [, \%attr ]' ],
O=>0x0200 },
- foreign_key_info=> { U =>[1,7,'$pk_catalog, $pk_schema, $pk_table,
$fk_catalog, $fk_schema, $fk_table' ], O=>0x0200|0x0800 },
+ foreign_key_info=> { U =>[7,8,'$pk_catalog, $pk_schema, $pk_table,
$fk_catalog, $fk_schema, $fk_table [, \%attr ]' ], O=>0x0200|0x0800 },
type_info_all => { U =>[1,1], O=>0x0200|0x0800 },
type_info => { U =>[1,2,'$data_type'], O=>0x0200 },
get_info => { U =>[2,2,'$info_type'], O=>0x0200|0x0800 },
@@ -4079,6 +4079,10 @@
$sth = $dbh->foreign_key_info( $pk_catalog, $pk_schema, $pk_table
, $fk_catalog, $fk_schema, $fk_table );
+ $sth = $dbh->foreign_key_info( $pk_catalog, $pk_schema, $pk_table
+ , $fk_catalog, $fk_schema, $fk_table
+ , \%attr );
+
Returns an active statement handle that can be used to fetch information
about foreign keys in and/or referencing the specified table(s).
The arguments don't accept search patterns (unlike table_info()).