Baixe o app para aproveitar ainda mais
Prévia do material em texto
Table 1-5. Attributes of the S_customer table. Column Name Description/Data "pe id Customer unique identification number. Maximum is 3 characters. Name Name of the customer. Maximum is 20 characters. Phone Telephone number of customer. Maximum is 20 characters. Address Address of customer. Maximum is 20 characters. City City where customer is located. Maximum is 20 characters. State State where customer resides. Maximum is 15 characters. Country Country where customer resides. Maximum is 20 characters. Zip_ code Zip code of customer. Maximum is 15 characters. Credit_ rating Credit standing of customer. Maximum is 9 characters. Sales_ rep_ id Sales representative of customer. Maximum is 3 characters. Region_ id Region in which the country of the customer is located. Maxrmum is 3 characters. Comments Product preferences of customer. Maximum is 255 characters. Table 1-6. Attributes of the S_dept table. Column Name Description/Data Type id Unique identification number assigned to each department. Maximum is 3 characters. Name Name of the department. Maximum is 20 characters. Region-id Region ID in which the department is located. Maximum is 3 characters. Table 1-7. Attributes of the S_emp table. Column Name Description/Data "pe id Unique identification number assigned to each employee. Maximum is 3 characters. Last_ name Last name of employee. Maximum is 20 characters First_ name first name of employee. Maximum is 20 characters. Userid Login ID of employee. Maximum is 8 characters. Start_ date Date in which employee started working in the company. Date data type. Comments Information about employee. Maximum is 25 characters. Manager_ id ID of the employee's manager. Maximum is 3 çharacters Title Title of the employee in the company. Maximum is 25 characters. Dept_ id ID of the employee's department. Maximum is 3 characters. Salary Salary of the employee. 11 digits including 2 decimals. Commision_ pct Percentage of commission earned by employee. 4 digits including 2 decimals. Table 1-8. Attributes of the S_region table. Column Name Description/Data Type Unique identification assigned to each region. Maximum is 3 characters. Name Unique name of each region. Maximum is 20 characters. Table 1-9. Attributes of the S_inventory table. Column Name Description/Data "IYpe Product_ id Unique identification number of the specialty product. Maximum is 7 characters. W arehouse_ id ID of the warehouse where the product is stored. Maximum is 7 characters. Amount_ in_ stock Amount of items in stock. Maximum is 9 digits. Reorder_ point Minimum number of items in stock before reordering. Maximum is 9 digits. Amount_ in_ Stock Maximum number in stock. Maximum is 9 digits. Out_ of_ stock_ explanation Reason why product is not in stock. Maximum is 255 characters. Restock_ date Date when product will be again in stock. Date data type. Table 1-10. Attributes of the S_item table. Column Name Description/Data "pe ord_ id ID of the order associated with this item. Maximum is 3 characters. item_ id Unique identification number assigned to each item. Maximum is 7 characters. Product_ id ID of the product associated with this item. Maximum is 7 characters. Price Price of item. Maximum is 11 digits including 2 decimals Quantity Quantity of this item. Maximum is 9 digits. Quantity_ shipped Quantity shipped of this item on this order for a given product. Maximum is 9 digits. Table 1-11. Attributes of the S_product table. Column Name Description/Data "pe id Unique identification number assigned to each product. Maximum is 7 characters. Name Name of the product. Maximum is 25 characters. Short_ desc Description of the product. Maximum is 255 characters. Suggested whlsl_ price Suggested wholesale price of product. Maximum is 11 digits including 2 decimals. Whlsl_ units Units of product for wholesale. Maximum is 10 characters. Table 1-12. Attributes of the S_warehouse table. Column Name Description/Data Type id Unique identification number assigned to each warehouse. Maximum is 7 characters. Region_ id Id of the region where the warehouse is located. Maximum is 3 characters. Address Address of the warehouse. Maximum is 20 City City in which the warehouse is located. Maximum is 20 characters. State State in which the warehouse is located. Maximum is 15 characters Zip_ code Zip code of the city where the warehouse is located. Maximum is 15 characters. Country Country in which the warehouse is located. Maximum is 20 characterx Phone Telephone number of the warehouse. Maximum is 20 characters. Manager_ id ID of the manager of the warehouse. Maximum is 3 characters. Table 1-13. Attributes of the S ord table. Column Name Description/Data Type id Unique identification number assigned to Maximum is 3 characters. Customer_ id Customevynique identification number. Maximum is 3 characters. Date_ ordered Date in which order was placed. Date data type. Date_ shipped Date in which order was shipped. Date data type. Order_ filled Unique identification number of sales representative that took the order. Maximum is 3 characters. Total Total amount of this order. Maximum is 11 digits, including 2 decimals. Payment_ type Form of payment. Maximum is 6 characters. Order filled _ Indicator of whether or not the order has been filled. Maximum is 1 character. Table 1-14. Integrity constraints of the SG database. Table Name Foreign Key Referenced Attributerrable S_DEVI' region_id id of table S_REGION S_EMP manager_id id of table S_EMP S_EMP dept_id id of table S_DEVr s EMP title title of table S_TITLE S_CUSTOMER sales_rep_id id of table S_EMP S_CUSTOMER region_id id of table S_REGION S_ORD customer Id _ id of table S CUSTOMER S_ORD id of table S_EMP S_ITEM ord_id id of table S_ORD S ITEM _ product_id id of table S_PRODUCT S WAREHOUSE _ manager_id id of table S EMP S_WAREHOUSE region_id id of table S_REGION s INVENTORY product_id id of table S PRODUCT S INVENTORY _ warehouse_id id of table S_WAREHOUSE
Compartilhar