Informix 9.2UC1 w/ WebData Blades
DBD::Informix 0.97005
DBI 1.13
Having some problems with the LIST datatype w/ Informix.
The problem is that the database pops an Assertion Failure with the code I
have below. It works fine from dbaccess, just not with DBI.
Does anyone know if this is a known problem with DBD::Informix, or the engine
or ......
See example code below:
#!/usr/bin/perl
BEGIN
{
require "/usr/informix/projects/lib/libp.pm";
};
$lib = new libp();
$dbh = $lib->OpenDB();
###############################
## create temp table to test ##
###############################
$temp_table_id = "list_row_test" . $$;
print "Creating test table\t[$temp_table_id]\n";
$table_sql = qq{
CREATE TEMP TABLE $temp_table_id
(
id serial,
name varchar(25),
list LIST(INTEGER NOT NULL)
)
};
$lib->SQLQuery($dbh, $table_sql);
$dbh->commit();
###########################
## insert some test data ##
###########################
$insert_sql = qq{
INSERT INTO
$temp_table_id
(
id,
name,
list
)
VALUES(100,"David",LIST{2})
};
@values = (100,"David","202");
$lib->SQLQuery($dbh, $insert_sql);
$dbh->commit();
#################################
## select test data from table ##
#################################
$select_sql = qq{
SELECT
*
FROM
$temp_table_id
};
$st1 = $lib->SQLQuery($dbh, $select_sql);
while($data = $st1->fetchrow_hashref())
{
$lib->print_ds(\$data);
}
$lib->CloseDB($dbh);
Thanks
--
------------------------------------
|| James Maes
|| Senior Programmer
|| [EMAIL PROTECTED]
|| The Sporting News
|| www.sportingnews.com
|| fantasy.sportingnews.com
|| radio.sportingnews.com
------------------------------------
"given enough time and resources we can accomplish anything"