How To Check For Attachments On Custom Investment Object
search cancel

How To Check For Attachments On Custom Investment Object

book

Article ID: 268699

calendar_today

Updated On:

Products

Clarity PPM SaaS Clarity PPM On Premise

Issue/Introduction

How can attachments be validated.
Is there a way to check if an attachment field is empty?  

 

Environment

Release : 16.1.1

Resolution

The following query can be used as an example to query attachments that exist on a custom investment.

select name, code, attachments  from odf_ca_tester
where attachments is not null
order by last_updated_date desc;

select a.id, a.created_date, a.created_by, a.LAST_UPDATED_DATE, 
a.LAST_UPDATED_DATE, b.unique_name, a.name
from CLB_DMS_FILES a,
SRM_RESOURCES b
WHERE b.user_id = a.created_by
--where parent_folder_id = xxxxxxxx
ORDER BY a.created_date desc

NOTE: attachments is the id of custom object attribute of 'Attachment'  type. 
odf_ca_tester is an example table that is created