On Fri, 2003-09-05 at 09:52, Tom Lane wrote:
> Andrew Dunstan <[EMAIL PROTECTED]> writes:
> > Bruce Momjian wrote:
> >>> HINT:  Perhaps you need to use 'createlang' to load the language into
> >>> the database, or you mistyped the language name.
> 
> > Why not list out the languages we *do* know about, and tell them it's 
> > not in the list? Or is that too much work?
> 
> Seems like it would clutter the error message without really addressing
> Bruce's concern.  I doubt that seeing the list of available languages
> would do much to jog a newbie's memory about needing to run createlang.

Ok, it's a hint right? Step 1 is to merge the fuzzystrmatch contrib
module into main line code. Step 2 is to use that code to determine a
close match.

CREATE FUNCTION .... LANGUAGE 'plgsql';

System notices the error, and looks for languages in pg_language that
have similar names to 'plgsql', finds 'plpgsql'.

ERROR: Language 'plgsql' not found
HINT:  Perhaps you intended to use the language 'plpgsql?


Lots of work (both to implement and maintain) but it would be a neat
trick.

Attachment: signature.asc
Description: This is a digitally signed message part

Reply via email to