Difference between revisions of "Sales.ShoppingCartItem (table)"

From dbscript Online Help
Jump to: navigation, search
Line 12: Line 12:
  
  
 +
=== Columns ===
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|- style="background:silver"
 
|- style="background:silver"
Line 18: Line 19:
 
| '''Nullable
 
| '''Nullable
 
| '''Default
 
| '''Default
| '''Description / PK / Index
+
| '''Description
 
 
 
|- valign="top"
 
|- valign="top"
Line 25: Line 26:
 
| not null
 
| not null
 
|  
 
|  
| Primary key for ShoppingCartItem records.<br />PK_ShoppingCartItem_ShoppingCartItemID
+
| Primary key for ShoppingCartItem records.
 
|- valign="top"
 
|- valign="top"
 
| ShoppingCartID
 
| ShoppingCartID
Line 31: Line 32:
 
| not null
 
| not null
 
|  
 
|  
| Shopping cart identification number.<br />IX_ShoppingCartItem_ShoppingCartID_ProductID
+
| Shopping cart identification number.
 
|- valign="top"
 
|- valign="top"
 
| Quantity
 
| Quantity
Line 37: Line 38:
 
| not null
 
| not null
 
| ((1))
 
| ((1))
| Product quantity ordered.<br />
+
| Product quantity ordered.
 
|- valign="top"
 
|- valign="top"
 
| ProductID
 
| ProductID
Line 43: Line 44:
 
| not null
 
| not null
 
|  
 
|  
| Product ordered. Foreign key to Product.ProductID.<br />IX_ShoppingCartItem_ShoppingCartID_ProductID
+
| Product ordered. Foreign key to Product.ProductID.
 
|- valign="top"
 
|- valign="top"
 
| DateCreated
 
| DateCreated
Line 49: Line 50:
 
| not null
 
| not null
 
| (getdate())
 
| (getdate())
| Date the time the record was created.<br />
+
| Date the time the record was created.
 
|- valign="top"
 
|- valign="top"
 
| ModifiedDate
 
| ModifiedDate
Line 55: Line 56:
 
| not null
 
| not null
 
| (getdate())
 
| (getdate())
| Date and time the record was last updated.<br />
+
| Date and time the record was last updated.
 
|}
 
|}
  
 +
=== Primary Key ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Primary Key
 +
| '''Columns
 +
|-
 +
| PK_ShoppingCartItem_ShoppingCartItemID
 +
| ShoppingCartItemID
 +
|}
  
 +
=== Indexes ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Index
 +
| '''Type
 +
| '''Columns
 +
 +
|-
 +
| IX_ShoppingCartItem_ShoppingCartID_ProductID
 +
|
 +
| ShoppingCartID, ProductID
 +
|}
  
 +
=== Check Constraints ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Check Constraint
 +
| '''Expression
 +
| '''Description
 +
 +
|-
 +
| CK_ShoppingCartItem_Quantity
 +
| ([Quantity]>=(1))
 +
| Check constraint [Quantity] >= (1)
 +
|}
 +
 +
=== Foreign Keys ===
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 
|- style="background:silver"
 
|- style="background:silver"
Line 72: Line 108:
 
|}
 
|}
  
 +
=== References ===
 +
{| border="1" cellpadding="5" cellspacing="0" style="border-collapse:collapse"
 +
|- style="background:silver"
 +
| '''Dependency Type
 +
| '''Object Type
 +
| '''Referenced Object
 +
 +
|-
 +
| Schema
 +
| Schema
 +
| [[Sales_(schema)|Sales]]
 +
 +
|}
  
  

Revision as of 00:06, 3 February 2010

wikibot

Table Sales.ShoppingCartItem
Description Contains online customer orders until the order is submitted or cancelled.


Columns

Column Data Type Nullable Default Description
ShoppingCartItemID int not null Primary key for ShoppingCartItem records.
ShoppingCartID nvarchar(50) not null Shopping cart identification number.
Quantity int not null ((1)) Product quantity ordered.
ProductID int not null Product ordered. Foreign key to Product.ProductID.
DateCreated datetime not null (getdate()) Date the time the record was created.
ModifiedDate datetime not null (getdate()) Date and time the record was last updated.

Primary Key

Primary Key Columns
PK_ShoppingCartItem_ShoppingCartItemID ShoppingCartItemID

Indexes

Index Type Columns
IX_ShoppingCartItem_ShoppingCartID_ProductID ShoppingCartID, ProductID

Check Constraints

Check Constraint Expression Description
CK_ShoppingCartItem_Quantity ([Quantity]>=(1)) Check constraint [Quantity] >= (1)

Foreign Keys

Relation Column Referenced Column
Production.Product ProductID ProductID

References

Dependency Type Object Type Referenced Object
Schema Schema Sales


automatically generated

Table Sales.ShoppingCartItem
Description Contains online customer orders until the order is submitted or cancelled.


Column Data Type Nullable Default Description / PK / Index
ShoppingCartItemID int not null Primary key for ShoppingCartItem records.
PK_ShoppingCartItem_ShoppingCartItemID
ShoppingCartID nvarchar(50) not null Shopping cart identification number.
IX_ShoppingCartItem_ShoppingCartID_ProductID
Quantity int not null (1) Product quantity ordered.
ProductID int not null Product ordered. Foreign key to Product.ProductID.
IX_ShoppingCartItem_ShoppingCartID_ProductID
DateCreated datetime not null (GETDATE()) Date the time the record was created.
ModifiedDate datetime not null (GETDATE()) Date and time the record was last updated.


Relation Column Referenced Column
Production.Product ProductID ProductID


Dependency Type Object Type Referenced Object
Schema Schema Sales