计算上下文是DAX的核心机制,在DAX圣经中对计算上下文的讲解可谓层层展开,不断深入,深入到每个阶段都重新更新定义,或者说是更准确的定义。犹如从传统力学到牛顿力学再到相对论,层层展开。
如何学习和掌握计算上文
Evaluation contexts are hard to fully understand. They not only require you to
learn some new concepts, they really require you to alter what you know when
writing code. This is, in our experience, the hard part of DAX: changing the
way you think and start thinking in DAX.
完全理解计算上下文是不容易的。不仅要求学习很多新的概念,更在于改变对写公式时的认知。也就是说,在我们的经验看来,DAX最难的就在于:改变思维方式并按DAX执行方式思考问题。
If you found the whole chapter a tough one, and you had to read it again and
again, that is very normal; you are in good company. This company includes us,
the authors. We started learning DAX in 2010 and we are writing this book in
- Unbelievably, it took us five years to master the code of DAX and of the
engine, with a lot of discussions and meetings with the development team in the
meantime.
如果你发现学习本章很难,甚至读了好几遍,这是很正常的。您现在学习DAX比我们那时要好多了,其实你正处于一个很好的环境,这里有我们(作者)。当年我们开始学的时候是在2010年,而这本书写于2015年。不可想象吧,学习DAX竟然花了我们5年时间(掌握DAX以及理解DAX引擎工作原理),在期间我们和DAX研发团队有着大量的讨论和交流。
The good news is that these concepts, once fixed in your mind, are unlikely
to go away and be forgotten: They will stay with you and help you come out
from very complex formulas with a smile on your face—the smile of someone
who knows that he or she really understands what is happening under the
cover.
好消息是:一旦这些概念深入你的大脑,这也是不容易忘记的,他们将帮助你处理非常复杂的公式。当你因解决某个难题会心一笑的时候,只有你或像你一样理解DAX的人才能感受在解决问题的表面,处理了多么复杂的问题。
We did our best to explain the internals of evaluation contexts and give you a
clear view of how they work, yet we know that our best is probably not
enough. Our suggestion is to read this chapter multiple times, until you can read
it very fast, because you totally understand it. Doing that is still hard for us,
too.
我们竭尽所能来解释计算上下文的内部运行机制以便能让你更清楚它是如何工作的,但我们的努力还是不够。我们的建议是反复阅读本章,直到你可以很快地读,因为那意味着你基本全部都理解了。能做到这些对于我们(作者)也是有挑战的。
网友评论