f6bbe21997-03-06Henrik Grubbström (Grubba) /*
4182211998-03-20Henrik Grubbström (Grubba)  * $Id: mysql.pike,v 1.4 1998/03/20 21:58:23 grubba Exp $
f6bbe21997-03-06Henrik Grubbström (Grubba)  * * Glue for the Mysql-module */
4182211998-03-20Henrik Grubbström (Grubba) //. //. File: mysql.pike //. RCSID: $Id: mysql.pike,v 1.4 1998/03/20 21:58:23 grubba Exp $ //. Author: Henrik Grubbström (grubba@idonex.se) //. //. Synopsis: Implements the glue to the Mysql-module. //. //. +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ //. //. Implements the glue needed to access the Mysql-module from the generic //. SQL module. //.
f6bbe21997-03-06Henrik Grubbström (Grubba) inherit Mysql.mysql;
2f9cc31998-03-19Henrik Grubbström (Grubba) 
4182211998-03-20Henrik Grubbström (Grubba) //. - quote //. Quote a string so that it can safely be put in a query. //. > s - String to quote.
6279f61998-03-19Henrik Grubbström (Grubba) string quote(string s)
2f9cc31998-03-19Henrik Grubbström (Grubba) { return(replace(s, ({ "\\", "\"", "\0", "\'", "\n", "\r" }), ({ "\\\\", "\\\"", "\\0", "\\\'", "\\n", "\\r" }))); }