Take the 2-minute tour ×
Geographic Information Systems Stack Exchange is a question and answer site for cartographers, geographers and GIS professionals. It's 100% free, no registration required.

I am trying to implement wfs-t in a map application. tried using ArcGIS server wfs-t, and didn't make it since there is a lock mechanism while trying to edit a feature.ArcGIS WFS-T + OpenLayers; then decided to move on using GeoServer... unfortunately, stuck again. sincerely wish somebody in this site can give me some advice. thanks a lot!

what I did in JS code is:

update the value of an attribute, and set the state of that feature as OpenLayers.State.Update;

feat.attributes['MATERIAL'] = 'CMPtest';
feat.data['MATERIAL'] = 'CMPtest';
feat.state = OpenLayers.State.UPDATE;

then:

using SaveStrategy.save();

the error response text is:

 <?xml version="1.0" ?>
<wfs:WFS_TransactionResponse version="1.0.0" xmlns:ogc="http://www.opengis.net/ogc" xmlns:wfs="http://www.opengis.net/wfs" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opengis.net/wfs http://XXXX/geoserver/schemas/wfs/1.0.0/WFS-transaction.xsd">
  <wfs:InsertResult>
    <ogc:FeatureId fid="none"/>
  </wfs:InsertResult>

  <wfs:TransactionResult>

    <wfs:Status>

      <wfs:FAILED/>

    </wfs:Status>

    <wfs:Message>
      update error
    </wfs:Message>

  </wfs:TransactionResult>
</wfs:WFS_TransactionResponse>

the request xml is:(from Chrome console)

<?xml version="1.0" ?>
    <wfs:Transaction service="WFS" version="1.0.0" xmlns:wfs="http://www.opengis.net/wfs" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.opengis.net/wfs http://schemas.opengis.net/wfs/1.0.0/WFS-transaction.xsd">
      <wfs:Update typeName="feature:SAMPLE_FEATURE" xmlns:feature="http://www.opengeospatial.net/cite">
        <wfs:Property>
          <wfs:Name>
            SHAPE
          </wfs:Name>
          <wfs:Value>
            <gml:Point srsName="EPSG:26912" xmlns:gml="http://www.opengis.net/gml">
              <gml:coordinates cs="," decimal="." ts="">
                401550.55,4647703.82
              </gml:coordinates>
            </gml:Point>
          </wfs:Value>
        </wfs:Property>
        <wfs:Property>
          <wfs:Name>
            MATERIAL
          </wfs:Name>
          <wfs:Value>
            CMPtest
          </wfs:Value>
        </wfs:Property>
        <wfs:Property>
          <wfs:Name>
            CENTER_LON
          </wfs:Name>
          <wfs:Value>
            -112.188498069
          </wfs:Value>
        </wfs:Property>
        <wfs:Property>
          <wfs:Name>
            CENTER_LAT
          </wfs:Name>
          <wfs:Value>
            41.9749785934
          </wfs:Value>
        </wfs:Property>
        <wfs:Property>
          <wfs:Name>
            CENTER_Z
          </wfs:Name>
          <wfs:Value>
            1353.59340947
          </wfs:Value>
        </wfs:Property>
        <ogc:Filter xmlns:ogc="http://www.opengis.net/ogc">
          <ogc:FeatureId fid="SAMPLE_FEATURE.1"/>
        </ogc:Filter>
      </wfs:Update>
    </wfs:Transaction>
share|improve this question
1  
Have you checked the geoserver log for errors? –  unicoletti Apr 8 '12 at 7:53
    
what happens if you paste that request into the GeoServer Demo page? –  iant Apr 8 '12 at 14:02
    
so sorry to bother you guys... it turns out something is wrong with back-end... index is not properly configuated in Oracle.. –  Simon Apr 9 '12 at 15:53

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Browse other questions tagged or ask your own question.