Oracle - Comparing dates
I have this Oracle procedure:

`CREATE OR REPLACE PROCEDURE xmas
IS
	CURSOR curUser IS SELECT userID, coins FROM Users;
	thisUser curUser%ROWTYPE;
	d VARCHAR(7);
	CURSOR curDate IS SELECT TO_CHAR(sysdate, 'DD-MON') FROM DUAL;
BEGIN
	OPEN curDate;
	FETCH curDate INTO d;
	CLOSE curDate;
	IF ((TO_DATE(d)) = (TO_DATE('25-DEC'))) THEN
		OPEN curUser;
		LOOP
			FETCH curUser INTO thisUser;
			EXIT WHEN (curUser%NOTFOUND);
			thisUser.coins := thisUser.coins + 5.00;
			UPDATE Users SET coins = thisUser.coins WHERE userID = thisUser.userID;
		END LOOP;
		CLOSE curUser;
	END IF;
END xmas;
/`

and when I call it, I get this error:

ORA-01840: input value not long enough for date format.

Tried different comparison methods for hours and nothing else has worked.
What's the problem??
Oracle - Comparing dates
===

I have this Oracle procedure:

`CREATE OR REPLACE PROCEDURE xmas
IS
	CURSOR curUser IS SELECT userID, coins FROM Users;
	thisUser curUser%ROWTYPE;
	d VARCHAR(7);
	CURSOR curDate IS SELECT TO_CHAR(sysdate, 'DD-MON') FROM DUAL;
BEGIN
	OPEN curDate;
	FETCH curDate INTO d;
	CLOSE curDate;
	IF ((TO_DATE(d)) = (TO_DATE('25-DEC'))) THEN
		OPEN curUser;
		LOOP
			FETCH curUser INTO thisUser;
			EXIT WHEN (curUser%NOTFOUND);
			thisUser.coins := thisUser.coins + 5.00;
			UPDATE Users SET coins = thisUser.coins WHERE userID = thisUser.userID;
		END LOOP;
		CLOSE curUser;
	END IF;
END xmas;
/`

and when I call it, I get this error:

ORA-01840: input value not long enough for date format.

Tried different comparison methods for hours and nothing else has worked.
What's the problem??