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

Document geoJSON anomalies encountered #166

Open
SanjanaSogimatt opened this issue Aug 24, 2024 · 0 comments
Open

Document geoJSON anomalies encountered #166

SanjanaSogimatt opened this issue Aug 24, 2024 · 0 comments

Comments

@SanjanaSogimatt
Copy link

Issue Title

Error Handling: Invalid Input Syntax for Integer During SubDistrict and Village Data Insertion

Description

While inserting SubDistrict and Village data into the GeoIP application using Prisma's $executeRawUnsafe() method, multiple errors occurred due to invalid input syntax for type integer and syntax errors in raw SQL queries. These errors resulted in failed data insertion for several entries.

Affected Entries:

SubDistricts:

  • Kachchh
  • Mirpur
  • Muzaffarabad
  • Punch
  • Leh
  • Kolasib
  • Lawngtlai

Villages:

  • Khiri
  • Itahri
  • Shortt's Island

Error Details:

Invalid Input Syntax for Integer (22P02):

  • The raw query failed due to invalid input syntax for type integer, likely caused by an empty string or incorrect data type being passed where an integer was expected.
  • Error message: ERROR: invalid input syntax for type integer: " "

Syntax Errors in SQL (42601):

  • Raw SQL queries failed due to syntax errors, indicating issues with the formatting of the SQL statements, possibly near keywords or special characters.

  • Specific errors:

ERROR: syntax error at or near "N"
ERROR: syntax error at or near "Bungtlang"
ERROR: syntax error at or near "{"
ERROR: syntax error at or near "s"

Expected Behavior:
Data should be inserted successfully without syntax errors.
The script should properly handle or validate inputs to avoid invalid syntax for integers.

Tech Stack:
Prisma Client Version: 5.17.0
Language: TypeScript
Environment: Node.js

Category
Bug Report

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

No branches or pull requests

1 participant