I'm creating a table in a dbase III (*.dbf) file. All works fine but some of the numeric columns need specific width and precision. If I add on the width and precision in the CREATE TABLE syntax, for example, HEIGHT NUMERIC(8,2) then it doesn't work. I have tried two connection strings...
CString connString = "Driver={Microsoft dBASE Driver (*.dbf)};DriverID=277;Dbq=" + directory;
CString connString = "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" + directory + ";Extended Properties=dBASE III;";
The first one will result in an error when I try to create the table and the second will allow me to create the table but there is no width or precision applied to the resulting dbf file.
The error for the odbc creat table statement is... Code = 80040e14 Code meaning = IDispatch error #3092 Source = Microsoft OLE DB Provider for ODBC Drivers Description = [Microsoft][ODBC dBase Driver] Syntax error in CREATE TABLE statement.
Anyone know what I should be using to create a dbf (dbaseIII) file that has specific field width and precision? Thanks.