mirror of
https://github.com/MariaDB/server.git
synced 2025-01-27 17:33:44 +01:00
ea01fff505
Adding "--source include/have_udf.inc" and a few "--replace" commands.
56 lines
1.5 KiB
Text
56 lines
1.5 KiB
Text
--source include/have_udf.inc
|
|
--source include/master-slave.inc
|
|
|
|
connection master;
|
|
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
eval CREATE FUNCTION metaphon RETURNS STRING SONAME "$UDF_EXAMPLE_SO";
|
|
SELECT metaphon('master');
|
|
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
--error ER_UDF_EXISTS
|
|
eval CREATE FUNCTION metaphon RETURNS INT SONAME "$UDF_EXAMPLE_SO";
|
|
|
|
sync_slave_with_master;
|
|
|
|
SELECT metaphon('slave');
|
|
|
|
connection master;
|
|
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
eval CREATE FUNCTION IF NOT EXISTS metaphon RETURNS STRING SONAME "$UDF_EXAMPLE_SO";
|
|
DROP FUNCTION IF EXISTS random_function_name;
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
eval CREATE FUNCTION IF NOT EXISTS metaphon RETURNS STRING SONAME "$UDF_EXAMPLE_SO";
|
|
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
--error ER_WRONG_USAGE
|
|
eval CREATE OR REPLACE FUNCTION IF NOT EXISTS metaphon RETURNS STRING SONAME "$UDF_EXAMPLE_SO";
|
|
sync_slave_with_master;
|
|
|
|
SELECT metaphon('slave');
|
|
|
|
connection master;
|
|
DROP FUNCTION metaphon;
|
|
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
eval CREATE OR REPLACE FUNCTION metaphon RETURNS STRING SONAME "$UDF_EXAMPLE_SO";
|
|
|
|
--replace_result $UDF_EXAMPLE_SO UDF_EXAMPLE_LIB
|
|
--error ER_UDF_EXISTS
|
|
eval CREATE FUNCTION metaphon RETURNS STRING SONAME "$UDF_EXAMPLE_SO";
|
|
sync_slave_with_master;
|
|
|
|
SELECT metaphon('slave');
|
|
|
|
connection master;
|
|
DROP FUNCTION metaphon;
|
|
DROP FUNCTION IF EXISTS metaphon;
|
|
sync_slave_with_master;
|
|
|
|
--error ER_SP_DOES_NOT_EXIST
|
|
DROP FUNCTION metaphon;
|
|
|
|
DROP FUNCTION IF EXISTS metaphon;
|
|
|
|
--source include/rpl_end.inc
|