Advertisement
horozov86

Task 11 - SQL

Oct 3rd, 2024 (edited)
177
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
SQL 0.66 KB | None | 0 0
  1. SELECT DISTINCT
  2. TOURNUMMER AS "Tour number",
  3. LKWKZ AS "Truck number",
  4. ANHAENGERKZ AS "Trailer number",
  5. PREISVORGABEBETRAGGS AS "Tour price",
  6. ASDGAB.BETRAG AS "Amount",
  7. SW.ISOWAEHRUNGSCODE AS "Currency tour amount",
  8. SABRZWECK.BEZEICHNUNG AS "Calculation purpose",
  9. SABRZWECK.MATCHCODE
  10.  
  11.  
  12. FROM ATOUR
  13.  
  14. JOIN
  15.     ATASEND ON ATOUR.NR = ATASEND.TOURNR
  16. JOIN
  17.     ASDGABRECHNUNG ASDGAB ON ATASEND.NR = ASDGAB.ATAID
  18. JOIN
  19.     SWAEHRUNG SW ON SW.ID = ATOUR.PREISVORGABEWAEHRUNGIDGS
  20. JOIN
  21.     atafrachtzahler ON ATASEND.NR = atafrachtzahler.TAID
  22. JOIN
  23.     SABRZWECK ON SABRZWECK.ID = atafrachtzahler.ABRZWECK
  24.    
  25. WHERE
  26.     ATOUR.TOURNUMMER IN (425608, 446595, 385378);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement