[mapguide-trac] #649: FeatureService.UpdateFeatures doesn't log errors and reports them as succesful

MapGuide Open Source trac_mapguide at osgeo.org
Tue Mar 3 03:44:50 EST 2009


#649: FeatureService.UpdateFeatures doesn't log errors and reports them as
succesful
-----------------------------+----------------------------------------------
 Reporter:  zspitzer         |         Owner:       
     Type:  defect           |        Status:  new  
 Priority:  high             |     Milestone:       
Component:  Feature Service  |       Version:  2.0.2
 Severity:  critical         |    Resolution:       
 Keywords:                   |   External_id:       
-----------------------------+----------------------------------------------
Comment (by milicevic):

 Replying to [comment:4 milicevic]:
 > Hello,
 >
 > i wolud like to report the same behaviour on deleting features. In fact,
 I don't get it, the code looks and works well, class name is just fine,
 filter condition also but no errors or exceptions has been thrown.
 >
 >
 > {{{
 >         string TIMgisUser =
 System.Configuration.ConfigurationManager.AppSettings["TIMgisUser"];
 >         MapGuideApi.MgInitializeWebTier(@"C:\program
 files\MapguideOpenSource2.0\WebServerExtensions\www\webconfig.ini");
 >         MgUserInformation userInfo = new
 MgUserInformation("Administrator", "" +
 System.Configuration.ConfigurationManager.AppSettings["mgP"] + "");
 >         MgSite site = new MgSite();
 >         site.Open(userInfo);
 >         String mgSessionId = site.CreateSession();
 >
 >         MgUserInformation userInfoNew = new
 MgUserInformation(mgSessionId);
 >         MgSiteConnection siteConnection = new MgSiteConnection();
 >         siteConnection.Open(userInfoNew);
 >
 >         MgResourceService resourceService =
 siteConnection.CreateService(MgServiceType.ResourceService) as
 MgResourceService;
 >         MgFeatureService featureService =
 siteConnection.CreateService(MgServiceType.FeatureService) as
 MgFeatureService;
 >
 >         MgResourceIdentifier resId = new
 MgResourceIdentifier("Library://PROJEKTI/ZLZ/PODACI/DIONICE.FeatureSource");
 >         MgFeatureCommandCollection commands = new
 MgFeatureCommandCollection();
 >
 >         string layerClassName = "DIONICE";
 >
 >         MgDeleteFeatures deleteCmd = new MgDeleteFeatures(layerClassName
 , "(FeatId=1)");
 >         commands.Add(deleteCmd);
 >
 >         featureService.UpdateFeatures(resId, commands, false);
 > }}}

 Hello,

 I wolud like fill up my report. Thanks to Zac i have solved my problem.
 The reason was '''read only''' feature source.

-- 
Ticket URL: <http://trac.osgeo.org/mapguide/ticket/649#comment:6>
MapGuide Open Source <http://mapguide.osgeo.org/>
MapGuide Open Source Internals


More information about the mapguide-trac mailing list