import text file errors - cutting off decimals

  • Thread starter Thread starter Guest
  • Start date Start date
G

Guest

Hi,
I am trying to write a macro that uploads a csv file.
Field 7 is a price e.g 1.6500 but Access is cutting off the decimals giving
1 in field 7 of the table and not the complete 1.65. Can somebody help?
Thanks
George
 
George,

This is most likely the result of the table field data type being
Integer or Long, which by definition is incapable of storing a decimal
part. Change field type to Single or Double (depending on the order of
magnitude of the values - press F1 while the cursor is in the fieldsize
property of the table design view for more details).

HTH,
Nikos
 
In the advanced button you need to alter the type of the fields you
want, in that case to double and save as a import specification. Later
in all situation you need to import that file you must use that
specification.

[]'s
BD
 
Thanks BD,
That worked a treat. i appreciate your help.
George

BD said:
In the advanced button you need to alter the type of the fields you
want, in that case to double and save as a import specification. Later
in all situation you need to import that file you must use that
specification.

[]'s
BD

Hi,
I am trying to write a macro that uploads a csv file.
Field 7 is a price e.g 1.6500 but Access is cutting off the decimals giving
1 in field 7 of the table and not the complete 1.65. Can somebody help?
Thanks
George
 
BD,
i have another xls file i wish to import - and when i try to specify the
sheet name to import Access wont let me save an import specification. Do you
have a suggestion on how i can tell access in a macro how to import the
specific sheet name in the excel file?
Thanks
George

George said:
Thanks BD,
That worked a treat. i appreciate your help.
George

BD said:
In the advanced button you need to alter the type of the fields you
want, in that case to double and save as a import specification. Later
in all situation you need to import that file you must use that
specification.

[]'s
BD

Hi,
I am trying to write a macro that uploads a csv file.
Field 7 is a price e.g 1.6500 but Access is cutting off the decimals giving
1 in field 7 of the table and not the complete 1.65. Can somebody help?
Thanks
George
 
I really don't know. Perhaps someone else will help you

[]'s
BD


BD,
i have another xls file i wish to import - and when i try to specify the
sheet name to import Access wont let me save an import specification. Do you
have a suggestion on how i can tell access in a macro how to import the
specific sheet name in the excel file?
Thanks
George

George said:
Thanks BD,
That worked a treat. i appreciate your help.
George

BD said:
In the advanced button you need to alter the type of the fields you
want, in that case to double and save as a import specification. Later
in all situation you need to import that file you must use that
specification.

[]'s
BD

On Tue, 13 Jun 2006 21:34:03 -0700, George

Hi,
I am trying to write a macro that uploads a csv file.
Field 7 is a price e.g 1.6500 but Access is cutting off the decimals giving
1 in field 7 of the table and not the complete 1.65. Can somebody help?
Thanks
George
 
Import specifications only apply when importing data from text files.

If you want to specify a sheet name in a macro, use the name as the
Range argument of the macro. If I remember rightly, you need to append a
$, using
Sheet1$
for Sheet1 and so on.

BD,
i have another xls file i wish to import - and when i try to specify the
sheet name to import Access wont let me save an import specification. Do you
have a suggestion on how i can tell access in a macro how to import the
specific sheet name in the excel file?
Thanks
George

George said:
Thanks BD,
That worked a treat. i appreciate your help.
George

BD said:
In the advanced button you need to alter the type of the fields you
want, in that case to double and save as a import specification. Later
in all situation you need to import that file you must use that
specification.

[]'s
BD

On Tue, 13 Jun 2006 21:34:03 -0700, George

Hi,
I am trying to write a macro that uploads a csv file.
Field 7 is a price e.g 1.6500 but Access is cutting off the decimals giving
1 in field 7 of the table and not the complete 1.65. Can somebody help?
Thanks
George
 
Back
Top