I don't find anything in the wiki about this, and not much on the message board. It would sure be helpful to get experienced input.
The 'export to sql' feature automatically converts existing DBF types to SQL types. User can change the type if desired. Obviously there is not one Best, but my 2 SQL books and the web have not given me much enlightenment so far.
The default type conversion in v11 are
My initial questions are
1. in Num 16, 2 conversion Alpha includes the decimal point in the 16. So I assume that SQL does not, which is why it went down to 15?
2. SQL Text data type has been depricated in SQL Server. Should we be using varcar()?
3. Image data type has been depricated. What should be used?
4. Date converts to datetime. If only the date portion is used, are queries,etc., simpler if SQL Date type is used?
5. Logical converts to bit. I have seen posts about only using tinyint(1) for logical. What are the implications?
6. In general is there any reason not to use varchar in place of char.
7. At what point is nvarchar needed. If app has only English and Spanish is varchar OK? Is there any penalty other than disk space for nvarchar?
Bill.
The 'export to sql' feature automatically converts existing DBF types to SQL types. User can change the type if desired. Obviously there is not one Best, but my 2 SQL books and the web have not given me much enlightenment so far.
The default type conversion in v11 are
Code:
DBF SQL Char255 char(255) Char1 char(1) Num16_2 numeric(15,2) Num17_7 numeric(16,7) Num1 numeric(1,0) Date datetime Logical bit Datetime datetime Shorttime smalldatetime Memo text Bitmap image Rtf image Jpeg image Image_Ref text Html text Uuid uniqueidentifier
1. in Num 16, 2 conversion Alpha includes the decimal point in the 16. So I assume that SQL does not, which is why it went down to 15?
2. SQL Text data type has been depricated in SQL Server. Should we be using varcar()?
3. Image data type has been depricated. What should be used?
4. Date converts to datetime. If only the date portion is used, are queries,etc., simpler if SQL Date type is used?
5. Logical converts to bit. I have seen posts about only using tinyint(1) for logical. What are the implications?
6. In general is there any reason not to use varchar in place of char.
7. At what point is nvarchar needed. If app has only English and Spanish is varchar OK? Is there any penalty other than disk space for nvarchar?
Bill.
Comment