Re: Remove "Allow Null" property from column
- From: "Darren Shaffer" <darrenshaffer@xxxxxxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 5 Apr 2005 14:37:58 -0600
Alex,
Your syntax looks correct to me - when you run the
"ALTER TABLE tableName ALTER COLUMN columnName NOT NULL"
command, what error do you get? A syntax error (Error Parsing Query) or
something else?
A stupid question - are there any null values in this column when you try to
run this command?
Finally - do you have any other constraints defined on this column?
Are you planning to synchronize this table with your central server? Is
dropping a recreating
the table in SQL CE an option for you?
--
Darren Shaffer
..NET Compact Framework MVP
Principal Architect
Connected Innovation
www.connectedinnovation.com
(303) 886-1932
"Alex Feldman" <alex-feldman@xxxxxxxxxxx> wrote in message
news:uq1yT$gOFHA.3560@xxxxxxxxxxxxxxxxxxxxxxx
> Does anyone know the sql command (or any other programmatic way) of
> removing the "Allow Null" property from a sql server ce column? This
> column needs to be a primary key for my table but I need to remove the
> "Allow Null" property (it is there in the central database by wrongful
> design, but it's too late for me to remove it from the central
> database).
>
> I've tried the
> "ALTER TABLE tableName ALTER COLUMN columnName NOT NULL" but it failed,
> as well as other attempts.
>
> Thanks.
>
> Alex
>
> p.s. for those following my previous thread about slow table querying,
> it appears that I really do need this feature....for another table in my
> database :-(
>
> *** Sent via Developersdex http://www.developersdex.com ***
.
- Follow-Ups:
- Re: Remove "Allow Null" property from column
- From: Alex Feldman
- Re: Remove "Allow Null" property from column
- References:
- Remove "Allow Null" property from column
- From: Alex Feldman
- Remove "Allow Null" property from column
- Prev by Date: Remove "Allow Null" property from column
- Next by Date: Re: Remove "Allow Null" property from column
- Previous by thread: Remove "Allow Null" property from column
- Next by thread: Re: Remove "Allow Null" property from column
- Index(es):
Relevant Pages
|