R
R
random2015-04-20 14:16:50
MySQL
random, 2015-04-20 14:16:50

How to implement a table in MySQL?

Let's say I have a table in excel as shown in the picture.
b7ec61d1e1fd4079898958a5e10a7a25.PNG
There is a column Sum, for which the value is calculated by the formula "=B3+B4", and the value of the column is equal for each row.
How can I make it so that there is no duplicate value for each row in the database?
An example of what it looks like in the database:
8a25f3cb5eae4cfe928fcfbc577ac072.PNG
You probably ask yourself why I need this ...
I have data in Excel that I will need to display this data on the site in tables (primefaces). And to take the data should from .

Answer the question

In order to leave comments, you need to log in

1 answer(s)
V
Vadim Shandrinov, 2015-04-20
@demon123

Store B3 and B4 in the plate, and calculate the amount later, after filling, on the client.
Or a separate request to the database.
(Do you know what relational databases are? no? you need to read, kmk.)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question