Import/export from access query to excel

G

Guest

Hi all,

I need a CVS file with some data I have in an access query. To do that I'm
trying to import (in excel) and Export (in access), and everything goes right
except the fields where I have up to 255 characters. These (in excel) only
shows the first 255 characters.

How to resolve this problem? or better, How to create a CSV file from my
Access query?

Thank you all. Tom.
 
J

John Nurick

Hi Tom,

Normally one just exports the query to CSV. Excel doesn't come into it
at all.

There are however some circumstances even then where fields are
truncated at 255 characters. Broadly they occur

1) when the field is a memo field and the query does something with its
contents, such as sorting or filtering (even that involved in a UNION
query);

2) if the field is a calculated field that produces a string more than
255 characters long (e.g. an expression that concatenates values from
several other fields, or that performs an operation - such as formatting
- on a memo field whose contents are more than 255 characters).

For 1, the work-round is to do the sorting or filtering in a subquery so
the main query can return the long field without any manipulation.

For 2, it may be necessary to append the records to a temporary table
from which they can be exported without manipulation.
 
G

Guest

Thanks a lot. It was the point.

John Nurick said:
Hi Tom,

Normally one just exports the query to CSV. Excel doesn't come into it
at all.

There are however some circumstances even then where fields are
truncated at 255 characters. Broadly they occur

1) when the field is a memo field and the query does something with its
contents, such as sorting or filtering (even that involved in a UNION
query);

2) if the field is a calculated field that produces a string more than
255 characters long (e.g. an expression that concatenates values from
several other fields, or that performs an operation - such as formatting
- on a memo field whose contents are more than 255 characters).

For 1, the work-round is to do the sorting or filtering in a subquery so
the main query can return the long field without any manipulation.

For 2, it may be necessary to append the records to a temporary table
from which they can be exported without manipulation.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top