Advertisement
psi_mmobile

Untitled

Apr 15th, 2022
1,244
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
PL/SQL 0.83 KB | None | 0 0
  1. SELECT
  2.     v.vehicle_id,
  3.     v.company_nr,
  4.     v.numberplate,
  5.     v.brand,
  6.     v.model,
  7.     vc.name,
  8.     esp.name,
  9.     vc.graphical_symbol,
  10.     esp.equipment_store_place_id,
  11.     kc.key_string,
  12.     kc.key_code_usage_id
  13. FROM
  14.     vehicle               v,
  15.     vo_vehicle_category   vc,
  16.     equipment_store_place esp,
  17.     gu_vehicle            gv,
  18.     key_code              kc
  19. WHERE
  20.     v.vehicle_id = kc.vehicle_id (+)
  21.     AND v.vo_vehicle_category_id = vc.vo_vehicle_category_id
  22.     AND vc.is_object = 'Y'
  23.     AND gv.gui_user_id = 102737
  24.     AND gv.vehicle_id = v.vehicle_id
  25.     AND ( kc.active_until >= SYSDATE
  26.           OR kc.active_until IS NULL )
  27.     AND NVL(v.vehicle_status_id,0) = 0
  28.     AND v.last_equipment_store_place_id = esp.equipment_store_place_id(+)
  29.     AND NVL(v.last_equipment_store_place_id, 0) != 100015;
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement