Click here to Skip to main content
11,573,618 members (44,188 online)
Rate this: bad
good
Please Sign up or sign in to vote.
See more: C# Homework SqlServerm
Hi,

My application task is I am going to develop one super market application in this scenario. The user enter product code and user description
start date and end date, product rate, and quantity. My question is product rate based on date in varies rates.
Example: we will get soap this product 15th October to Nov 7th Rs.20/-. The same product Nov 8th between Dec Rs.23/- The same product change for Dec 15th Between Jan 12th Rs.19/- . How design database for this application and how to write class and method for this application.
Posted 29-Aug-12 3:54am
Edited 29-Aug-12 4:16am
v3
Comments
Nueman at 29-Aug-12 10:02am
   
Your question reads like a homework assignment. In any case, it seems much too broad. My suggestion is to start working on it and post relevant smaller problems.
Marcus Kramer at 29-Aug-12 10:17am
   
Clearly homework. Read over your course notes first and make some attempt to do your own work. When that fails, ask a specific question related to the point where you got stuck. We will be very happy to help you at that point.
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 1

Nueman is right. Your question is too broad. Too general. You do not provide enough information. Without knowing the requirements of your application it's very hard to help you. You ask for a class or method for this application...but a class or method that does what? Are you adding or updating products in your product table? Are you placing an order from a customer? Are you placing an order to a supplier? You need to be much more specific if you want real help.

If you don't even know where to start, you should google for some basic tutorials. Google Results[^]

The very first result is a Code Project article:Beginners guide to accessing SQL Server through C#[^]

This should get you started. Hope it helps.
  Permalink  
Rate this: bad
good
Please Sign up or sign in to vote.

Solution 2

Hi,

After giving some thought i come to one solution. this is my personal view, you can do this with many other ways.

You need to create one table which may contain
ProductID - your product identity value
ProductVariationPercentage - you need to calculate what percentage you required to increase your product value from 20 to 23.
AffectedDate - The date from when this percentage should increase.

Note : your base price will be in your product database itself.

Although this is really very basic stuff but i think you are very new with development, And i hope you will develop this functionality from above hint.

You also need to do a lot of validation and other work in your BusinessLayer(if you are following 3Tier/NTier Architecture). Like, product price should have some threshold value, threshold value should not cross even if defined(Alert should be generated).

Hope i answered your question
Thanks
-Amit Gajjar
  Permalink  

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS


Advertise | Privacy | Mobile
Web03 | 2.8.150624.2 | Last Updated 29 Aug 2012
Copyright © CodeProject, 1999-2015
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100