Hi Wai, On 9 February 2012 17:23, Wai <[email protected]> wrote: > Hello, > > I don't understand what useful functional purpose it would serve to separate > these different types of blobs into the separate entities when > DataResource.mimeTypeId/Content.mimeTypeId would help to distinguish one > type of blob from another.
I cannot tell you the exact reason for these separate entities, but a wild guess is that you can tune up these tables for each blob type. I'm also curious about the original reasoning for this > > The complication with having separate entities for each type of uploaded > binary files types is one of management. > > For a scenario where a user stores a photo to the content component (which > ends up storing the image data into DataResource and ImageDataResource). > Now, when the user decides later to change the content to another type of > file (eg. a video file) for the same contentId, then ofbiz would have to > make the necessary changes of destroying the entry in ImageDataResource and > store the uploaded video data to VideoDataResource for the same > DataResource.dataResourceId/Content.dataResourceId. This is rather > complicated for maintenance purposes. Deleting from two tables is not much complicated than deleting from one table with OFBiz ;) > > I propose to only use ImageDataResource for storing any kind of blob content > and rely on Content.mimeTypeId and/or DataResource.mimeTypeId to identify > the format of the blob. Hence deprecating > VideoDataResource,AudioDataResource,OtherDataResource. > > Any insight/comment is appreciated. > > Thanks, > Wai Cheers, Bilgin > > > -- > View this message in context: > http://ofbiz.135035.n4.nabble.com/ImageDataResource-VideoDataResource-AudioDataResource-OtherDataResource-tp4354343p4373608.html > Sent from the OFBiz - User mailing list archive at Nabble.com.
