Hello All -
I am coding a utility to write stored procedures based on the field names and data types in any given table. I can get the field-Type and field-Size but if the Type is a Decimal (number), I am hitting a wall when attemping to find out the precision and scale via code. I can only get a Size value and that just won't work.
code example:
For Each fld In db.TableDefs(sTableName).Fields
Select Case fld.Type
Case 4 'int
'
Case 7 'dbl
'
Case 8 'date
'
Case 10 'string
'pass in the iTextLen arg...
iLen = fld.Size
tstrm.WriteLine BuildCastString(fld.Name, 10, iLen)
Any ideas?
Thanks - Scott
I am coding a utility to write stored procedures based on the field names and data types in any given table. I can get the field-Type and field-Size but if the Type is a Decimal (number), I am hitting a wall when attemping to find out the precision and scale via code. I can only get a Size value and that just won't work.
code example:
For Each fld In db.TableDefs(sTableName).Fields
Select Case fld.Type
Case 4 'int
'
Case 7 'dbl
'
Case 8 'date
'
Case 10 'string
'pass in the iTextLen arg...
iLen = fld.Size
tstrm.WriteLine BuildCastString(fld.Name, 10, iLen)
Any ideas?
Thanks - Scott