Primary Key Lookup fails for Oracle tables with underscores in their name

Description

When inserting features into a table in an Oracle Datastore, if the table name contains underscores, then:
The primary key lookup will fail:

Because the primary key lookup fails, the primary key is null and we get a read-only FeatureSource, causing the insert to fail:

This is particularily notable when using the importer extension to import shapefiles.

It looks like this error is related to the changes made here: https://github.com/geotools/geotools/commit/3a98d302b9f41006e33da51cc107ba7449e471f9 (Fix for )

seems to be caused by a similar problem.

Environment

Oracle 11.2 running on Windows 2003 server.
Issue was observed on various remote instances of GeoServer 2.7

Status

Assignee

Unassigned

Reporter

Torben Barsballe

Triage

None

Components

Fix versions

Priority

Medium
Configure