- Subscribe to RSS Feed
- Mark Question as New
- Mark Question as Read
- Float this Question for Current User
- Bookmark
- Subscribe
- Mute
- Printer Friendly Page
Changing timezone in cassandra
Created ‎12-01-2017 08:21 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hey,
I am working on cassandra 3.0 and I am struck at how to change the default time zone in cassandra. Default is Greenwich time or UTC or +00:00 offset. I need to convert the default time to another timezone. I tried many sources and I am not able to figure it out.
For example: When doing a query like this: "select * from table WHERE time > 11:00 (HH:mm) AND time < 15"
The result is: all times between 11:00 and 13:00 which is wrong. The result has to be 12:00, 13:00 and 14:00.
My actual time zone is +01:00.
Thanks in advance.
Created ‎12-01-2017 11:03 AM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Fixed this problem by creating and using the cqlshrc file like this:
http://docs.datastax.com/en/cql/3.1/cql/cql_reference/cqlshrc.html#clqshrc__cqlshrcOptions
I used "CET" for my timezone and it works so far.
Created ‎02-22-2018 02:51 PM
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report Inappropriate Content
Hi @Salda Murrah,
Created cqlshrc file like that and moved it to .cassandra folder.
Changed "Display Timezone" parameter to "Europe/Minsk" and "UTC+3" but still, its not working.
What should i do?
,I could not figure it how you solved this.
I changed timezone parameter to "UTC+3" in cqlshrc but still its not working.
Should i change datetimeformat?
All i need is to change it to UTC+3 since C* uses UTC by default.
Can you help me with that?
