Tina K
asked on
Multiple functions in SQL select statement
For some reason, this really has me stumped. I'm trying to retrieve the max transaction id from the inventory_transaction table, but also need to sum up some costs. As soon as I start adding any of the costs, no matter how I do it, the max(inventory_trans) fails and I get a record for each different cost.
Example - this works:
This doesn't: I get 151 records, rather than the max:
Also doesn't work:
Any help appreciated!
Example - this works:
This doesn't: I get 151 records, rather than the max:
Also doesn't work:
Any help appreciated!
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
ASKER
That did the trick Scott! Thanks so much!
FROM ...
WHERE ...
GROUP BY part_id