Home Forums SQL Server 2008 T-SQL (SS2K8) SQL Server Table Structure, StartDate and EndDate RE: SQL Server Table Structure, StartDate and EndDate

  • interesting wissam;

    the excel spreadsheet you receive, does the start and end date apply only to the short term offer? so for one month some rate is slightly cheaper, but the table Tariffs contains the regular/default rates?

    in that case, i would consider a separate table for the Discounts, and join the two tables together based on the EndDate, using the DiscountRate if todays date is still valid; i don't think you want to update the master table with the rates, and then try to back out those changes after the end period.

    Lowell


    --help us help you! If you post a question, make sure you include a CREATE TABLE... statement and INSERT INTO... statement into that table to give the volunteers here representative data. with your description of the problem, we can provide a tested, verifiable solution to your question! asking the question the right way gets you a tested answer the fastest way possible!