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

when $metrics.lastexecutionstart is null, set it to 0 #802

Merged
merged 2 commits into from Apr 10, 2016

Conversation

dengshilong
Copy link
Contributor

When $metrics.lastexecutionstart is null, set it to 0, so we can do a full-import. This is useful when select incremental data from a table.

@jprante
Copy link
Owner

jprante commented Apr 10, 2016

Not sure if this sets timestamp to just 01-JAN-1970, but I accept it for now... challenges with date/times before 1970 are another subject that matters throughout the importer code.

@jprante
Copy link
Owner

jprante commented Apr 10, 2016

Thanks!

@jprante jprante merged commit 0f6b180 into jprante:master Apr 10, 2016
@dengshilong
Copy link
Contributor Author

I have not consider the time before 01-JAN-1970. Now we don't need

There is a problem here, the first time you run the script, it can't select any data from table, it have two solutions here:

in another script, do full-import, later you can use the incremental script to select incremental data
define a statefile.json file before the first time you run the incremental script, set the lastexecutionstart to 0, so that you can select all the data from table.

I will delete it from README.

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.

None yet

2 participants