RE: Constraint

RE: Constraint

 

  

You Should use trigger for this.

-----Original Message-----
From: Carol Green
[mailto:mssqldba-ezmlmshield-x96911641.[Email address protected]
Sent: 30 January 2007 5:35 PM
To: LazyDBA Discussion
Subject: RE: Constraint


Hi Manu,

Sounds to me like something that would be better handled in the
application or failing that a trigger to undo any changes made if the
date is greater.

If I was using an application, I would prefer to know that I couldn't
change the record before I edited it rather than after...

Carol.

-----Original Message-----
From: Manu varghese
[mailto:mssqldba-ezmlmshield-x98917802.[Email address protected]
Sent: 30 January 2007 11:51
To: LazyDBA Discussion
Subject: Constraint


Hi All

I have a table with 5 columns say a,b,c,d,e. Where column 'e' is of
datatype datetime and all the rest are of nvarchar. I need a constraint
that any one the four columns (a,b,c,d) should be editable if the date
in the column 'e' should be garater than current date


Please help...


Regards
Manu.



---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY To post a
dba job: http://jobs.lazydba.com To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html


This email and any files transmitted within it are private and confidential.
If you are not the intended recipient, this email and any attachments within it have been transmitted to you in error.
You are prohibited from using, copying, distributing or otherwise using the information contained within this email.
Nothing in this email message amounts to a contractual or legal commitment on the part of Optilan unless confirmed by a communication signed on behalf of the company.
Any email cannot be guaranteed to be secure, error free or free from viruses. Although every possible care is taken by Optilan, Optilan does not accept any liability whatsoever for any loss or damage which may be caused as a result of the transmission of this message by email.



---------------------------------------------------------------------
TO REPLY TO EVERYBODY , PLEASE CLICK REPLY-ALL, NOT JUST REPLY
To post a dba job: http://jobs.lazydba.com
To subscribe : http://www.LazyDBA.com
To unsubscribe: http://www.lazydba.com/unsubscribe.html

MS Sql Server LazyDBA home page