FileName and Extension on MetadataSchema | Community
Skip to main content
francisco_ribei
Level 6
December 29, 2015
Solved

FileName and Extension on MetadataSchema

  • December 29, 2015
  • 5 replies
  • 2499 views

Hi,

I have a requirement to display the filename and the extension on the metadata schema.

I was using these:

  • jcr:content/cq:name - for the filename
  • ./jcr:content/metadata/dam:Fileformat: For the extension

The problem is those values are not consistent for all assets.

For File Name, I noticed this property is filled only when we set the dc:title in the Metadata, after that it fills this field. The problem is, it is not filled for all assets. For some formats it is not filled, for example, for PNG it works for a .doc it doesn't.

The same happens for dam:FileFormat, for some file formats it is filled for other it is not.

Is this working as it was designed for?

In case it is not always filled, there would be a way to use the node name in the metadata schema as the asset node name is the file name?

Or any other alternative?

Any inputs are welcome.

Thanks

This post is no longer active and is closed to new replies. Need help? Start a new post to ask your question.
Best answer by leeasling

Sounds like you may want to customize the workflow process for adding/updating DAM assets.  You could have a custom workflow step added to the OOTB workflow process that extracts the extension and stores the data on the node, you'd then be able to add this to your metadata schema.

5 replies

leeaslingAccepted solution
Level 8
December 29, 2015

Sounds like you may want to customize the workflow process for adding/updating DAM assets.  You could have a custom workflow step added to the OOTB workflow process that extracts the extension and stores the data on the node, you'd then be able to add this to your metadata schema.

francisco_ribei
Level 6
December 29, 2015

hi @leeasling,

That's what I was thinking to do.

Thanks for the tip, I'll create a custom step to set the cq:name and dam:FileFormat.

Thanks

Jitendra_S_Toma
Level 10
December 30, 2015

Hi,

"dc:format" attribute is the common attribute in all digital assets. So, Can it be used in your case?. I would not prefer to create "dam:FileFormat" on every asset. And, By the way, Are you planning to determine DAM file format of the asset before creating this attribute?.

---

Jitendra

franciscoribeir wrote...

hi @leeasling,

That's what I was thinking to do.

Thanks for the tip, I'll create a custom step to set the cq:name and dam:FileFormat.

Thanks

 

francisco_ribei
Level 6
December 30, 2015

Hi @Jitendra,

I'm going to fill dam:Fileformat with the file extension, that I can get from the filename.

Do you think this could cause problem?

Thanks.

Jitendra_S_Toma
Level 10
December 30, 2015

Well,

If there is no such attribute, then you are going to create it. And my point is that we should use dc:Format if we can rather than creating it. Just putting my thought. Can't really say if that could cause some problem.

--

Jitendra