Plateforme Level Extreme
Abonnement
Profil corporatif
Produits & Services
Support
Légal
English
Limiting entries into the column
Message
 
 
À
Tous
Information générale
Forum:
Microsoft SQL Server
Catégorie:
Conception bases de données
Titre:
Limiting entries into the column
Divers
Thread ID:
00759382
Message ID:
00759382
Vues:
56
Hi everybody,

If my field can be either Y or N, how can I specify it? Or if the field can be only one of 3 predefined values?

Also, is it right to create one index with three columns? One of the fields is FK, two others just regular fields, but may be useful in joins or where clause...

I've generated relationship:
ALTER TABLE dbo.CartDetail ADD CONSTRAINT
	FK_CartDetail_CartContent FOREIGN KEY
	(
	CartContentID
	) REFERENCES dbo.CartContent
	(
	CartContentID
	) ON UPDATE CASCADE
	 ON DELETE CASCADE
	
GO
It is the same, as triggers? Or should I do something different?



Thanks in advance.
If it's not broken, fix it until it is.


My Blog
Suivant
Répondre
Fil
Voir

Click here to load this message in the networking platform