string_fold_left (fun l c -> l @ flag_of_char c) [] s
let init myflags mylog =
- let s, m, a =
+ let m, a =
let g =
if List.mem Galax myflags
then MQIMap.empty_map else MQIMap.read_map
in g ()
in
{log = mylog; set = myflags;
- pgc = if List.mem Galax myflags then None else MQIPostgres.init s;
+ pgc =
+ if List.mem Galax myflags then
+ None
+ else
+ MQIPostgres.init
+ (Helm_registry.get "mathql_interpreter.postgresql_connection_string");
pgm = m; pga = a
}
type pg_alias = (string * string) list
-let empty_map () = "", [], []
+let empty_map () = [], []
let read_map () =
let map = Helm_registry.get "mathql_interpreter.db_map" in
let ich = open_in map in
- let pgs = input_line ich in
let rec aux r s =
let d = input_line ich in
match Str.split (Str.regexp "[ \t]+") d with
in
let pgm, pga = aux [] [] in
close_in ich;
- pgs, pgm, pga
+ pgm, pga
let comp c1 c2 = match c1, c2 with
| (_, t1), (_, t2) when t1 < t2 -> U.Lt
type pg_alias
-val empty_map : unit -> string * pg_map * pg_alias
+val empty_map : unit -> pg_map * pg_alias
-val read_map : unit -> string * pg_map * pg_alias
+val read_map : unit -> pg_map * pg_alias
val get_tables : pg_map -> MathQL.path -> pg_tables