* Refactored DatabaseBase::sourceStream(), made it possible for descendant classes to alter its behaviour w/o having to redo it completely like Oracle does. * MySQL class now supports specifying DELIMITER. * Thrown away the mess of catering for double semicolon. If it's a problem, fix your .sql files! * Haven't actually touched Oracle. * Tests!
12 lines
205 B
PL/PgSQL
12 lines
205 B
PL/PgSQL
-- Postgres test file for DatabaseTest::testStoredFunctions()
|
|
|
|
CREATE FUNCTION mw_test_function()
|
|
RETURNS INTEGER
|
|
LANGUAGE plpgsql AS
|
|
$mw$
|
|
DECLARE foo INTEGER;
|
|
BEGIN
|
|
foo := 21;
|
|
RETURN foo * 2;
|
|
END
|
|
$mw$;
|