[Geoserver-users] null pointer exception in oracle WFS insert again

Hi All,

I have exactly the same problem as Zerogeek here:
http://www.nabble.com/null-pointer-exception-in-oracle-WFS-insert-td15340163.html

I use Geoserver 1.7.2. I have 3 tables in the database, one point
type, one multipolygon type, which work fine in MapBender 2.5, even
WFS-T editing etc. However, the third one, which has 2 multipolygon
columns, of which I selected one in Mapbender, fails to insert new
features with the above symptoms.

In the above conversation I just don't understand where the capitals
can come into question, and wherever I looked, everything is
uppercase. Spatial column is KGEOM, which has spatial index:
CREATE INDEX "BALAZS"."IDX_BLOKK_A0_KGEOM" ON "BALAZS"."BLOKK_A0" ("KGEOM")
   INDEXTYPE IS "MDSYS"."SPATIAL_INDEX" PARAMETERS ('layer_gtype=MULTIPOLYGON');

My failing request with some other (not all) log output is

2009-02-19 11:42:08,608 ERROR [geoserver.ows] -
org.geoserver.platform.ServiceException: Could not determine geoserver request f
rom http request GET /geoserver/wfs? HTTP/1.1
User-Agent: Java/1.6.0_10
Host: att-it.homelinux.net:22880
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
Connection: keep-alive
        at org.geoserver.ows.Dispatcher.dispatch(Dispatcher.java:389)
        at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:20
