On MSDN, I found a data type chart 
(http://msdn.microsoft.com/library/en-
us/odbc/htm/odbcsql_data_types.asp) for ODBC, which lists what I 
presume to be the types of data types that can be created for a table 
using DBI.  Am I correct so far?  For those of you going to look at this 
for the first time, I am also presuming that the middle column, labelled 
"Typical SQL data type" is the data type description that would be used 
when creating a table with DBI.

The table I am creating needs to have an automatically incremental 
column, named 'sid'.  So far, this is what I have:

my $dbh = DBI->connect('dbi:ODBC:armstrongfrn_survey') || die 
DBI::errstr;
my $sth = $dbh->do("CREATE TABLE sample (
                          sid INTEGER auto_increment,
                          abstract VARCHAR(255) )
                                 ");
$dbh->disconnect();

But, I get an error, of course.  Does anyone know where there is a 
convenient chart of attributes to apply to data types, using ODBC?  
And, even better, if anyone knows of syntax examples, that would be 
super, too.

Right now, I am roaming back and forth between MSDN, "Programming 
the Perl DBI", the DBI perldoc, and the "ActivePerl Developer's Guide", 
none with much luck on finding this attribute information.

Thanks again for the help.

Brad Smith

Reply via email to