In the real world a good developer would ask the users/customer what they want. In your case your customer/user is your prof.
PS: What prof./teachers want and what is done here in the real world can be very different. We could show you how we do it in the real world but that might not be what the prof wants/ So you get a bad grade.
If you do not elaborate your question a little more by providing some explanations about your project and the problem you have to solve, your chances of receiving an aswer that could help you are very few .
Everybody is not ready to dig in an unknown database and spend time trying to figure out what you want precisely.
hi thanks for showing interest. the question i asked before i managed to answer myself...
there is another problem i m having...
there are six drivers and six cars . two drivers owns the car while four other drivers drives companies car.
those who drives their own car gets 70% of the money back n those who drives company car gets 50% of the money.
i did something like that..
Invoice Paid: [Cost iN Dollars]*0.5
cost in dollars is the total what they make.* 0.5 for the company car drivers . for example 30 * .5 = $15 that's how much a company car drivers make for one ride.
do i have to make two different invoices for those who owned car n companies car or do i have to add them in the same coding...
Don't make different invoices. Add a column (field) into the Drivers table containing the multiplicator you use into the computation. This way it would be easier to update the system if the rules change (say 50% becomes 45%). This way you'd just have to modify the values into a table as nothing is hard coded. Ideally these rations should be stored into a separate table, though.
The clever way ( according to my mind) consists in creating a Lookup table with the time zones: Tbl_TimesZones with (at least) 2 columns: TZ_Code, Text(1), Primary key and TZ_Value, Long. In SQL we can then use:
SELECT DateAdd("n",[TZ_Value],[TimeDepart]) AS TTime
FROM Table1 INNER JOIN Tbl_TimeZones ON Table1.TimeZone = Tbl_TimeZones.TZ_Code;
Otherwise you'll have to use a serie of cascading IIf's which can be hard to understand (and to debug!) and that can quickly become unmanageable when the number of possibilities increases (only 3 in your question):
IIf([TimeZone]='C',DateAdd("n",90,[TimeDepart]),[TimeDepart]))) AS TTime