How to split table with >1.000 Columns
Posted by: Martin Weil
Date: January 20, 2021 06:30AM

Hi there,

I have one measurement device (scientific purpose) which generates about 850 values every 10 seconds (800 of those are sensoric data, the rest are additional info).

I need to store all these 800 sensor values in a DB and FLOAT is not an option, since it is not precise enough, so it has to be DOUBLE.

In the future, there might even be an upgrade to my hardware which could result in even more colums of sensoric data.


So I would ask for a feedback on my design idea:

Make a DB and create three tables:
- sensor1
- sensor1_values01
- sensor1_values02

Table "sensor1" would have the 50 "other" columns like
"id" (auto increment)
"date"
"time"
...

Table "sensor1_values01" would have the first 400 DOUBLE columns
"id" (auto increment)
"ref_id" [which would point to "sensor1.id"]
"i1"
...
"i400"

and so on.

My question is: does this seem ok or are there obvious flaws in this design? (400x DBL should not be a problem regarding the Max-Row-Size of about 8.000 Byte and it would be easy to add more columns with addition "sensor1.valuesNN" tables).

Thank you for your advice
Martin

Options: ReplyQuote


Subject
Written By
Posted
How to split table with >1.000 Columns
January 20, 2021 06:30AM


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.