0% found this document useful (0 votes)
71 views14 pages

Cs Project Sample

Uploaded by

nehahosad21
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
0% found this document useful (0 votes)
71 views14 pages

Cs Project Sample

Uploaded by

nehahosad21
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 14
Names: 1. Vatsal Sanjeevkumar Dudhaiya 2. Daksh Mathur 3, Shubhang Srinivasan Class: 12 CBSE Roll Number: 27610736 School: NPS International School Year: 2021-22 Date of Submission: 22 - 03 - 2022 Project Title: Departmental Store Database Simulation Toy Table of Contents Page Number Acknowledgements 2 Objective Technical Documentation User Documentation > Structure of the Database * Modules Structure of the Code g 4 5 SQL Statements for creation of table * Item Table © Item Stock Table Customer Table Membership Table Order Table Cart Table Python Code ae Sample Output 8. Bibliography a I, Vatsal Sanjeevkumar a thanks to my teacher, Shukla, for her constant support and guidance. —_ I would also. pursue the topic of my choice for my Computer providing me the resources to do'so with ease. OBJECTIVE: The objective of this project is to simulate all f Python program, linked with SQL, included in this that would allow the proper functioning of a departmental The project would allow the inventory and organisation of in a database. The database will then be used to ext preference. For instance, customers can view the alter the records in the tables. Customers can also c1 be added them from the item list. xH000.€ sHO00 a TECHNICAL DOCUMENTATION: - Yatsal S. Dudhaiya Device 1: Lenovo IdeaPad 300-141SK | RAM: 8.00 GB p F OS: Windows 10 Home nemeer nae Dee: Processor: Intel(R) Core(TM) i5-6200U CPU. @231 s Structure of The database o| Device 2: Lenovo, ‘ThinkCentre Desktop ~ Inthe Item RAM: 8.00 GB the table a OS: Windows 10 Pro. Price (float Processor: Intel(R) Core(TM) i7-7700 CPU @3.60GH2, 3.60GHz - The Item: matches grocery lis Device 1; ASUS, VivoBook XS13EP eae therefore, RAM: 16.0 GB Cue OS: Windows 10 Home “oe Processor: 1 Ith Gen Intel(R) Core(TM) i7-1165G7 @280GHz 2.80 GHz sage (inte Device 2: Lenovo ThinkCentre Desktop anf Weak RAM: 8.00 GB mentee OS: Windows 10 Pro Processor: Intel(R) Core(TM) i7-7700 cpu @3.60GHz, 3.60GHz USER DOCUMENTATION: SSE SOCUMENTATION: Project Title: Departmental Store Database Simulation Structure of the database: The database of the departmental store contains the following tables: - Inthe Item Table, all available items in the store will be displayed. The columns in the table are Item Code (string), Item Name (string), Item Category (string) and Item Price (floating point value). - The Item Stock table displays the real-time quantity of items in our store which matches with the corresponding item code to help the customer make changes to his grocery list accordingly. As customers add or remove items from their respective Carts, the stock in this table is updated accordingly. The columns in this table, therefore, are the Item Code (string) and its quantity available (integer number). - A Customer Table maintains a customer list with their names (string) and contact details including the residential addresses (string) as well as a phone number (integer) sage (integer) & gender (string) fields are optional - can be filled in as null). A unique Customer ID (integer) is given to each customer. - A Membership Table keeps track of the date since a particular customer became a member. It also has the Customer ID column which matches with the one in the Customer, Table, bb o} zed ono zouiny 1 ‘An Order table will be maintained for the store owner's convenience. It would list the details of all the Orders. This will include the eae (integer), the Order 10 SOFC 10 No (integer), the date of purchase, the Item tem No (i of the item (integer value), the | applied. - A Cart table will also be (float) and Price (float). This opened. id o1 Si bbe. ay 6-4 nog eau Term-2 | Computer S hint Structure of the code The program will firstly display the main menu wherein the user will choose their deg. course of action. The menu will have the following choices: sit 1. View Database a. Customers i, Full table containing all information ii, Specific (by Customer ID) b. Items. i. Full table containing all information ii, Specific (by Item Category) c. Stock i. Full table containing all information ii, Specific Category (by Item Code) d. Orders acy aoe containing all information ii. gain) Ci samt le to proc rae sda, Ad b. The contents of the Cart will be displayed on screen and the user will be asked to confirm whether the contents of the Cart are accurate or if they would like to make changes. ©. Once the Cart has been finalized and no more updates are to be made, the customer is asked if they are a member. i. If they are a member, then they are offered individual discounts on all items (regardless of price) if the total purchases are over $60 based on the number of years they have been a member. Once their discount is calculated, their bill is printed. ii, If they are not a member, then they receive no discounts and their bill is printed immediately. 4. Becoming a member If the customer chooses to become a member, they are required to enter their information. A new Customer ID is assigned automatically. These values are then added to the Customer and Membership tables and the record for the new member is successfully created. Cancelling your membership The member is first asked to confirm whether they wish to terminate their membership. If confirmed, the member is required to enter their present Customer ID and their record is deleted from the Custom and Membership tables. 6. Exit y old Ends the while Joop and the programs caste uaa all nora again. lev eldsTans > » sapubeas BAilmee!2" ,' (in 20 5. ITEM TABLE create table Itemfable (Item ItemName text, ItemCategory insert into ItemTable s Set’, 'Utensils',24.99) insert into Itemfable Pan’, 'Utensils',28.00) Set', 'Utensils', D, 2)) cry print ("Shut down successful") break else: print ("ERROR! Invalid output, please try again.") Sample Outputs: Python 3.7.4 (default, Aug 9 2019, 18: (anvea)} Type "copyright", “credits” or “license” for more information. 313) [MSC v-1915 64 bit IPython 7.8.@ -- An enhanced Interactive Python. In [2]: runfile(*C:/Users/sec3/Desktop/shubhang/Project 2021-2022/CS Project - SQLPython Interface.py”, wdir="C:/Users/ sec3/Desktop/shubhang/Project 2021-2022") Welcome to the online Singapore Greenhome Grocery store - 2 fresher approach in life. What would you like to do today? 1. View Database, 2. Update database, 31 create cart, : 2. would you like to become a member? JOIN US for EXCLUSIVE DEALS and DISCOUNTS, yom C18" heOBEOE. .P . 277 Lbncel your membership - We're sorry to see you gol =~ mae " gs sey Doug 2nd Sa meiedg iY «1 ‘A. View complete Customer table, 8. Search the table by Customer ID: a Coos, Goo, Geos, Geos, (1004, (aes, Gees, (eer, Geos! Geos, Gere! Gen, Gen? | Ges; | Gore, Geis, Gere, Gow, Gore, Geis, Goze, Qeai, |caoz2; Gees, (ae24, (e2s, (e2s, (1927, | ez, (ae23, What would you like to do today? 1. View Database,” ments,Dahlia street 450eag° ‘Leslie Knope’, “F', 50, 99090123, “10-02, White Tiger Apartments,Dahl on Nee eee ee ee ee onasesenias) “fag Perkins’ (F's a5, 96249323, #18-04, Sunmyland Colony, Evergreen, Lane 430022") [Andy Dwyer", "M", 40, 88730751, "#17-09, SE a ees ‘April Ludgate", ‘r","32, 96831271, "49/8, Villa Street, 3, HG. - ‘Michael. Scott, 'w", "so, 91843376, "127-01, Highrise Apartments, H.-G ee) dame taleerths ths ab, shesnas, hie-11,"sionyland Colony, evergreen Lane 4s90zz:) “Drighe ic Senrie’,”"H", 55, 4636503, “40i-03, sunnyland Colony, Evergreen Lane, 4segz2') {Saul Goodman’, "M", 39, 84538920, '#11,02, Sunnyland Colony, Evergres 2 ? (Malter White’; °N') 65, 96725463, ‘#21, Villa Street, 450013") TAnnie Edison’, “F', 29, 90174538, "#35, Villa Street, 450013") 150033") iSeittany Perry", “F', 31, 95492463, ‘825-05, Highrise Apartments, 4: rQlaire Dunphy", “F:, 41, 87453201, "#29/D, Villa Street, 450012") (Matthew Murdock’, °N', 36, 93541642, "#8 , ButterCorn Housing, 450091") ikgren Page", °F", 33, 91658392, "#9, Jellysean Villas, 450088") [Elizabeth Jennings", °F", 25, 83581518, ‘#10, Gumyorm Duplex 450077") iMilson Fisk’, “M", 62, 83558264, "#55-01, SuperTall Apartments, 450068" ) Tay Gupta’, “m", 23, 82239504, *soi-o1, Megatiall Flats, 450066") {Rani Madhavan", ““F", 30, 92753212, “#10-09, Megatiall Flats, 450066") ‘Mehana Ali", “F', 24, 98735637, “#11-01/8, Supertouses, 450089") iBen Myatt", “M', 38, 91353500, *#10/c, MultiCool Flats, 450001") {armanpreet Singh’, “F*, 30, 92119751, “831/8, Osborn-i1, Morning Lane, 450021") Ttuke Skywalker’, “M", 44, 97710252, "#12-06, Beanbag Heights, Marty Lane, 450034") [hela Organa’, “F*, 47, 98906724, ‘#13-04, Beanbag Heights, Marty Lane, 450034") [Han Solo", “M', 74, 84372067, ‘foS-01, Beanbag Heights, Marty Lene, 450034") T3ynn Erso’, “F*, 25, 96032544, "#12, Sunnyside, Devils Lane, 450034") sare /bsera/sea/Oektoy/ alba GEE ac Iyleose to the online ‘Singapore Greenhowe Grocery store - a fresher approach in life. | | Ipat would you Tike to do today? |}, View Database, Update database, | create cart, yould you Like to become a menber? JOIN US for EXCLUSIVE DEALS and DISCOUNTS, * Cancel your menbership - We're sorry to see you go! 5, Bit 3 Jenter Item Code to add to cart I ‘Enter’ to complete order or X to cancel order fnter quantity: 2 fnter Iten Code to add to cart ress ‘Enter’ to complete order or X to cancel order ((u, ‘Stainless Steel Pan’, 2.0, 56.0) [Is everything in the cart correct? (yin) 3 (art has been finalised. Is the customer a member? (y/n)y_ i) walang 910 1 nag 0} wold o2 Statntess steed oa Total Cost: $56.0 Costomer 10: 1009 Exctusive offers Starting to!!! a sore than $50 [Become 2 member row and youll receive massive discounts on all purchase of Tres € conditions apy > Tat"you for shopping + STORE Nie ie hope to se you ogeine

You might also like