Modify logical field

A

Alan T

I want to modify a Yes/No field to NULL, I tried the following:
ALTER TABLE table1 ALTER COLUMN [Resigned] [Logical] NULL

but I got syntax error.
 
A

Allen Browne

YESNO in place of [Logical] (no square brackets) should work, but JET cannot
handle Null in yes/no fields, so the NULL part won't work.

An alternative might be to create an SHORT field, with a validation rule of:
Is Null OR 0 OR -1
so that it behaves like a yes/no but supports Null.

For your reference, here's a list of the field types JET supports:
http://allenbrowne.com/ser-49.html
and some JET DDL examples:
http://allenbrowne.com/func-DDL.html
 

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

Similar Threads

Set default value to 0 with ALTER TABLE 1
Modifying a Data Type 5
Alter Table Question 2
modifiy field type by vba 6
Using checkbox to edit criteria 3
Change field type from VB 2
Search any field 10
Access Access VBA question 0

Top