Fix samples

This commit is contained in:
Fabian Affolter 2016-10-24 15:48:55 +02:00
parent b343ac3931
commit 978c1180ec
No known key found for this signature in database
GPG Key ID: DDF3D6F44AAB1336

View File

@ -8,7 +8,7 @@ comments: false
sharing: true
footer: true
logo: home-assistant.png
ha_category: "History"
ha_category: History
ha_release: pre 0.7
---
@ -44,7 +44,8 @@ Configuration variables:
Without any `include` or `exclude` configuration the history displays graphs for every entity (well that's not exactly true - for instance `hidden` entities or `scenes` are never shown) on a given date. If you are only interested in some of the entities you several options:
- Define domains and entities to `exclude` (aka. blacklist). This is convenient when you are basically happy with the information displayed, but just want to remove some entities or domains. Usually these are entities/domains which do not change (like `weblink`) or rarely change (`updater` or `automation`).
Define domains and entities to `exclude` (aka. blacklist). This is convenient when you are basically happy with the information displayed, but just want to remove some entities or domains. Usually these are entities/domains which do not change (like `weblink`) or rarely change (`updater` or `automation`).
```yaml
# Example configuration.yaml entry with exclude
history:
@ -57,7 +58,9 @@ history:
- sensor.last_boot
- sensor.date
```
- Define domains and entities to display by using the `include` configuration (aka. whitelist). If you have a lot of entities in your system and your `exclude` lists possibly get very large, it might be better just to define the entities or domains to display.
Define domains and entities to display by using the `include` configuration (aka. whitelist). If you have a lot of entities in your system and your `exclude` lists possibly get very large, it might be better just to define the entities or domains to display.
```yaml
# Example configuration.yaml entry with include
history:
@ -67,7 +70,9 @@ history:
- switch
- media_player
```
- Use the `include` list to define the domains/entities to display, and exclude some of them with in the `exclude` list. This makes sense if you for instance include the `sensor` domain, but want to exclude some specific sensors. Instead of adding every sensor entity to the `include` `entities` list just include the `sensor` domain and exclude the sensor entities you are not interested in.
Use the `include` list to define the domains/entities to display, and exclude some of them with in the `exclude` list. This makes sense if you for instance include the `sensor` domain, but want to exclude some specific sensors. Instead of adding every sensor entity to the `include` `entities` list just include the `sensor` domain and exclude the sensor entities you are not interested in.
```yaml
# Example configuration.yaml entry with include and exclude
history:
@ -84,7 +89,7 @@ history:
#### {% linkable_title Implementation details %}
The history is stored in a SQLite database `home-assistant.db` within your config directory.
The history is stored in a SQLite database `home-assistant_v2.db` within your configuration directory.
- events table is all events except `time_changed` that happened while recorder component was running.
- states table contains all the `new_state` values of `state_changed` events.
@ -96,7 +101,7 @@ The history is stored in a SQLite database `home-assistant.db` within your confi
- `last_updated`: timestamp anything has changed (state, attributes)
- `created`: timestamp this entry was inserted into the database
When the history component queries the states table it only selects states where the state has changed: `WHERE last_changed=last_updated`
When the `history` component queries the states table it only selects states where the state has changed: `WHERE last_changed=last_updated`
#### {% linkable_title On dates %}