How to resolve ORA-01830 Error Message in Oracle database

Learn the motive and how to unravel the ORA-01830 error message in Oracle.


When you come across an ORA-01830 error, the following error message will appear:

ORA-01830: date format picture ends earlier than converting complete enter string


You tried to enter a date value, but the date entered did now not match the date format.


The option(s) to resolve this Oracle error are:

Option #1

This error can show up when you strive to enter a date cost without the usage of the TO_DATE function.

In Oracle, the default date layout is generally DD-MON-YYYY. If you attempt to enter a date fee that does not comply with this format, you need to use the TO_DATE function.

For example, if you tried to execute the following SQL statement:

INSERT INTO supplier
(1, 'IBM', '13-DEC-2004 6:56 PM');

You would receive the following error message:

To correct this error, you can use the TO_DATE characteristic as follows:

INSERT INTO supplier
(1, 'IBM', TO_DATE('13-DEC-2004 6:56 PM', 'dd-mon-yyyy hh:mi PM'));