I'm sorry TITLE is not so specific. I will try to explain: I am new to SQL. I work and wrote a query that contains 9 columns that extract information from many tables. on the 9th column the names of the types of machines are indicated, and on the third - a value representing the time during which the machine worked for a month. I need to add the 10th column, which will have for each type of machine, the maximum of the 3rd column for this type. let's say there are 5 XR machines (5 rows in the table) with time (3rd column) 1,2,3,4,5 (in hours). I need that in the 10th column, all the rows where the type of machine is XR will be 5, since this is the maximum for this type of machine.
How should I do it?
Any help would be greatly appreciated!
source
share