Skip to content

Support reading timestamps in epoc format#26

Open
ftylitak wants to merge 2 commits intofabio-miranda:masterfrom
insighio:master
Open

Support reading timestamps in epoc format#26
ftylitak wants to merge 2 commits intofabio-miranda:masterfrom
insighio:master

Conversation

@ftylitak
Copy link
Copy Markdown

@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
Copy Markdown

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