There was an error while loading. Please reload this page.
2 parents ac9141c + b35f997 commit 41a3c58Copy full SHA for 41a3c58
storage/connect/tabodbc.cpp
@@ -321,10 +321,21 @@ PSZ TDBODBC::GetFile(PGLOBAL g)
321
{
322
if (Connect) {
323
char *p1, *p2;
324
- size_t n;
+int i;
325
+size_t n;
326
- if ((p1 = strstr(Connect, "DBQ="))) {
327
- p1 += 4; // Beginning of file name
+if (!(p1 = strstr(Connect, "DBQ="))) {
328
+char *p, *lc = strlwr(PlugDup(g, Connect));
329
+
330
+if ((p = strstr(lc, "database=")))
331
+p1 = Connect + (p - lc);
332
333
+i = 9;
334
+} else
335
+i = 4;
336
337
+if (p1) {
338
+p1 += i; // Beginning of file name
339
p2 = strchr(p1, ';'); // End of file path/name
340
341
// Make the File path/name from the connect string
0 commit comments