newbie questions about composite key
Posted by: Noel Keene
Date: September 30, 2007 03:22PM

Hi,
I'm in a bit of a conundrum here. I've spent a while creating scripts to parse weather data, and now I'm trying to develop a database to house them in a way that makes it easy and effective to relate and reference the data. The problem I'm running into is that I've got several groups of data (i.e. wind data, rain data, etc) and am planning to put them into separate tables. Some of that data is placed into the table every hour while others are every three hours and some just once a day. So, I'll have a date and time for each table that would perhaps require a composite key...that's the direction I'm heading in. I'll need to reference this data by date (i.e. show and relate certain weather data from a day when a storm came in) but the date will be the same for several rows since the data is stored multiple times per day. Here's an example where script checks for temperature aloft and stores it twice a day.
DATE(local) TIME(Zulu) Temp Aloft
08-24-2007 12 14
08-24-2007 00 12
08-25-2007 12 15
08-25-2007 00 14

And data from script that checks for windshift every hour and records one if it occurred, NULL if not.
DATE(local) Time(Zulu) WindShift
08-24-2007 19 NULL
08-24-2007 20 NULL
08-25-2007 21 21
08-25-2007 22 NULL

I've seen many examples of tables with ID numbers and such for primary keys, but I don't think I can do that, since the date is important in referencing weather events. Any thoughts, or are my questions way to unclear? Thanks for any help,
Shad

Options: ReplyQuote


Subject
Written By
Posted
newbie questions about composite key
September 30, 2007 03:22PM


Sorry, you can't reply to this topic. It has been closed.

Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.