Skip to content
Advertisement

Group by Latest value

I only want to show the latest value. Here is the table: InstanceID InstanceDate TotalProjects 1 2021-10-14 69 1 2021-10-12 70 2 2021-10-14 20 3 2021-10-14 89 3 ​ 2021-10-13 99 3 2021-10-11 100 4 ​ 2021-10-12 12 4 2021-10-14 13 5 ​ 2021-10-14 0 Here is the query I used to get this table: This is what I want:

Column or global variable not found db2

I have a issue with DB2. I have two libraries with the same structure database. The only one difference is the data. When i try this sql request for the first library, it’s work but when i try with the other library, i have this error. I check the CLIENT and EMPLOYE tables and they have the column with data.

Add new column in SQL query

I want to use the result of query to create new column in order to to find the change of freight to the revenue The original question is What is the impact on revenue of the additional 10% in freight. I am currently using Northwind dataset SQL query does not work as it does not recognize new variable “New” and

Advertisement