When and If, Does the 'version' in ContentVersion Change?

Salesforce Asked by Carl-Johan Beurling on September 2, 2020

I’m using the lightning-file-upload component to upload files (wow).

My question is: is it safe to add a custom lookup relationship on the ContentVersion object?

I guess I don’t really understand the ‘version’ part of the name. Since we have to use isLatest = true when we query, does that mean the contentVersion changes on its own and therefore the custom relationship isn’t reliable, in the way, that a new version would be created and that record wouldn’t have the correct relationship?

One Answer

It's safe to put a Lookup field on the ContentVersion object, as the Lookup value will automatically be set on a new version from the previous version

If the Lookup value is changed on the latest version, it will only affect the latest version

Answered by Instread on September 2, 2020

Add your own answers!

Related Questions

Email images not displaying ONLY in Outlook Desktop

0  Asked on December 30, 2020 by curious-blueprints


How treat columns with colons in SQL

1  Asked on December 30, 2020 by greg-beazley


Why some classes cannot be constructed?

1  Asked on December 27, 2020 by andrii-pytel


Test Class not working (Case/Event)

0  Asked on December 27, 2020 by marvv


Find Parent Event of Child Event

2  Asked on December 27, 2020 by abhinav-gupta


Field output order when conver object to JSON

3  Asked on December 27, 2020 by ling


Unpackage an unlocked package

0  Asked on December 26, 2020 by an-le


Changing a multi-select picklist to a single select

0  Asked on December 24, 2020 by user88750


Ask a Question

Get help from others!

© 2022 All rights reserved. Sites we Love: PCI Database, MenuIva, UKBizDB, Menu Kuliner, Sharing RPP