Creating dynamic tables

D

Dennis Grant

I am designing a cd-rom using macromedia flash. The flash product calls the text from the database and the page is dynamically displayed. This has allowed the content to be amended etc easily.

However, i now have a new challenge! I wish to store in the database the contents of a table, which needs to be drawn from data in the database.

The layout of the table (appearance) will be dealt with in Flash. I need a way to store the information easily. The number of columns / column headings needs to be created dynamically, there are many different tables to be displayed all with different headings/rows/columns etc.

The display tables are to be linked to a specific page being displayed in flash.


Any suggestions would be appreciated.

Thanks

d.


Requirements For Table Data

| = The divider between each row/column value
¦ = End of columns, start of rows divider

i.e.

question="Height|Area|Age¦Darrel|Dennis|Clive";
answer="6'2|Carlton|31¦5'11|Top Valley|30¦6'0|Mapperley|39";

This example consists of 3 rows and 3 columns


Height
Area
Age

Darrel
6'2
Carlton
31

Dennis
5'11
Top Valley
30

Clive
6'0
Mapperley
39


I simple way of entering this information into a form.

Enter how many columns you require with each heading
Add a row and enter row heading
Enter data for current row, column 1 (then column 2 and 3 and so on)

Once this has been done the values and headings need to be constructed in the same format as the example above.

I think it may need 2 tables. The first is where the raw data goes .

Section No
Sub No
Page No
Column No
Column Heading
Row No
Row Heading
Field No
Field Value

Then a query can format the data and place it into Questions & Answers table.

Question=Column Heading in Column No 1 + "|" + Column Heading in Column No 2 +"|"+ Column Heading in Column No 3 + "¦" + Row Heading in Row No 1 +"|"+ Row Heading in Row No 2 +"|"+ Row Heading in Row No 3

Answer=Field Value in Field No 1 +"|" Field Value in Field No 2 +"|" Field Value in Field No 3 +"¦"+ Field Value in Field No 4 +"|" Field Value in Field No 5 +"|" Field Value in Field No 6 +"¦"+ Field Value in Field No 7 +"|" Field Value in Field No 8 +"|" Field Value in Field No 9
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top