Converting a letter (text) to a number

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

Guest

How can I convert a letter to a number: example: F = 2 or M =1.

Thank you.
 
You can add an expression like this in a query cell. Just
make sure that your only values are F and M.

Sexfld:IIF(fld="F",2,1)

Otherwise, do:

Sexfld:IIF(fld="F",2,IIF(fld="M",1,0))

In this case, 0 will be anything that wasn't F or M
 

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