How can I get my SQL to ignore this error. It seems that ORSLSM contains some rows that contain non numeric values. I would like to ignore the row that are causing the errors
Announcement
Collapse
No announcement yet.
Ignoring rows that produce errors
Collapse
X
-
If orstat and/or orcoto are not numeric fields, I would say they couse the error.
In that case you can just write your WHERE like ... WHERE ORSTAT >= '6'
Otherwise you can skip the rows by using regex:
WHERE regexp_count(TRIM(ORSLSM), '^[0-9]*$') = 1
This checks if the field contains only numeric values.
Hope this helps
Andy
Comment