8)
....
2009-02-19 11:42:08,633 TRACE [geotools.xml] - startElement(http://www.opengis.n
et/wfs,Insert,wfs:Insert
2009-02-19 11:42:08,633 TRACE [geotools.xml] - startElement(http://www.openplans
.org/topp,BLOKK_A0,topp:BLOKK_A0
2009-02-19 11:42:08,634 TRACE [geotools.xml] - startElement(,TAJOL,TAJOL
2009-02-19 11:42:08,634 DEBUG [geotools.xml] - Could not find declaration for: {
http://www.opengis.net/wfs\}TAJOL. Checking if containing type declares a single
particle.
[other column also]
2009-02-19 11:42:08,641 TRACE [geotools.xml] - startElement(,KGEOM,KGEOM
2009-02-19 11:42:08,641 DEBUG [geotools.xml] - Could not find declaration for: {
http://www.opengis.net/wfs\}KGEOM. Checking if containing type declares a single
particle.
2009-02-19 11:42:08,641 DEBUG [geotools.xml] - Could not find declaration for: {
http://www.opengis.net/wfs\}KGEOM. Performing lookup by ignoring namespace
2009-02-19 11:42:08,665 DEBUG [geoserver.wfs] - located FeatureType w/ typeRef '
OracleSpatialThin:BLOKK_A0' and elementName '{http://www.openplans.org/topp\}BLOK
K_A0'
2009-02-19 11:42:08,665 DEBUG [geoserver.wfs] - Transasction Insert:net.opengis.
wfs.impl.InsertElementTypeImpl@anonymised.com (feature: [org.geotools.feature.simple.Sim
pleFeatureImpl@anonymised.com], handle: null, idgen: <unset>, inputFormat:
<unset>, srsName: null)
2009-02-19 11:42:08,666 DEBUG [data.jdbc] - getting feature writer for BLOKK_A0:
typeName = BLOKK_A0 schema: SimpleFeatureTypeImpl http://www.openplans.org/topp
BLOKK_A0 identified extends Feature(KGEOM:KGEOM,ORT2X:ORT2X,MERAR:MERAR,ORT2Y:OR
T2Y,ORT1Y:ORT1Y,TGEOM:TGEOM,ORT1X:ORT1X,BLOAZ:BLOAZ,TAJOL:TAJOL)srids: {KGEOM=23
700, TGEOM=23700}
2009-02-19 11:42:08,666 DEBUG [filter.SQLEncoderOracle] - SQLEncoderOracle: Geom
etric Column is: KGEOM
2009-02-19 11:42:08,669 DEBUG [data.jdbc] - About to execute query: SELECT "SORS
ZAM", "BLOAZ", "TAJOL", "MERAR", "ORT1X", "ORT1Y", "ORT2X", "ORT2Y", "KGEOM", "T
GEOM" FROM "BLOKK_A0" WHERE '1' = '0'
2009-02-19 11:42:08,701 INFO [geoserver.wfs] -
Request: transaction
        handle = null
        service = WFS
        version = 1.0.0
        baseUrl = http://att-it.homelinux.net:80/geoserver/
        providedVersion = 1.0.0
        lockId = null
        group =
[wfs:insert=net.opengis.wfs.impl.InsertElementTypeImpl@anonymised.com
(feature: [org.geotools.feature.simple.SimpleFeatureImpl@anonymised.com],
handle: null, idgen: <unset>, inputFormat: <unset>, srsName: null)]
        insert = [net.opengis.wfs.impl.InsertElementTypeImpl@anonymised.com
(feature: [org.geotools.feature.simple.SimpleFeatureImpl@anonymised.com],
handle: null, idgen: <unset>, inputFormat: <unset>, srsName: null)]
        update =
        delete =
        native =
        releaseAction = ALL

What can be the problem?

Thank you in advance.
Best regards: Balázs Bámer

Balázs Bámer ha scritto:

Hi All,

I have exactly the same problem as Zerogeek here:
http://www.nabble.com/null-pointer-exception-in-oracle-WFS-insert-td15340163.html

I use Geoserver 1.7.2. I have 3 tables in the database, one point
type, one multipolygon type, which work fine in MapBender 2.5, even
WFS-T editing etc. However, the third one, which has 2 multipolygon
columns, of which I selected one in Mapbender, fails to insert new
features with the above symptoms.

In the above conversation I just don't understand where the capitals
can come into question, and wherever I looked, everything is
uppercase.

The user above was trying to insert data using lowercase names in the
WFS-T request, that triggered the NPE.

Spatial column is KGEOM, which has spatial index:
CREATE INDEX "BALAZS"."IDX_BLOKK_A0_KGEOM" ON "BALAZS"."BLOKK_A0" ("KGEOM")
   INDEXTYPE IS "MDSYS"."SPATIAL_INDEX" PARAMETERS ('layer_gtype=MULTIPOLYGON');

My failing request with some other (not all) log output is

2009-02-19 11:42:08,608 ERROR [geoserver.ows] -
org.geoserver.platform.ServiceException: Could not determine geoserver request f
rom http request GET /geoserver/wfs? HTTP/1.1
User-Agent: Java/1.6.0_10
Host: att-it.homelinux.net:22880
Accept: text/html, image/gif, image/jpeg, *; q=.2, */*; q=.2
Connection: keep-alive
        at org.geoserver.ows.Dispatcher.dispatch(Dispatcher.java:389)
        at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:20
8)
....

Ouch, you cut exactly the only part that I could effectively use to get an idea of the problem.

In order to help you out I need two things:
- a full stack trace
- a sql script to recreate your data (not all, just enough to reproduce the issue)
- the exact request you made

You can send me that information by private mail.

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

Hello

I'm Experimenting with geoserver and oracle and now i have the same Problem!
Im Working with Geoserver 1.7.5.

I have an Oracle Spatial Test-Table wich consist of three colums
(ID,NAME,GEOMETRY).
The primary key is set on ID and the spatialindex to GEOMETRY.
I have insertet some test features.

Now i have created a test-html-page to watch the tablecontent in an
Openlayers-map with an WFS-layer. Also this page should be able to insert,
modify and delete features.

Load and delete is no problem but if i try to insert and save a feature i
got the same Error.

I'm deeply gratefull for any Information about this error and i would like
to know if there is an solution for this problem.

Thanks for any post!!!

------------------------------------------------
The Stack-Trace

13:36:30,109 INFO [STDOUT] 08 Jul 13:36:30 ERROR [geoserver.wfs] -
Transaction failed
org.geoserver.wfs.WFSTransactionException: Error performing insert
  at
org.geoserver.wfs.InsertElementHandler.execute(InsertElementHandler.java:200)
  at org.geoserver.wfs.Transaction.execute(Transaction.java:333)
  at org.geoserver.wfs.Transaction.transaction(Transaction.java:108)
  at
org.geoserver.wfs.DefaultWebFeatureService.transaction(DefaultWebFeatureService.java:182)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)
  at
org.springframework.aop.support.AopUtils.invokeJoinpointUsingReflection(AopUtils.java:310)
  at
org.springframework.aop.framework.ReflectiveMethodInvocation.invokeJoinpoint(ReflectiveMethodInvocation.java:182)
  at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:149)
  at org.geoserver.ows.util.EMFLogger.invoke(EMFLogger.java:51)
  at
org.springframework.aop.framework.ReflectiveMethodInvocation.proceed(ReflectiveMethodInvocation.java:171)
  at
org.springframework.aop.framework.JdkDynamicAopProxy.invoke(JdkDynamicAopProxy.java:204)
  at $Proxy89.transaction(Unknown Source)
  at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
  at sun.reflect.NativeMethodAccessorImpl.invoke(Unknown Source)
  at sun.reflect.DelegatingMethodAccessorImpl.invoke(Unknown Source)
  at java.lang.reflect.Method.invoke(Unknown Source)
  at
org.geoserver.security.OperationSecurityInterceptor.invoke(OperationSecurityInterceptor.java:41)
  at org.geoserver.ows.Dispatcher.execute(Dispatcher.java:583)
  at org.geoserver.ows.Dispatcher.handleRequestInternal(Dispatcher.java:212)
  at
org.springframework.web.servlet.mvc.AbstractController.handleRequest(AbstractController.java:153)
  at
org.springframework.web.servlet.mvc.SimpleControllerHandlerAdapter.handle(SimpleControllerHandlerAdapter.java:48)
  at
org.springframework.web.servlet.DispatcherServlet.doDispatch(DispatcherServlet.java:875)
  at
org.springframework.web.servlet.DispatcherServlet.doService(DispatcherServlet.java:809)
  at
org.springframework.web.servlet.FrameworkServlet.processRequest(FrameworkServlet.java:571)
  at
org.springframework.web.servlet.FrameworkServlet.doPost(FrameworkServlet.java:511)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:710)
  at javax.servlet.http.HttpServlet.service(HttpServlet.java:803)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:290)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at
org.vfny.geoserver.filters.SetCharacterEncodingFilter.doFilter(SetCharacterEncodingFilter.java:108)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:265)
  at
org.acegisecurity.intercept.web.FilterSecurityInterceptor.invoke(FilterSecurityInterceptor.java:107)
  at
org.acegisecurity.intercept.web.FilterSecurityInterceptor.doFilter(FilterSecurityInterceptor.java:72)
  at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
  at
org.acegisecurity.ui.ExceptionTranslationFilter.doFilter(ExceptionTranslationFilter.java:124)
  at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
  at
org.acegisecurity.providers.anonymous.AnonymousProcessingFilter.doFilter(AnonymousProcessingFilter.java:125)
  at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
  at
org.acegisecurity.ui.basicauth.BasicProcessingFilter.doFilter(BasicProcessingFilter.java:174)
  at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
  at
org.acegisecurity.context.HttpSessionContextIntegrationFilter.doFilter(HttpSessionContextIntegrationFilter.java:249)
  at
org.acegisecurity.util.FilterChainProxy$VirtualFilterChain.doFilter(FilterChainProxy.java:275)
  at
org.acegisecurity.util.FilterChainProxy.doFilter(FilterChainProxy.java:149)
  at
org.acegisecurity.util.FilterToBeanProxy.doFilter(FilterToBeanProxy.java:98)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.geoserver.filters.LoggingFilter.doFilter(LoggingFilter.java:73)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at
org.geoserver.filters.ReverseProxyFilter.doFilter(ReverseProxyFilter.java:163)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at org.geoserver.filters.GZIPFilter.doFilter(GZIPFilter.java:41)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at
org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
  at
org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:235)
  at
org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:206)
  at
org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:230)
  at
org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:175)
  at
org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:182)
  at
org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:84)
  at
org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:127)
  at
org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:102)
  at
org.jboss.web.tomcat.service.jca.CachedConnectionValve.invoke(CachedConnectionValve.java:157)
  at
org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:109)
  at
org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:262)
  at
org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:844)
  at
org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.process(Http11Protocol.java:583)
  at org.apache.tomcat.util.net.JIoEndpoint$Worker.run(JIoEndpoint.java:446)
  at java.lang.Thread.run(Unknown Source)
Caused by: java.lang.NullPointerException
  at
org.geotools.data.oracle.OracleFeatureWriter.doInsert(OracleFeatureWriter.java:182)
  at
org.geotools.data.jdbc.JDBCFeatureWriter.write(JDBCFeatureWriter.java:215)
  at
org.geotools.data.InProcessLockingManager$1.write(InProcessLockingManager.java:335)
  at
org.geotools.data.jdbc.JDBCFeatureStore.addFeatures(JDBCFeatureStore.java:383)
  at
org.vfny.geoserver.global.GeoServerFeatureStore.addFeatures(GeoServerFeatureStore.java:81)
  at
org.geoserver.wfs.InsertElementHandler.execute(InsertElementHandler.java:169)
  ... 75 more

13:36:30,109 INFO [STDOUT] 08 Jul 13:36:30 INFO [geoserver.wfs] -
Request: transaction
  handle = null
  service = WFS
  version = 1.0.0
  baseUrl = http://localhost:8085/geoserver/
  providedVersion = 1.0.0
  lockId = null
  group = [wfs:insert=net.opengis.wfs.impl.InsertElementTypeImpl@anonymised.com
(feature: [org.geotools.feature.simple.SimpleFeatureImpl@anonymised.com], handle:
null, idgen: <unset>, inputFormat: <unset>, srsName: null)]
  insert = [net.opengis.wfs.impl.InsertElementTypeImpl@anonymised.com (feature:
[org.geotools.feature.simple.SimpleFeatureImpl@anonymised.com], handle: null,
idgen: <unset>, inputFormat: <unset>, srsName: null)]
  update =
  delete =
  native =
  releaseAction = ALL

------------------------------------------------
MY-HTML-Page

<html xmlns="http://www.w3.org/1999/xhtml&quot;&gt;
  <head>
    <title>Scribble on a WFS</title>
    <link rel="stylesheet" href="../theme/default/style.css" type="text/css"
/>
    <link rel="stylesheet" href="style.css" type="text/css" />
    <style type="text/css">
    
    #map {
            width: 800px;
            height: 475px;
            border: 1px solid black;
        }
    
        #controls {
            width: 512px;
        }
        #controlToggle {
            padding-left: 1em;
        }
        #controlToggle li {
            list-style: none;
        }
    </style>
    <script src="../lib/Firebug/firebug.js"></script>
    <script src="../lib/OpenLayers.js"></script>

    <script type="text/javascript">
        var map, vectors, controls;

        var DeleteFeature = OpenLayers.Class(OpenLayers.Control, {
            initialize: function(layer, options) {
                
                this.layer = layer;
                this.handler = new OpenLayers.Handler.Feature(
                    this, layer, {click: this.clickFeature}
                );
            },
            clickFeature: function(feature) {
                // if feature doesn't have a fid, destroy it
                if(feature.fid == undefined) {
                    this.layer.destroyFeatures([feature]);
                } else {
                    feature.state = OpenLayers.State.DELETE;
                    this.layer.events.triggerEvent("afterfeaturemodified",
                                                   {feature: feature});
                    feature.renderIntent = "select";
                    this.layer.drawFeature(feature);
                }
            },
            setMap: function(map) {
                this.handler.setMap(map);
                OpenLayers.Control.prototype.setMap.apply(this, arguments);
            },
            CLASS_NAME: "OpenLayers.Control.DeleteFeature"
        });

        function init(){
            map = new OpenLayers.Map('map');
            var wms = new OpenLayers.Layer.WMS( "OpenLayers WMS",
                "http://labs.metacarta.com/wms/vmap0?&quot;, {layers: 'basic'});
            OpenLayers.Feature.Vector.style['default']['strokeWidth'] = '2';
           // vectors = new OpenLayers.Layer.Vector("Vector Layer");

            vectors = new OpenLayers.Layer.WFS( "Scribble WFS",
                    "http://localhost:8085/geoserver/wfs&quot;,
                    { typename: 'max:MAX_GEO2' },
                    {
                      typename: 'MAX_GEO2',
                      featureNS: 'http://localhost:8085/max’,
                      extractAttributes: false
                    } );
            map.addLayers([wms, vectors]);
            
            map.addControl(new OpenLayers.Control.LayerSwitcher());
            map.addControl(new OpenLayers.Control.MousePosition());
            
            function report(event) {
                OpenLayers.Console.log(event.type, event.feature ?
event.feature.id : event.components);
            }
            vectors.events.on({
                "beforefeaturemodified": report,
                "featuremodified": report,
                "afterfeaturemodified": report,
                "vertexmodified": report,
                "sketchmodified": report,
                "sketchstarted": report,
                "sketchcomplete": report
            });
            controls = {
                point: new OpenLayers.Control.DrawFeature(vectors,
                            OpenLayers.Handler.Point),
                line: new OpenLayers.Control.DrawFeature(vectors,
                            OpenLayers.Handler.Path),
                polygon: new OpenLayers.Control.DrawFeature(vectors,
                            OpenLayers.Handler.Polygon),
                regular: new OpenLayers.Control.DrawFeature(vectors,
                            OpenLayers.Handler.RegularPolygon,
                            {handlerOptions: {sides: 5}}),
                modify: new OpenLayers.Control.ModifyFeature(vectors),
                deleteFeature: new DeleteFeature(vectors)
            };
            
            for(var key in controls) {
                map.addControl(controls[key]);
            }
            
            map.setCenter(new OpenLayers.LonLat(0, 0), 3);
            document.getElementById('noneToggle').checked = true;
        }
        
        function update() {
            // reset modification mode
            controls.modify.mode = OpenLayers.Control.ModifyFeature.RESHAPE;
            var rotate = document.getElementById("rotate").checked;
            if(rotate) {
                controls.modify.mode |=
OpenLayers.Control.ModifyFeature.ROTATE;
            }
            var resize = document.getElementById("resize").checked;
            if(resize) {
                controls.modify.mode |=
OpenLayers.Control.ModifyFeature.RESIZE;
                var keepAspectRatio =
document.getElementById("keepAspectRatio").checked;
                if (keepAspectRatio) {
                    controls.modify.mode &=
~OpenLayers.Control.ModifyFeature.RESHAPE;
                }
            }
            var drag = document.getElementById("drag").checked;
            if(drag) {
                controls.modify.mode |=
OpenLayers.Control.ModifyFeature.DRAG;
            }
            if (rotate || drag) {
                controls.modify.mode &=
~OpenLayers.Control.ModifyFeature.RESHAPE;
            }
            var sides = parseInt(document.getElementById("sides").value);
            sides = Math.max(3, isNaN(sides) ? 0 : sides);
            controls.regular.handler.sides = sides;
            var irregular = document.getElementById("irregular").checked;
            controls.regular.handler.irregular = irregular;
        }

        function toggleControl(element) {
            for(key in controls) {
                var control = controls[key];
                if(element.value == key && element.checked) {
                    control.activate();
                } else {
                    control.deactivate();
                }
            }
        }
        function save() {
            for(var i = 0; i < map.layers[1].features.length; i++) {
                var f = map.layers[1].features[i];
                //f.style['strokeColor'] = '#ee9900';
                alert( map.layers[1].features[i].geometry);
                map.layers[1].drawFeature(f);
            }
            map.layers[1].commit();
            return false;
        }
    </script>
  </head>
  <body onload="init()">
    <h1 id="title">OpenLayers Modify Feature Example</h1>
    <div id="shortdesc">A demonstration of the ModifyFeature control for
editing vector features.</div>
    
        <div style="float:left; text-align:left;">
     
< a href="#" onclick="return save()">Save |
< a href="#" onclick="map.layers[1].refresh(); return false">Refresh
(removes all newly added lines)</div><br />
    <div id="map" class="smallmap"></div>
    <div id="controls">

        <ul id="controlToggle">
            <li>
                <input type="radio" name="type" value="none" id="noneToggle"
                       onclick="toggleControl(this);" checked="checked" />
                <label for="noneToggle">navigate</label>
            </li>
            <li>
                <input type="radio" name="type" value="point"
id="pointToggle" onclick="toggleControl(this);" />
                <label for="pointToggle">draw point</label>

            </li>
            <li>
                <input type="radio" name="type" value="line" id="lineToggle"
onclick="toggleControl(this);" />
                <label for="lineToggle">draw line</label>
            </li>
            <li>
                <input type="radio" name="type" value="polygon"
id="polygonToggle" onclick="toggleControl(this);" />
                <label for="polygonToggle">draw polygon</label>

            </li>
            <li>
                <input type="radio" name="type" value="regular"
id="regularToggle" onclick="toggleControl(this);" />
                <label for="regularToggle">draw regular polygon</label>
                <label for="sides"> - sides</label>
                <input id="sides" type="text" size="2" maxlength="2"
                       name="sides" value="5" onchange="update()" />
                <ul>

                    <li>
                        <input id="irregular" type="checkbox"
                               name="irregular" onchange="update()" />
                        <label for="irregular">irregular</label>
                    </li>
                </ul>
            </li>
            </br>
              <li>
                <input type="radio" name="type" value="deleteFeature"
id="deleteToggle" onclick="toggleControl(this);" />
                <label for="polygonToggle">delete Feature</label>

            </li>
            </br>
            <li>
                <input type="radio" name="type" value="modify"
id="modifyToggle"
                       onclick="toggleControl(this);" />

                <label for="modifyToggle">modify feature</label>
                <ul>
                    <li>
                        <input id="rotate" type="checkbox"
                               name="rotate" onchange="update()" />
                        <label for="rotate">allow rotation</label>
                    </li>
                    <li>
                        <input id="resize" type="checkbox"
                               name="resize" onchange="update()" />

                        <label for="resize">allow resizing</label>
                        (<input id="keepAspectRatio" type="checkbox"
                               name="keepAspectRatio" onchange="update()"
checked="checked" />
                        <label for="keepAspectRatio">keep aspect
ratio</label>)
                    </li>
                    <li>
                        <input id="drag" type="checkbox"
                               name="drag" onchange="update()" />
                        <label for="drag">allow dragging</label>

                    </li>
                </ul>
            </li>
        </ul>
    </div>
  </body>
</html>

--
View this message in context: http://www.nabble.com/null-pointer-exception-in-oracle-WFS-insert-again-tp22102471p24390284.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Howie.Stuntman ha scritto:

Caused by: java.lang.NullPointerException
  at
org.geotools.data.oracle.OracleFeatureWriter.doInsert(OracleFeatureWriter.java:182)
  at

Hmm... this is the old Oracle datastore, and the issue is happening
because the geometry being inserted is null (along with a bug in the
datastore that does not foresee this case).

The old Oracle data store is no more being maintained, so we cannot offer help about it.
Can you try out the OracleNG one? If you encounter problems
with it we'll be able to offer some assistance

As for the geometry being null, it might be that the parser skipped it
because it was not conforming to the schema of the WFS version you're
trying to use (or, other simpler possibility, the geometry is really
null)
If you have specified a geometry make sure you're using the proper GML
encoding for the WFS version you're using, they are quite different.
WFS 1.1 uses GML 3, WFS 1.0 uses GML 2

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

Hello Andrea

thanks for your fast answer.
I have tested now the Oracle NG datastore plugin and there is no error
anymore.
But when i try to insert data to the table, the plugin creates a new dataset
but without a geometry in the geometry column.
I have tested the same code with an Shapefile as datasource and it works.

If there are any ideas whats wrong i would like to here it!!!
And if there are more questions about the problem i would try to answer
them.

Cheers
Howie

Andrea Aime-4 wrote:

Howie.Stuntman ha scritto:

Caused by: java.lang.NullPointerException
  at
org.geotools.data.oracle.OracleFeatureWriter.doInsert(OracleFeatureWriter.java:182)
  at

Hmm... this is the old Oracle datastore, and the issue is happening
because the geometry being inserted is null (along with a bug in the
datastore that does not foresee this case).

The old Oracle data store is no more being maintained, so we cannot
offer help about it.
Can you try out the OracleNG one? If you encounter problems
with it we'll be able to offer some assistance

As for the geometry being null, it might be that the parser skipped it
because it was not conforming to the schema of the WFS version you're
trying to use (or, other simpler possibility, the geometry is really
null)
If you have specified a geometry make sure you're using the proper GML
encoding for the WFS version you're using, they are quite different.
WFS 1.1 uses GML 3, WFS 1.0 uses GML 2

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.

------------------------------------------------------------------------------
Enter the BlackBerry Developer Challenge
This is your chance to win up to $100,000 in prizes! For a limited time,
vendors submitting new applications to BlackBerry App World(TM) will have
the opportunity to enter the BlackBerry Developer Challenge. See full
prize
details at: http://p.sf.net/sfu/Challenge
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

--
View this message in context: http://www.nabble.com/null-pointer-exception-in-oracle-WFS-insert-again-tp22102471p24405510.html
Sent from the GeoServer - User mailing list archive at Nabble.com.

Howie.Stuntman ha scritto:

Hello Andrea

thanks for your fast answer.
I have tested now the Oracle NG datastore plugin and there is no error
anymore.
But when i try to insert data to the table, the plugin creates a new dataset
but without a geometry in the geometry column.
I have tested the same code with an Shapefile as datasource and it works.

You mean, the very same request against a shapefile with the same
structure as your Oracle table?
I already told you what the most likely reason for a null geometry is
in my original mail, did you double check WFS and GML schema conformance? See below:

As for the geometry being null, it might be that the parser skipped it
because it was not conforming to the schema of the WFS version you're
trying to use (or, other simpler possibility, the geometry is really
null)
If you have specified a geometry make sure you're using the proper GML
encoding for the WFS version you're using, they are quite different.
WFS 1.1 uses GML 3, WFS 1.0 uses GML 2

A way to make GeoServer perform the schema check for you is to post to:

http://host:port/geoserver/wfs?strict=true

That URL triggers schema validation on every request.

If this does not help please provide enough SQL to rebuild your table
and the WFS request that's failing for you so that we can debug it
locally.

Cheers
Andrea

--
Andrea Aime
OpenGeo - http://opengeo.org
Expert service straight from the developers.