how to copy text string to all records in column in Access 2002

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

Guest

I added a column to a table and want to copy a text string to the remaining
cells in the column in Access 2002. Also, I want to export the amount column
as text with zero filled and without the decimal point. Can some tell me how
to do this in Ascess 2002.

TS
 
I added a column to a table and want to copy a text string to the remaining
cells in the column in Access 2002. Also, I want to export the amount column
as text with zero filled and without the decimal point. Can some tell me how
to do this in Ascess 2002.

TS

Copying a text string is easy - just create an update query to do the job,
which will generate SQL that looks something like:
UPDATE tblName SET fldName = "text string"

To get the right format when exporting, you're best off creating a calculated
column to get it into the exact format you want:
Format (fldName * 100, "0000")

(you multiply by however many numbers you have after the decimal point and
use as many zeros as you want the column to have overall)
 
The update & set stmt worked great, thanks. The format stmt also worked however
when I run export to a fixed width text file, the amount field loses the
leading zeroes and is left justified. How can I retain the leading zeroes in
the text file?
Tonys
 

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

Back
Top