I have no problem connecting to an Oracle 8.1.5 database on Netware 5.1 and viewing the contents of the database, however, add or editing are causing me problems. Here is my test code: #!c:\perl\bin\perl.exe use CGI; use DBI qw(:sql_types); $query = CGI::new(); if (($query->request_method() eq "POST") && ($query->param("CourseID") ne '') && ($query->param("Title") ne '') && ($query->param("Fees") ne '') && ($query->param("Days") ne '') && ($query->param("Dates") ne '') && ($query->param("Times") ne '') && ($query->param("Location") ne '') && ($query->param("Community") ne '')) { &UpdateDB; } else { print $query->header(); print $query->start_html( -title=>'ERROR'); print "<FONT FACE='Arial' color='#FF0000'>"; print "<H2>Unable to complete insert!</H2><BR>"; print "<H3>Incomplete data was received!</H3><P>"; print "<FORM METHOD='POST' ACTION='tasks.pl'>"; print "<INPUT TYPE='hidden' NAME='Community' VALUE=$community>"; print "<INPUT TYPE='hidden' NAME='task' VALUE='Edit'>"; print "<INPUT TYPE='SUBMIT' VALUE='OK'>"; print " Try again?"; print "</FORM>"; print "</FORM>"; print "<FORM METHOD='' ACTION='http://10.1.9.20/courses/coursedata.html'>"; print "<INPUT TYPE='SUBMIT' VALUE='OK'>"; print "<B> Choose another option?<B>"; print "</FORM>"; } sub UpdateDB { $courseid=$query->param("CourseID"); $title=$query->param("Title"); $fees=$query->param("Fees"); $hours=$query->param("Hours"); $ceus=$query->param("CEUS"); $days=$query->param("Days"); $dates=$query->param("Dates"); $times=$query->param("Times"); $location=$query->param("Location"); $room=$query->param("Room"); $instructor=$query->param("Instructor"); $community = $query->param("Community"); $dsname = "ouce"; $user = "admin"; $password = "novell"; if ($room eq '') { $room=" "; } if ($instructor eq '') { $instructor=" "; } $sql = "INSERT INTO courses (CourseID, Title, Fees, Hours, CEUs, CourseDays, CourseDates, CourseTimes, Location, Room, Instructor, Community) VALUES (\'$courseid\', \'$title\', \'$fees\', $hours, $ceus, \'$days\', \'$dates\', \'$times\', \'$location\', \'$room\', \'$instructor\', \'$community\');"; DBI->trace(2,"adderror.txt"); $dbh = DBI->connect("dbi:ODBC:$dsname",$user,$password, { RaiseError => 1 }); $cursor = $dbh->prepare($sql); $cursor->execute || die $dbh->errstr; $dbh->disconnect; print $query->header(); print $query->start_html( -title=>'Insert Results'); print "<FONT FACE='Arial' color='#FF0000'>"; print "<H2>Insert was complete!</H2><P>"; print "<FORM METHOD='POST' ACTION='tasks.pl'>"; print "<INPUT TYPE='hidden' NAME='Community' VALUE='$community'>"; print "<INPUT TYPE='hidden' NAME='task' VALUE='Edit'>"; print "<INPUT TYPE='SUBMIT' VALUE='OK'>"; print "<B> Add another course?</B>"; print "</FORM>"; print "<FORM METHOD='' ACTION='http://10.1.9.20/courses/coursedata.html'>"; print "<INPUT TYPE='SUBMIT' VALUE='OK'>"; print "<FONT FACE='ARIAL' COLOR='#000000'>"; print "<B> Choose another option?</B>"; print "</FORM>"; } I have attached the error file I have been getting... Any help is appreciated, Mitch Clarvit SoftDev, Inc.
DBI 1.06 dispatch trace level set to 2 Note: perl is running without the recommended perl -w option -> DBI->connect(dbi:ODBC:ouce, admin, novell, HASH(0xca4242ac)) -> DBI->install_driver(ODBC) for perl=5.00307 pid=276 ruid=0 euid=0 install_driver: DBD::ODBC loaded <- install_driver= DBI::dr=HASH(0xc9f988a8) -> connect for DBD::ODBC::dr (DBI::dr=HASH(0xc9f988a8)~0xcf7417b8 'ouce' 'admin' 'novell' HASH(0xca4249dc)) connect 'ouce', 'admin', 'novell' <- connect= DBI::db=HASH(0xcf74171c) at DBI.pm line 378. -> STORE for DBD::ODBC::db (DBI::db=HASH(0xcf74174c)~INNER 'RaiseError' 1) <- STORE= 1 at DBI.pm line 400. -> STORE for DBD::ODBC::db (DBI::db=HASH(0xcf74174c)~INNER 'PrintError' 1) <- STORE= 1 at DBI.pm line 400. -> STORE for DBD::ODBC::db (DBI::db=HASH(0xcf74174c)~INNER 'AutoCommit' 1) <- STORE= 1 at DBI.pm line 400. <- connect= DBI::db=HASH(0xcf74171c) -> prepare for DBD::ODBC::db (DBI::db=HASH(0xcf74171c)~0xcf74174c 'INSERT INTO courses (CourseID, Title, Fees, Hours, CEUs, CourseDays, CourseDates, CourseTimes, Location, Room, Instructor, Community) VALUES ('GFNUPC103', 'Access 2000 Introduction', '$149', 12, 1.2, '4 Tues & 4 Thurs', 'Feb 6 - Mar 1', '5:00 - 6:30 pm', 'Boca Raton Campus ', ' ', ' ', 'smartIT');') dbd_st_prepare'd sql f-893011600 INSERT INTO courses (CourseID, Title, Fees, Hours, CEUs, CourseDays, CourseDates, CourseTimes, Location, Room, Instructor, Community) VALUES ('GFNUPC103', 'Access 2000 Introduction', '$149', 12, 1.2, '4 Tues & 4 Thurs', 'Feb 6 - Mar 1', '5:00 - 6:30 pm', 'Boca Raton Campus ', ' ', ' ', 'smartIT'); <- prepare= DBI::st=HASH(0xcf74183c) at addcourse.pl line 79. -> execute for DBD::ODBC::st (DBI::st=HASH(0xcf74183c)~0xca4243b4) dbd_st_execute (for sql f-893011600 after)... ERROR EVENT -1 '[TOD][ODBC][SQLI]%PARSER-E-SYNTAX, Line 5 Syntax Error: Last Symbol Read Was hours (SQL-S1000)(DBD: st_execute/SQLExecute err=-1)' (Handlers: undef) st_execute/SQLExecute error -1 recorded: [TOD][ODBC][SQLI]%PARSER-E-SYNTAX, Line 5 Syntax Error: Last Symbol Read Was hours (SQL-S1000)(DBD: st_execute/SQLExecute err=-1) <- execute= undef at addcourse.pl line 80. !! ERROR: -1 '[TOD][ODBC][SQLI]%PARSER-E-SYNTAX, Line 5 Syntax Error: Last Symbol Read Was hours (SQL-S1000)(DBD: st_execute/SQLExecute err=-1)' -> DBI::END -> disconnect_all for DBD::ODBC::dr (DBI::dr=HASH(0xc9f988a8)~0xcf7417b8) <- disconnect_all= '' at DBI.pm line 417. <- DBI::END complete -> DESTROY for DBD::ODBC::st (DBI::st=HASH(0xca4243b4)~INNER) <- DESTROY= undef during global destruction. -> DESTROY for DBD::ODBC::db (DBI::db=HASH(0xcf74174c)~INNER) <- DESTROY= undef during global destruction. -> DESTROY in DBD::_::common for DBD::ODBC::dr (DBI::dr=HASH(0xcf7417b8)~INNER) <- DESTROY= undef during global destruction.