From 871903c621fc8ff666bbe54f57967348f1e5fd3a Mon Sep 17 00:00:00 2001 From: Gasper Zejn Date: Tue, 17 Mar 2015 12:27:04 +0100 Subject: [PATCH] Fix small typos. --- cubes/backends/sql/query.py | 2 +- cubes/model.py | 2 +- doc/model.rst | 4 ++-- doc/slicing_and_dicing.rst | 6 +++--- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/cubes/backends/sql/query.py b/cubes/backends/sql/query.py index ef6af3bf..e7ecd40e 100644 --- a/cubes/backends/sql/query.py +++ b/cubes/backends/sql/query.py @@ -339,7 +339,7 @@ def join_expression(self, attributes, include_fact=True, master_fact=None, returned from mapper (most probably by `Mapper.relevant_joins()`) Returns a tuple: (`expression`, `tables`) where `expression` is - QLAlchemy expression object and `tables` is a list of `SnowflakeTable` + SQLAlchemy expression object and `tables` is a list of `SnowflakeTable` objects used in the join. If `include_fact` is ``True`` (default) then fact table is considered diff --git a/cubes/model.py b/cubes/model.py index ecf6b49b..a808c6cd 100644 --- a/cubes/model.py +++ b/cubes/model.py @@ -1988,7 +1988,7 @@ def __init__(self, name, label=None, description=None, order=None, * `formula` – name of a formula that contains the arithemtic expression (optional) * `measure` – measure name for this aggregate (optional) - * `expression` – arithmetic expression (only if bacend supported) + * `expression` – arithmetic expression (only if backend supported) * `nonadditive` – additive behavior for the aggregate (inherited from the measure in most of the times) """ diff --git a/doc/model.rst b/doc/model.rst index c107c154..381b2609 100644 --- a/doc/model.rst +++ b/doc/model.rst @@ -128,7 +128,7 @@ The ``joins`` can be considered as named templates. They should contain ``name`` property that will be referenced by a cube. -Vsibility: The joins and mappings are local to a single model. They are not +Visibility: The joins and mappings are local to a single model. They are not shared within the workspace. @@ -156,7 +156,7 @@ level as: ] The join has a name specified, which is used to match joins in the cube. Note -that the join contains incimplete information: it contains only the ``detail`` +that the join contains incomplete information: it contains only the ``detail`` part, that is the dimension key. To use the join in a cube which has two date dimensions `start date` and `end date`: diff --git a/doc/slicing_and_dicing.rst b/doc/slicing_and_dicing.rst index 282b277c..6dcceb2b 100644 --- a/doc/slicing_and_dicing.rst +++ b/doc/slicing_and_dicing.rst @@ -30,7 +30,7 @@ browsed. :width: 300px There are three types of cells: `point` – defines a single point in a dimension -at a prticular level; `range` – defines all points of an ordered dimension +at a particular level; `range` – defines all points of an ordered dimension (such as date) within the range and `set` – collection of points: .. figure:: images/cubes-point-range-set-cut.png @@ -43,7 +43,7 @@ For December 2010, regardless of day: ``[2010, 12]`` and for the whole year: it would be a single item list ``[2010]``. Similar for other dimensions: ``["sk", "Bratislava"]`` for city `Bratislava` in `Slovakia` (code ``sk``). -In Python the cuts for "sales in Slovakia between June 2010 and June 2013" are +In Python the cuts for "sales in Slovakia between June 2010 and June 2012" are defined as: .. code-block:: python @@ -335,7 +335,7 @@ Which is equivalent to: levels = dimension.hierarchy().levels() labels = [] for i, detail in enumerate(cut_details): - labels.append(detail[level[i].label_attribute.ref()]) + labels.append(detail[levels[i].label_attribute.ref()]) Note that this might change a bit: either full detail will be returned or just key and label, depending on an option argument (not yet decided).