What is the best way to create table in SQL database for my situation? Option 1 or Option 2?
TMyRecord = record
id : integer;
name : string;
price : Array [0.100] of double;
If i want to create table in SQL database,
Option 1: - Creating one table and use ID and Name for all price entries.
CREATE TABLE My_Record
(
ID int,
Name varchar(255),
price float,
);
or Option 2: - use two tables and link each other?
CREATE TABLE My_Record
(
ID int,
Name varchar(255),
price float,
PRIMARY KEY (P_Id)
);
CREATE TABLE My_Record_ArrayData
(
FOREIGN KEY (ID) REFERENCES My_Record(ID)
price float,
);
Thanks in advance.