Advertisement
horozov86

Task 15 - SQL

Oct 10th, 2024
184
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQL 0.43 KB | None | 0 0
  1. SELECT
  2. AUFTRAGSNUMMER AS "Order number",
  3. NAME1 AS "Customer name",
  4. MIN(BISLADEDATUM) AS "First loading date",
  5. MAX(LIEFERDATUMENDEIST) AS "Final delivery date"
  6. FROM
  7.     AKOPF
  8. JOIN
  9.     SKUNDEN ON SKUNDEN.NR = AKOPF.FRACHTAGNR
  10. JOIN
  11.     ASENDUNG ON AKOPF.NR = ASENDUNG.AKOPFNR
  12. JOIN
  13.     ATASEND ON ASENDUNG.SENDUNGID = ATASEND.ASENDUNGID
  14. WHERE
  15.     AUFTRAGSNUMMER IN (946030, 951548)
  16. GROUP BY
  17.     AUFTRAGSNUMMER,
  18.     NAME1;
  19.  
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement