Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support reading timestamps in epoc format #26

Open
wants to merge 2 commits into
base: master
Choose a base branch
from

Conversation

ftylitak
Copy link

@ftylitak ftylitak commented Apr 7, 2022

Support reading timestamps in epoc format in the time field, applying the required multiplier for the value to always be in nanoseconds.

Through "-te" option, user can pass the percision of the epoch time. When the timecolumn is parsed, the appropriate multiplier will be applied to always end up in nanoseconds that are required by influxdb.

@fcattaneo2
Copy link

Your script is ok for epoch timestamp format, but not work for native timestamp data.

I get this error with your script that work with original scripst by Miranda.

timestamp = int(row[timecolumn])
ValueError: invalid literal for int() with base 10: '2022-09-01 00:00:00'

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants