Change text format to Yes/No?

PaulA

Registered User.
Local time
Today, 04:58
Joined
Jul 17, 2001
Messages
416
Hi, all--

I came into a database where the forms have checkboxes connected to table fields that are in text data type. I see that when the checkbox is checked, the value in the field is still -1 in the table. Is there a reason to change these fields to Yes/No data type or just keep them as they are? Are there limitations or problems to having Yes/No values (-1) in a text field?

Thanks.

Paul
 
You can't just rip out that ugly beam in the basement without making sure the rest of your house isn't going to collapse. You are right in thinking that the field should be Yes/No, if only 2 values are ever present. However, the biggest reason not too, is not knowing the effects will be.

You've got to map out what queries, forms and reports will be impacted by changing this to a Yes/No and editing them so that they don't stop working. Also, you need to make sure that there are only 2 distinct values that field ever has. If it has -1, 0 and Null, then technically that's 3 values and maybe somewhere in the database the Null value means something different than 0 or -1.
 
The value is always -1 or 0 (or null for a triple state). Yes/No (or True/False) is just another way of presenting the data so if set in the table design this will being picked up when creating a control on a form or report.

Personally I don't use checkboxes in continuous or datasheet forms because if the user clicks on the field and it is not locked, they can change the value when all they wanted to do was sort or filter, so in those cases I display yes/no or true/false (or even Y/N) depending on context -using a one row listbox with a value rowsource of

-1,"Yes",0,"No"
 

Users who are viewing this thread

Back
Top Bottom