TeamSite 6.1 on Solaris 8
I've got a TPL which I'm using to write to an Oracle 8i using Perl:

BI embedded within the TPL. When I run iwpt_compile.ipl from the command line, I get an error (which differs depending on if I'm trying to INSERT into the DEV DB or the PROD DB. When I try to INSERT into PROD, I get this:
DBD:
racle::st execute failed: ORA-03113: end-of-file on communication channel (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO article ( article_id, title, description, filename, externalid, weight, expirationdate, inactive, featureimage, featureimagethumbnail, externalcategory) VALUES (?,?,?,?,?,?,to_date(?,'yyyy-mm-dd'),?,?,?,?)" with ParamValues:
5="000000000",
8=1,
10=undef,
2="Jasons Test Article",
3="Jasons testing this article 9.",
6="500",
1='6896',
7="2005-08-01",
4='/templatedata/test/articles_YB/data/jasontest1.xml',
9=undef,
11="Alternative Medicine"] at /iw-home/TeamSite/iw-perl/site/lib/TRGcmsDatabase.pm line 165.
Use of uninitialized value in concatenation (.) or string at (eval 11) line 156.
Use of uninitialized value in concatenation (.) or string at (eval 11) line 156.When I try the exact same code against the DEV DB, I get this after it hangs and I have to ^C out of it:
^CDBD:
racle::st execute failed: ORA-01400: cannot insert NULL into ("MXP"."ARTICLE"."TITLE") (DBD ERROR: OCIStmtExecute) [for Statement "INSERT INTO article ( article_id, title, description, filename, externalid, weight, expirationdate, inactive, featureimage, featureimagethumbnail, externalcategory) VALUES (?,?,?,?,?,?,to_date(?,'yyyy-mm-dd'),?,?,?,?)" with ParamValues:
5="000000000",
8=1,
10=undef,
2="Jasons Test Article",
3="Jasons testing this article 9.",
6="500",
1='6897',
7="2005-08-01",
4='/templatedata/test/articles_YB/data/jasontest1.xml',
9=undef,
11="Alternative Medicine"] at /iw-home/TeamSite/iw-perl/site/lib/TRGcmsDatabase.pm line 165.
Use of uninitialized value in concatenation (.) or string at (eval 11) line 156.
Use of uninitialized value in concatenation (.) or string at (eval 11) line 156.This is the command line I'm using:
/iw-home/TeamSite/iw-perl/bin/iwperl /iw-home/TeamSite/bin/iwpt_compile.ipl -pt /iwmnt/washington/main/MXP/content/WORKAREA/Production/templatedata/test/articles_YB/presentation/prodDB.tpl -smartwrite -ofile /iwmnt/washington/main/MXP/content/WORKAREA/Production/jasontest1.htm -iw_pt-dcr /iwmnt/washington/main/MXP/content/WORKAREA/Production/templatedata/test/articles_YB/data/jasontest1.xml -iw_include-location /iwmnt/washington/main/MXP/content/WORKAREA/ProductionHere's where it gets weird.... I run the same command, but add "-ocode output.ipl". It generates the output.ipl program and I run it.... It executes perfectly on both databases. The data shows up in the database and I get no errors.
Because of this inconsistant behavior (and the warnings from line 156), my guess is that there's some sort of memory leak/use of uninitiallized variables. The only uninitialized variables that I have set to 'undef' are being passed in the DBI execute statement. I am under the impression that the way to send NULL values to the database is by passing undefined variables.
Here is my code that writes to the database:
my $InsertSQL = "INSERT INTO article ( article_id, title, description, filename, externalid, weight, expirationdate, inactive, featureimage, featureimagethumbnail, externalcategory) VALUES (?,?,?,?,?,?,to_date(?,'yyyy-mm-dd'),?,?,?,?)";
my $st = $dbh->prepare($InsertSQL);
$st->execute($newID,$title,$description,$filename,$extId,$weight,$expirationdate,$inactiveflag,$featureimage,$featurethumbnail,$externalcategory) or $retVal=0;In most cases, the $featureimage & $featurethumbnail variables will be set to undef. If there is a better way to pass a NULL value to the database, please let me know.
Thanks for any and all help,
Jason