The Luzmo platform supports a vareity of data types: these comprise 4 base-types of data and 4 special types of data.
The following four are the "base types" in Luzmo. The column data type will be inferred from your data source, either upon upload to Luzmo or from the schema information provided by your database or Plugin.
You can change the data type by selecting the data icon displayed to the left of each field name.
For datasets stored in Luzmo's database (local uploads & API data push), you can change the data type freely between all base and special types.
When working with a plugin or data provider, you can change the column type manually in Luzmo between its basetype (inferred from the data source) to the correspoding special data types. Specifically:
The topography data type is available on topography datasets. Please check this article for more information.
The coordinates data type can be set from a numeric column: when casting a numeric to a coordinate data type, you will be asked to specify the latitude and longitude column for the coordinate. An extra column containing your new "coordinates" data type will be created. Please check this article for more information.
We run a metadata sync every few hours to keep the structure in Luzmo the same as the structure in the database. In case you have done adaptations to the dataset structure and would like to trigger the metadata sync manually, you can do so from the dataset details page, which you can reach by clicking the More Info "i" icon .
Note: For MongoDB datasets, Luzmo infers the structure of a dataset and the data types of the columns from the first 1000 records in the dataset. This is because MongoDB is schemaless, meaning any document within a MongoDB collection could have a varying sets of fields with different data types for each field. The fallback data type is "hierarchy".
You can set your columns' data type to date or datetime.
Please refer to this article for more explanation on how these influence the possibility of timezone usage.
Let's consider a few examples:
Example 1 The column in the dataset includes values like "2023-04-07". In this case, this value unambiguously refers to the 7th of April, regardless of the timezone where the user is located, dashboard setting, ... This value should never be interpreted as the 6th of April at 22:00 for example. The column should be set to date.
Example 2 The column in the dataset includes values like "2023-04-07 04:00:00 +02:00". In this case, this value represents an exact moment in time (04 AM on the 7th of April in the UTC+2 timezone). This row should thus be counted on the 7th of April if we aggregate data in Belgium (UTC+1), but should count towards the 6th of April if we aggregate data in the USA, NY (UTC-5). The data will shift depending on the display timezone you specify. The column should be set to datetime.
Example 3
The column in the dataset includes values like "2023-04-07 02:00:00". In this case, you could want it to behave as a date like in example 1 or as a datetime like in example 2. Luzmo will try to set the type based on which values we encounter for local upload, or what the original data type is ("date", "datetime") for databases. You can change the datatype in Luzmo to date or datetime.
When you set it to date, the hours and so on will be ignored and the data will not shift in time.
When you set it to datetime, the data will be interpreted as UTC by Luzmo (as the exact timezone is not specified). When setting your display timezone to e.g. UTC-6, the above value will shift and become 2023-04-06 20:00:00.
Example 4 The column in the dataset includes values like "2023-04-07 02:00:00 +02:00 and ""2023-04-07 02:00:00 +04:00". As you can see, the column has data in different timezones. If you want them to shift to a specific display timezone, you need to make sure to set the field to a "timestamp with time zone" in your database. If this database field is not of a "timestamp with time zone" data type, you can make a view that takes your user's timezone + your "timestamp without time zone" column and turns it into a "timestamp with time zone". Make sure the data type for the column is set to datetime.
Example 5 The column in the dataset includes values like in example four, "2023-04-07 02:00:00 +02:00 and ""2023-04-07 02:00:00 +04:00". As you can see, the column has data in different timezones. If you do not want them to shift in time, you need to make sure the field to a "timestamp without timezone" in your database. At that point, the column will be interpreted as in the UTC timezone by Luzmo. You can make sure no shift occurs on your data by setting the display timezone of your dashboards to UTC as well. Make sure the data type for the column is set to datetime.