Datasets
How do I change data in a source using DataLens?
You cannot change data in a source using DataLens.
You can process data you get from a source on the DataLens side using calculated fields.
The date field is recognized as a string. What should I do?
DataLens uses dates in ISO format. This means, if a date in your source data is 01.01.2020 (its format is DD.MM.YYYY), DataLens will treat it as a string.
To convert this kind of field value to the Date type, create a new field with this formula: DATE_PARSE([field_name_with_date_in_DD.MM.YYYY_format]).
The DATETIME_PARSE function works similarly and converts a string to the Date and Time type.
How do I link two tables with the JOIN operator if the fields to link have different data types?
Fields to link your tables by cannot have different data types.
To link tables, convert the fields in the source table to the type you need.
How do I add row numbering to a table?
To add row numbering, use a calculated field, e.g., RSUM(MIN(1)). See the screenshot
How do I convert a Unix time field to the DataLens Date and time field?
To do this, convert the Unix time to seconds and use the DATETIME function. For example, convert this Unix time in milliseconds: DATETIME(1380717142785/1000), where the /1000 operation converts milliseconds to seconds.
For Unix time fields, the data type in DataLens is an integer or fraction.
Can I use SQL queries to generate a dataset?
You can directly query a database via the dataset creation interface using SQL queries.
How can I get a point's coordinates from its address?
You could use the GEOCODE() function for that; however, it is not supported anymore.
Use the Yandex Maps API geocoder
See this example of a Jupyter notebook
Where can I get geopolygons/geopoints for regions/districts/cities?
You can use ready-made geodata sets
The archive contains the following data:
- Countries (polygons and points).
- Russian regions (polygons and points).
- Russian cities (points).
- Districts of million-plus cities (polygons).
Why is dataset materialization not available?
Materialization is no longer supported. We recommend working with a database directly. If a database responds to DataLens analytical queries too slowly, build data marts, e.g., based on Yandex Managed Service for ClickHouse®. You can use Yandex Data Transfer to upload your data.
ClickHouse® is a registered trademark of ClickHouse, Inc