From: Perrin Harkins Date: March 6 2009 8:07pm Subject: Re: Possible to get better error handling for invalid enum parameter to stored program? List-Archive: http://lists.mysql.com/mysql/216615 Message-Id: <66887a3d0903061207w59c01c86o91dd300a9a79726b@mail.gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable I'm afraid enums are useless for anything except compressing your data, since they don't reject bad values. If you want to limit a field to a set of values, you need to use a lookup table and a foreign key constraint. - Perrin On Fri, Mar 6, 2009 at 1:35 PM, David Karr wro= te: > If I define an enum parameter for a stored program, and the calling code > sends an invalid value, they get the less than useful "data truncated" > error. =A0Is it possible to define the stored program to produce better e= rror > handling for that kind of error? > > This is probably a FAQ, but in general, it appears that error diagnostics= in > stored programs are very primitive. Are there any plans in a roadmap to > improve this? >