Hi, in proc sql for sas i have this query to calculate TIME_FOR_REPLY (operations with timestamp). SELECT (CASEWHEN Wcs_dashboard_interaction.END_TIMESTAMP is null AND Wcs_dashboard_interaction.DISPATCH_TIMESTAMP IS NULL AND Wcs_dashboard_interaction.START_TIMESTAMP IS NOT NULL THEN (MAX(Wcs_dashboard_session.END_TIMESTAMP) - MIN(Wcs_dashboard_session.START_TIMESTAMP)) WHEN Wcs_dashboard_interaction.END_TIMESTAMP is null AND Wcs_dashboard_interaction.DISPATCH_TIMESTAMP IS NULL AND Wcs_dashboard_interaction.START_TIMESTAMP IS NULL THEN (MAX(Wcs_dashboard_session.END_TIMESTAMP) - MIN(Wcs_dashboard_session.START_TIMESTAMP)) WHEN Wcs_dashboard_interaction.END_TIMESTAMP is NOT null AND Wcs_dashboard_interaction.DISPATCH_TIMESTAMP IS NOT NULL THEN (MAX(Wcs_dashboard_interaction.DISPATCH_TIMESTAMP) - MIN(Wcs_dashboard_session.START_TIMESTAMP)) WHEN Wcs_dashboard_interaction.END_TIMESTAMP is null AND Wcs_dashboard_interaction.DISPATCH_TIMESTAMP IS NOT NULL THEN (MAX(Wcs_dashboard_interaction.DISPATCH_TIMESTAMP) - MIN(Wcs_dashboard_session.START_TIMESTAMP)) WHEN Wcs_dashboard_interaction.END_TIMESTAMP is NOT null AND Wcs_dashboard_interaction.DISPATCH_TIMESTAMP IS NULL THEN (MAX(Wcs_dashboard_session.END_TIMESTAMP) - MIN(Wcs_dashboard_session.START_TIMESTAMP))ELSE '00.00.00'tEND) AS TIME_FOR_REPLY FROM UNIBANK_ASYNC.Wcs_dashboard_session Wcs_dashboard_session LEFT JOIN UNIBANK_ASYNC.Wcs_dashboard_interaction Wcs_dashboard_interaction ON Wcs_dashboard_session.WCS_SESSION_ID=Wcs_dashboard_interaction.WCS_SESSION_ID LEFT JOIN UNIBANK_ASYNC.Wcs_dashboard_escalation Wcs_dashboard_escalation ON Wcs_dashboard_session.WCS_SESSION_ID=Wcs_dashboard_interaction.WCS_SESSION_ID LEFT JOIN UNIBANK_ASYNC.Wcs_dashboard_hold_resume Wcs_dashboard_hold_resume ON Wcs_dashboard_session.WCS_SESSION_ID=Wcs_dashboard_hold_resume.WCS_SESSION_ID LEFT JOIN UNIBANK_ASYNC.Wcs_dashboard_share Wcs_dashboard_share ON Wcs_dashboard_session.WCS_SESSION_ID=Wcs_dashboard_share.WCS_SESSION_ID LEFT JOIN UNIBANK_ASYNC.Wcs_survey Wcs_survey ON Wcs_survey.EXTERNAL_ID=Wcs_dashboard_session.EXTERNAL_ID When i creat the query in ireport i don't konw what is the correct syntax: '00.00.00't (I would like that as a last case stament were enhanced by the timestamp "00:00:00") Can you give me some help? Thank's so much Marcello.