text field to checkbox on imported excel sheet

  • Thread starter Relative Begginer
  • Start date
R

Relative Begginer

Hello. I imported an Excel sheet into Access creating a new table. We have
a text column that I would like to make into a check box column. The data is
essentially y/n already. I need to know what replace the "x" we have now (for
"yes") with so when I go to design view and change the field Access doesn't
erase the data just makes it a "yes" if there's an "x" in the field or "no"
if the field is blank.

Would I replace "X" with 1/0, y/n or something else? Would I need to not
have blank record entries? In the example below, use a 1/0 approach instead
of using "X".

Example:
Header is "School"
Record 1 is "X"
Record 2 is " " (Blank)

Thank you for any help you can give me!
 
K

KARL DEWEY

If you are only interested in changing for reporting purposes then just use a
calculated field in the query like this --
Attended: IIF([School] = "X", "Yes", "No")
 
M

Maverick

Yes/No fields store the data as True/False. If you change your "x" to True,
it should import fine. You don't have to change your blanks to False, but you
may want to. I'm not sure if it matters in the end, but sometimes it's better
to be safe than sorry.
 

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