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

SPIT converts null dates to invalid values #13395

Closed
qgib opened this issue Dec 14, 2010 · 1 comment
Closed

SPIT converts null dates to invalid values #13395

qgib opened this issue Dec 14, 2010 · 1 comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Plugins
Milestone

Comments

@qgib
Copy link
Contributor

qgib commented Dec 14, 2010

Author Name: Aren Cambre (Aren Cambre)
Original Redmine Issue: 3335

Redmine category:c++_plugins
Assignee: Tim Sutton


If I have a shapefile with a DBF that has null values in the date column, SPIT translates these null dates to an invalid 0000/00/00 value. For example, this error:

Problem inserting features from file:
C:/[redacted]/TxDOT_Roadways.shp
The database gave an error while executing this SQL:
INSERT INTO "public"."TxDOT_Roadways"("OBJECTID","STRATMAP_I","RTE_NM",... (rest of SQL trimmed)
The error was:
ERROR:  date/time field value out of range: "0000/00/00"
LINE 1: ...0','058AA0353','AA','353',NULL,'353','2010/12/01','0000/00/0...

If I use shp2pgsql.exe instead, the date gets translated to NULL in the INSERT INTO statements.

If you want to reproduce, download TxDOT Roadways 2010 at http://www.tnris.state.tx.us/datadownload/download.jsp and import TxDOT_Roadways.shp.

@qgib
Copy link
Contributor Author

qgib commented Dec 9, 2011

Author Name: Paolo Cavallini (@pcav)


IMHO SPIT will not be maintained, as DB Manager will enter into Master. No work should go into fixing this.


  • pull_request_patch_supplied was configured as 0
  • resolution was configured as wontfix
  • status_id was changed from Open to Closed

@qgib qgib added Bug Either a bug report, or a bug fix. Let's hope for the latter! Plugins labels May 24, 2019
@qgib qgib added this to the Version 1.7.0 milestone May 24, 2019
@qgib qgib closed this as completed May 24, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Either a bug report, or a bug fix. Let's hope for the latter! Plugins
Projects
None yet
Development

No branches or pull requests

1 participant