Addition of two mysql query results

mysql

#21

an auto_increment is not going to work for this

you should have a skinny and tall table – one temperature per time, many rows

e.g.

CREATE 
  TABLE astb 
      ( temptime DATETIME NOT NULL
      , temp INT NOT NULL
      , PRIMARY KEY ( temptime, temp)
      )

your queries will be simpler then too


#22

thank you. so you mean I should use the same query structure too?


#23

yes, but instead of the query calculating16 differences, there’s only one

it’s up to you though

did you understand my comment about summing a string?


#24

no, i didn’t understand your comment there.


#25

in SUM('tcount'), 'tcount' is a character string

in SUM(tcount), tcount is a column name