Weird. What Database you using?

I did a test table with an admin  column in MSsqlServer7 and it worked fine

Any chance "admin" is reserved word in that DB?

Justin

--------------- test table sql -------------------------------------
if exists (select * from dbo.sysobjects where id =
object_id(N'[dbo].[test]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)
drop table [dbo].[test]
GO

CREATE TABLE [dbo].[test] (
        [testid] [int] IDENTITY (1, 1) NOT NULL ,
        [teststr] [varchar] (50) NULL ,
        [admin] [bit] NOT NULL
) ON [PRIMARY]
GO

ALTER TABLE [dbo].[test] WITH NOCHECK ADD
        CONSTRAINT [DF_test_admin] DEFAULT (0) FOR [admin],
        CONSTRAINT [PK_test] PRIMARY KEY  CLUSTERED
        (
                [testid]
        )  ON [PRIMARY]
GO
--------------- test table sql -------------------------------------




> -----Original Message-----
> From: Russ 'Snake' Michaels [mailto:[EMAIL PROTECTED]]
> Sent: Friday, August 09, 2002 2:30 PM
> To: [EMAIL PROTECTED]
> Subject: RE: [ cf-dev ] update query
>
>
> UPDATE        Companies
>               SET
> Name='#FORM.Required_CompanyName#',
>                                       Address='#FORM.Address#',
>                                       Town='#FORM.Town#',
>                                       County='#FORM.County#',
>                                       Postcode='#FORM.Postcode#',
>                                       Country='#FORM.Country#',
>
> CompanyTelephone='#FORM.ReqPhone_CompanyTelephone#',
>                                       Fax='#FORM.NoRPhone_Fax#',
>
> CompanyEmail='#FORM.NoREmail_CompanyEmail#',
>                                       Website='#FORM.Website#',
>
> ContactPerson='#FORM.Required_ContactPerson#',
>
> ContactEmail='#LCase(FORM.ReqEmail_ContactEmail)#',
>
> ContactTelephone='#FORM.ContactTelephone#',
>                                       Brands='#FORM.Brands#',
>                                       ProductTypes='#FORM.ProductTypes#',
>
> MinimumOrder=#FORM.NoRNumer_MinimumOrder#,
>
> AvailableFrom='#FORM.AvailableFrom#',
>
> CourseSubjects='#FORM.CourseSubjects#',
>
> Qualifications='#FORM.Qualifications#',
>                                       CourseType='#FORM.CourseType#',
>                                       Services='#FORM.Services#',
>                                       ServiceType='#FORM.ServiceType#',
>
> PersonnelType='#FORM.PersonnelType#',
>                                       Employers='#FORM.Employers#',
>                                       AdType=#AdType#,
>                                       Active=#Status#
>               WHERE           CompanyID=#FORM.ID#
>
> -----Original Message-----
> From: Spike [mailto:[EMAIL PROTECTED]]
> Sent: 09 August 2002 14:14
> To: [EMAIL PROTECTED]
> Subject: RE: [ cf-dev ] update query
>
>
> What does your query look like?
>
> > -----Original Message-----
> > From: Russ 'Snake' Michaels [mailto:[EMAIL PROTECTED]]
> > Sent: 09 August 2002 15:09
> > To: [EMAIL PROTECTED]
> > Subject: [ cf-dev ] update query
> >
> >
> > ok check this out.
> >
> > I have a field in the table
> >
> > Admin               bit     default(0)
> >
> > The value of this field is currently set to 1
> > I have just changed it to a NOT NULL value with a default,
> > previous is a NULL, still did the same thing.
> >
> > I run an update query, this query DOES NOT update this
> > column. There are no other update queries. Nothing touches
> > this column at all. Yet every time I run an update query,
> > this field gets set to 0 all by itself. there are no triggers
> > or anything of this sort to cause it, it is just a plain old table.
> >
> >
> >
> > --
> > To unsubscribe, e-mail: [EMAIL PROTECTED]
> > For additional commands, e-mail:
> > [EMAIL PROTECTED] For human help, e-mail:
> > [EMAIL PROTECTED]
> >
> >
> >
>
>
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> For human help, e-mail: [EMAIL PROTECTED]
>
>
>
> --
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> For human help, e-mail: [EMAIL PROTECTED]
>
>
>
>


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
For human help, e-mail: [EMAIL PROTECTED]


Reply via email to