General information
Category:
Databases,Tables, Views, Indexing and SQL syntax
Title:
Need help with a table / SQL design issue.
Hello People,
I have a table set up with the following fields: date(D),fund_id(C,10),shareclass(C,10),performance(N,10,3). For every unique fund_id there are anywhere from 1 to 25 share classes with performance history over a range of dates. I want to set up a way to update the performance values for a particular fund in a tabular format. For example, if FundA has 4 share classes and is chosen it would look like:
Date Class1 Class2 Class3 Class4
01/01/01 2.2 2.0 2.3 1.9
01/02/01 -1.5 -1.3 -1.2 -1.7
.
.
.
05/25/01 5.3 4.9 5.0 5.1
Is there a way to do this with a view created from a self-join? Should I set the table up differently. There are thousands of funds, so the file would get awfully big if I had a field for each possible share class. I am new to SQL so I apologize for my ignorance if the answer to my question is obvious or if I haven't explained my problem succinctly.
Thanks in advance!
- Tony
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only