From d09abdb0eb637dcfecb85765813b54d889b49f34 Mon Sep 17 00:00:00 2001 From: Navdeep Date: Sat, 5 Jul 2014 00:01:04 +0530 Subject: [PATCH] install.lib_mysqludf_preg.ubuntu This documentation depicts installation of lib_mysqludf_preg in Debian Linux(Ubuntu). --- doc/install.ubuntu | 13 +++++++++++++ 1 file changed, 13 insertions(+) create mode 100644 doc/install.ubuntu diff --git a/doc/install.ubuntu b/doc/install.ubuntu new file mode 100644 index 0000000..9ef5b32 --- /dev/null +++ b/doc/install.ubuntu @@ -0,0 +1,13 @@ +I found a UDF for MySQL called lib_mysqludf_preg and here’s how I got it to run on Ubuntu 11.04, somewhere in a temporary directory: + +sudo apt-get install libpcre3-dev libmysqlclient-dev +wget www.goodhumans.com/Misc/lib_mysqludf/lib_mysqludf_preg-LATEST.tar.gz +tar -xf lib_mysqludf_preg-LATEST.tar.gz +cd lib_mysqludf_preg-1.1/ +sudo ./configure +sudo make install +sudo service mysql restart + +At this point the UDF library is installed but the functions are not available yet, so log in to your MySQL command line, preferably as root and create your new preg_replace function like this: + +mysql>CREATE FUNCTION preg_replace RETURNS STRING SONAME 'lib_mysqludf_preg.so';