Syntax for dfm database query statement

We need a way to get the objCreationTime out of DFM for volumes.   Would someone please be able to provide the correct “dfm database query run “select”” statement?

Re: Syntax for dfm database query statement

Hi Bryan,

           The field you are looking for ""objCreationTime" is not availabe via database views so you can access them using dfm database query run.

dfm detail <obj-name-or-id> | findstr /i obj will give your objCreation time.

C:\>dfm detail 17989 | findstr /i obj


objCreationTimestamp               2010-09-09 20:55:06.000000




objFlags                           5

objFullName                        xxx-drp01-cf1:/xxxx_project01

objId                              17989

objName                            xxx_project01

objPerfStatus                      Unknown

objPerfStatusCode                  5


objStatus                          Error

objStatusChangeTimestamp           2012-01-15 09:43:34.000000

objStatusCode                      7


objStatusTimestamp                 2012-01-15 09:43:34.000000

objType                            Volume

sysObjectID                        .




Re: Syntax for dfm database query statement

Thank you Adai,

My customer has thousands of volumes and was really hoping to query the database against this attribute, filtering on values older than some date "X".    I believe your solutions will require exporting a list of all obj-name-or-id's then running the dfm detail command against each of them.

Can you think of any more efficient ways to accomplish this?  Your help is appreciated.

Re: Syntax for dfm database query statement


don't know if you have solved this already. By querying against the DFM database and not the views, you are able to get this information.

eg: dfm query run "SELECT * FROM DFM.volumes v LEFT JOIN DFM.objects o ON v.volId = o.objId WHERE o.objDeleted IS NULL AND v.snapshotSourceId=0"

You just have to chose which fields you need for the output. SELECT * comes up with quite a lot fields which you probably don't need. If you need filernames and other you'd have to make more joins.

Hope this helps.


Re: Syntax for dfm database query statement

Hi Jakob,

     dfm query run is not a supported cli and shouldn't not be used. Customer can only use view by dfm database query run cli.