CREATE VIEW "ur_ingest_session_file_issue" AS
SELECT us.device_id,
us.ur_ingest_session_id,
usp.ur_ingest_session_fs_path_id,
usp.root_path,
ufs.ur_ingest_session_fs_path_entry_id,
ufs.file_path_abs,
ufs.ur_status,
ufs.ur_diagnostics
FROM ur_ingest_session_fs_path_entry ufs
JOIN ur_ingest_session_fs_path usp ON ufs.ingest_fs_path_id = usp.ur_ingest_session_fs_path_id
JOIN ur_ingest_session us ON usp.ingest_session_id = us.ur_ingest_session_id
WHERE ufs.ur_status IS NOT NULL
GROUP BY us.device_id,
us.ur_ingest_session_id,
usp.ur_ingest_session_fs_path_id,
usp.root_path,
ufs.ur_ingest_session_fs_path_entry_id,
ufs.file_path_abs,
ufs.ur_status,
ufs.ur_diagnostics