[
https://issues.apache.org/jira/browse/OFBIZ-10953?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=17035108#comment-17035108 ]
Jacopo Cappellato commented on OFBIZ-10953:
-------------------------------------------
Hi [~pierresmits],
this is not what I was trying to convey; quoting myself:
{quote}In my opinion, rather than relaxing the "surrogate key" rule for dimension tables by introducing exceptions to it, it would be better to improve the implementation of surrogate keys in our BI component
{quote}
So, just to be super clear to avoid that my comment is misinterpreted:
* I didn't say that this *needs* to be done before *anything is added to the BI component*
* I was not talking about *corrections* that are required: the current code is not broken or wrong, I see this just as an opportunity for an improvement
* this enhancement would involve the implementation of a new method, db independent, to define/generate numeric sequences: so it is not a matter of *correcting* field type or entity engine definitions
* I mentioned this enhancement in this context because we were talking about the best practices around "surrogate keys" from the DWHT book and this is something that was in my mind since long: however it is off topic for this ticket, nor it is blocking any enhancements to be contributed to the BI component, and it was not my intention to shift the conversation away from the topic
> have CurrencyDimension have a dimensionId that is based on the natural key
> --------------------------------------------------------------------------
>
> Key: OFBIZ-10953
> URL:
https://issues.apache.org/jira/browse/OFBIZ-10953> Project: OFBiz
> Issue Type: Improvement
> Components: bi
> Affects Versions: Trunk, Release Branch 17.12, Release Branch 18.12
> Reporter: Pierre Smits
> Assignee: Pierre Smits
> Priority: Major
> Labels: CurrencyDimension, birt, currency, dimension, dwh
> Attachments: 20200208_094840.jpg, OFBIZ-10953-BI.patch
>
>
> Currently the record sequencer (delegator.getNextSeqId) is used to determine the dimensionId for the CurrencyDimension. This is unnecessary as the uomId from the UOM table can be used for currency.
> It also makes it easier to set the foreign-key in fact tables by generating it based on the date provided, than by retrieving the dimensionId based on a retrieval through the getDimensionIdFromNaturalKey service.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)