Summarize and multiplication between tables

让人想犯罪 __ 提交于 2019-12-11 13:52:53

问题


I work in a lightrail-company, and I am responsible for the passenger counting. We have automatic passenger counting on one tram, but we have 16 trams at the most in traffic. I am looking for a way to multiply sum of boarded passengers and number of trams in traffic.

I have a MYSQL database, "Telledata".

I have two tables, "tram_usage_fri", this is a table who shows how many trams that are in use at any given time of the day.


and "Vogn217", which has all the information about passenger counting.

.

Lets take an example:
Table tram_usage_fri: Between 14:10 and 17:41 we have 16 trams in traffic.
Table Vogn 217: I want to summarize number of passengers between 14:10 and 17:41 and multiply this by 16 trams from table "tram_usage_fri".

Is this even possible?

来源:https://stackoverflow.com/questions/33916408/summarize-and-multiplication-between-tables

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!