[mapserver-commits] r10115 - trunk/mapserver

svn at osgeo.org svn at osgeo.org
Sat Apr 24 13:24:25 EDT 2010


Author: sdlime
Date: 2010-04-24 13:24:24 -0400 (Sat, 24 Apr 2010)
New Revision: 10115

Modified:
   trunk/mapserver/HISTORY.TXT
   trunk/mapserver/mapfile.c
Log:
Write out join CONNECTIONTYPE when saving a mapfile. (#3435)

Modified: trunk/mapserver/HISTORY.TXT
===================================================================
--- trunk/mapserver/HISTORY.TXT	2010-04-24 17:22:28 UTC (rev 10114)
+++ trunk/mapserver/HISTORY.TXT	2010-04-24 17:24:24 UTC (rev 10115)
@@ -14,6 +14,8 @@
 Current Version (SVN trunk):
 ----------------------------
 
+- Write out join CONNECTIONTYPE when saving a mapfile. (#3435)
+
 - Fixed attribute queries to use an extent stored (and cached) as part of the queryObj
   rather than the map->extent. (#3424)
 

Modified: trunk/mapserver/mapfile.c
===================================================================
--- trunk/mapserver/mapfile.c	2010-04-24 17:22:28 UTC (rev 10114)
+++ trunk/mapserver/mapfile.c	2010-04-24 17:24:24 UTC (rev 10115)
@@ -566,6 +566,19 @@
   if(join->name) fprintf(stream, "        NAME \"%s\"\n", join->name);
   if(join->table) fprintf(stream, "        TABLE \"%s\"\n", join->table);
   if(join->to) fprintf(stream, "        TO \"%s\"\n", join->to);
+  switch (join->connectiontype) {
+  case(MS_DB_CSV):
+    fprintf(stream, "        CONNECTIONTYPE CSV\n");
+    break;
+  case(MS_DB_POSTGRES):
+    fprintf(stream, "        CONNECTIONTYPE POSTGRES\n");
+    break;
+  case(MS_DB_MYSQL):
+    fprintf(stream, "        CONNECTIONTYPE MYSQL\n");
+    break;
+  default:
+    break;
+  };
   fprintf(stream, "        TYPE %s\n", msJoinType[join->type]);
   fprintf(stream, "      END\n");
 }



More information about the mapserver-commits mailing list