MySQL doesn't accept non-real dates on stored procedure calls

Bug #250354 reported by Matthew
4
Affects Status Importance Assigned to Milestone
mysql-dfsg-5.0 (Ubuntu)
Invalid
Undecided
Unassigned

Bug Description

Binary package hint: mysql-server

Sort of hard to explain. I created a stored procedures where you pass 2 dates, a begindate and enddate. I used >= begindate AND <= enddate. I couldn't figure out why sometimes I was getting unexpected results. Eventually I figured out that "non-real" dates (for example 2008-06-31) causes mysql to return NULL.

What's strange is that IT ACCEPTS the non-real dates in a regular SELECT. But if you stick the exact same SELECT into a Stored Procedure it stops working.

I hope I have been clear enough that you understand. I would consider this to be a bug and not user error since the problem only occurs with stored procedures. Also I ahve check and some other distros don't have this happen.

Revision history for this message
Mathias Gug (mathiaz) wrote : Re: [Bug 250354] [NEW] MySQL doesn't accept non-real dates on stored procedure calls

On Mon, Jul 21, 2008 at 12:08:58AM -0000, Matthew wrote:
> Sort of hard to explain. I created a stored procedures where you pass 2
> dates, a begindate and enddate. I used >= begindate AND <= enddate. I
> couldn't figure out why sometimes I was getting unexpected results.
> Eventually I figured out that "non-real" dates (for example 2008-06-31)
> causes mysql to return NULL.

Could specify the actual code you've used to create the store procedure
?

>
> What's strange is that IT ACCEPTS the non-real dates in a regular
> SELECT. But if you stick the exact same SELECT into a Stored Procedure
> it stops working.

Could you list which sql statement you're using and the outcome you
receive ?

 status incomplete

--
Mathias Gug
Ubuntu Developer http://www.ubuntu.com

Changed in mysql-dfsg-5.0:
status: New → Incomplete
Revision history for this message
wolfger (wolfger) wrote :

Over 4 months with no response. We are closing this bug report because it lacks the information we need to investigate the problem, as described in the previous comments. Please reopen it if you can give us the missing information, and don't hesitate to submit bug reports in the future. To reopen the bug report you can click on the current status, under the Status column, and change the Status back to "New". Thanks again!

Changed in mysql-dfsg-5.0:
status: Incomplete → Invalid
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.