this is how my final
jsp table shoul look like :
metric1 metric2 metric3
ProjAttrib1
ProjAttrib2
subProjAttrib2
projAttrib3
heres what I was able to come up with and the tables I have are :
Projdetail (contains PK pid)
projattribs(pid FK references pid from projdetails and contains a list of projattribs for a proj)
projsubattribs(subattribId FK references projattribid from projattribs, pid FK references pid from Projdetail)
projmetrics (pid references pid from proj detail and a list of metrics for a proj)
This form will take inputs and store into a table called projmetricsdata(contains pid, attribid, subattribid, metricid, metricdata, dataid).
So, my question is :
1) is the above design (ignoring the naming conventions and typos), good enough ?
2) I am trying to form a query with the plain old sql and trying to come up with queries for
1) displaying the left col with proj attrib details
2) displaying metrics row on.
So, for 2.2) all I need is a
java bean populated with the metric table values.
but for 2.1, I dont know how I will populate this(probably using a join). I think I will need to use a join for this, but then, how would I populate the sub attribs for this (in java) ?
And another question I had was, say everything eventually happens and I need to take the inputs from the HTML table in JSP, how would I map the required text box to the required tables ? Ok, as I write this, I think think I can make use of the pid and attrib/sub attib id and make a way with this.
cheers,