openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From jrba...@apache.org
Subject svn commit: r899784 [11/11] - in /openjpa/trunk: openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/conf/ openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/identifier/ openjpa-jdbc/src/main/java/org/apache/openjpa/jdbc/kernel/ openjpa-jdbc/src/main/ja...
Date Fri, 15 Jan 2010 19:38:26 GMT
Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityA.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityA.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityA.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityA.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,111 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+import java.util.Set;
+
+public class EntityA {
+    private int id;
+    private String name;
+    
+    private String secName;
+    
+    private Set<String> delimSet = new HashSet<String>();
+    private Map<String, String> delimMap = 
+        new HashMap<String, String>();
+    
+    public EntityA(){
+    }
+    
+    public EntityA(int id, String name) {
+        this.name=name;
+    }
+    
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * @return the secName
+     */
+    public String getSecName() {
+        return secName;
+    }
+
+    /**
+     * @param secName the secName to set
+     */
+    public void setSecName(String secName) {
+        this.secName = secName;
+    }
+
+    public Set<String> getDelimSet() {
+        return delimSet;
+    }
+
+    public void setDelimSet(Set<String> collectionDelimSet) {
+        this.delimSet = collectionDelimSet;
+    }
+    
+    public void addDelimSet(String item) {
+        this.delimSet.add(item);
+    }
+
+    /**
+     * @return the delimCollectionMap
+     */
+    public Map<String, String> getDelimMap() {
+        return delimMap;
+    }
+
+    /**
+     * @param delimCollectionMap the delimCollectionMap to set
+     */
+    public void setDelimMap(Map<String, String> delimMap) {
+        this.delimMap = delimMap;
+    }
+    
+    public void addDelimMap(String key, String value) {
+        this.delimMap.put(key, value);
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityA.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityB.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityB.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityB.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityB.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,54 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+public class EntityB {
+    private int id;
+    private String name;
+    
+    public EntityB(String name) {
+        this.name = name;
+    }
+    
+    
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityB.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityH.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityH.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityH.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityH.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,152 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import java.util.Collection;
+import java.util.HashMap;
+import java.util.HashSet;
+import java.util.Map;
+
+public class EntityH {
+    private int id;
+    private String name;
+    
+    private String secName;
+    
+    private Collection<EntityI> entityIs = new HashSet<EntityI>();
+    
+    private EntityI2 entityI2;
+    
+    Map<EntityI3,EntityI4> map = new HashMap<EntityI3,EntityI4>();
+    
+    Map<EntityI4,EntityI3> map2 = new HashMap<EntityI4,EntityI3>();
+
+    public EntityH() {}
+    
+    public EntityH(int id) {
+        this.id = id;
+    }
+
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * @return the secName
+     */
+    public String getSecName() {
+        return secName;
+    }
+
+    /**
+     * @param secName the secName to set
+     */
+    public void setSecName(String secName) {
+        this.secName = secName;
+    }
+    
+    public Collection<EntityI> getEntityIs() {
+        return entityIs;
+    }
+    /**
+     * @param entityIs the entityIs to set
+     */
+    public void setEntityIs(Collection<EntityI> entityIs) {
+        this.entityIs = entityIs;
+    }
+    
+    public void addEntityI(EntityI entityI) {
+        entityIs.add(entityI);
+    }
+
+    /**
+     * @return the entityI2
+     */
+    public EntityI2 getEntityI2() {
+        return entityI2;
+    }
+
+    /**
+     * @param entityI2 the entityI2 to set
+     */
+    public void setEntityI2(EntityI2 entityI2) {
+        this.entityI2 = entityI2;
+    }
+
+    /**
+     * @return the map
+     */
+    public Map<EntityI3, EntityI4> getMap() {
+        return map;
+    }
+
+    /**
+     * @param map the map to set
+     */
+    public void setMap(Map<EntityI3, EntityI4> map) {
+        this.map = map;
+    }
+    
+    public void addMapValues(EntityI3 key, EntityI4 value) {
+        map.put(key, value);
+    }
+
+    /**
+     * @return the map2
+     */
+    public Map<EntityI4, EntityI3> getMap2() {
+        return map2;
+    }
+
+    /**
+     * @param map2 the map2 to set
+     */
+    public void setMap2(Map<EntityI4, EntityI3> map2) {
+        this.map2 = map2;
+    }
+    
+    public void addMap2Values(EntityI4 key, EntityI3 value) {
+        map2.put(key, value);
+    }
+
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityH.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,80 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import java.util.Collection;
+import java.util.HashSet;
+
+public class EntityI {
+    private int id;
+    private String name;
+    private Collection<EntityH> entityHs = new HashSet<EntityH>();
+    
+    public EntityI() {}
+    
+    public EntityI(int id) {
+        this.id = id;
+    }
+
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * @return the entityHs
+     */
+    public Collection<EntityH> getEntityHs() {
+        return entityHs;
+    }
+
+    /**
+     * @param entityHs the entityHs to set
+     */
+    public void setEntityHs(Collection<EntityH> entityHs) {
+        this.entityHs = entityHs;
+    }
+    
+    public void addEntityH(EntityH entityH) {
+        entityHs.add(entityH);
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI2.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI2.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI2.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI2.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+public class EntityI2 {
+    private int id;
+    private String name;
+    
+    private EntityI3 entityI3;
+    
+    public EntityI2() {}
+    
+    public EntityI2(int id) {
+        this.id = id;
+    }
+
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+    /**
+     * @return the entityI3
+     */
+    public EntityI3 getEntityI3() {
+        return entityI3;
+    }
+
+    /**
+     * @param entityI3 the entityI3 to set
+     */
+    public void setEntityI3(EntityI3 entityI3) {
+        this.entityI3 = entityI3;
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI2.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI3.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI3.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI3.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI3.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,56 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+public class EntityI3 {
+    int id;
+    String name;
+    
+    public EntityI3() {}
+    
+    public EntityI3(int id) {
+        this.id = id;
+    }
+    
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI3.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI4.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI4.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI4.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI4.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,56 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+public class EntityI4 {
+    int id;
+    String name;
+    
+    public EntityI4() {}
+    
+    public EntityI4(int id) {
+        this.id = id;
+    }
+    
+    /**
+     * @return the id
+     */
+    public int getId() {
+        return id;
+    }
+    /**
+     * @param id the id to set
+     */
+    public void setId(int id) {
+        this.id = id;
+    }
+    /**
+     * @return the name
+     */
+    public String getName() {
+        return name;
+    }
+    /**
+     * @param name the name to set
+     */
+    public void setName(String name) {
+        this.name = name;
+    }
+
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/EntityI4.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,27 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+public class Pontiac extends Car {
+    public Pontiac() {}
+    
+    public Pontiac(int id) {
+        super(id);
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac2.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac2.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac2.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac2.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,32 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import javax.persistence.DiscriminatorValue;
+import javax.persistence.Entity;
+
+//@Entity
+//@DiscriminatorValue("Pontiac")
+public class Pontiac2 extends Car2 {
+    public Pontiac2() {}
+    
+    public Pontiac2(int id) {
+        super(id);
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/Pontiac2.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdResultSets.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdResultSets.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdResultSets.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdResultSets.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,124 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import java.util.List;
+
+import javax.persistence.Query;
+
+import org.apache.openjpa.persistence.OpenJPAEntityManager;
+import org.apache.openjpa.persistence.OpenJPAEntityManagerFactorySPI;
+import org.apache.openjpa.persistence.test.SQLListenerTestCase;
+
+public class TestXmlDelimIdResultSets 
+        extends SQLListenerTestCase {
+    OpenJPAEntityManager em;
+    int id = 0;
+    Car car;
+    Pontiac pontiac;
+    Chevrolet chevrolet;
+    Car2 car2;
+    Pontiac2 pontiac2;
+    Chevrolet2 chevrolet2;
+    
+    @Override
+    public void setUp() throws Exception {
+        setSupportedDatabases(
+            org.apache.openjpa.jdbc.sql.DerbyDictionary.class,
+            org.apache.openjpa.jdbc.sql.DB2Dictionary.class);
+        if (isTestsDisabled()) {
+            return;
+        }
+        
+        super.setUp(
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Car.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Pontiac.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Chevrolet.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Car2.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Pontiac2.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Chevrolet2.class,
+            DROP_TABLES);
+        assertNotNull(emf);
+        
+        em = emf.createEntityManager();
+        assertNotNull(em);
+    }
+    
+    @Override
+    protected String getPersistenceUnitName() {
+        return "delimited-identifiers-result-set-xml";
+    }    
+    
+    private void createChevrolet(int id) {
+        chevrolet = new Chevrolet(id);
+        chevrolet.setModel("Malibu");
+        chevrolet.setColor("black");
+        chevrolet.setModelYear("2009");
+    }
+
+    private void createPontiac(int id) {
+        pontiac = new Pontiac(id);
+        pontiac.setModel("G6");
+        pontiac.setColor("red");
+        pontiac.setModelYear("2005");
+    }
+
+    public void testCreate() {
+        id++;
+        createPontiac(id);
+        id++;
+        createChevrolet(id);
+        
+        em.getTransaction().begin();
+        em.persist(pontiac);
+        em.persist(chevrolet);
+        em.getTransaction().commit();
+        
+        runQueries();
+    }
+    
+    private void runQueries() {
+        em.clear();
+        resultSetQuery();
+    }
+    
+    private void resultSetQuery() {
+        String query = 
+            "SELECT c.id, c.\"car model\", c.\"car color\", " +
+            "c.\"discr col\", c.\"model year\" " +
+            "FROM \"XmlCar\" c ";
+        Query q = em.createNativeQuery(query,"XmlCarResultSet");
+        List<Object[]> results = (List<Object[]>)q.getResultList();
+        assertEquals(2,results.size());
+        
+        for (Object[] result : results) {
+            assertEquals(2, result.length);
+            assertTrue(result[0] instanceof Car2);
+            assertTrue(result[1] instanceof String);
+            Car2 car2 = (Car2)result[0];
+            String modelYear = (String)result[1];
+            if (car2.getModel().equals("G6")) {
+                assertEquals("2005", modelYear);
+            }
+            else if (car2.getModel().equals("Malibu")) {
+                assertEquals("2009", modelYear);
+            }
+        }
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdResultSets.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdSeqGen.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdSeqGen.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdSeqGen.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdSeqGen.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,82 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import org.apache.openjpa.jdbc.conf.JDBCConfiguration;
+import org.apache.openjpa.jdbc.sql.DBDictionary;
+import org.apache.openjpa.persistence.OpenJPAEntityManager;
+import org.apache.openjpa.persistence.test.SQLListenerTestCase;
+
+public class TestXmlDelimIdSeqGen extends SQLListenerTestCase {
+    OpenJPAEntityManager em;
+    JDBCConfiguration conf;
+    DBDictionary dict;
+    boolean supportsNativeSequence = false;
+    
+    EntityB entityB;
+    
+    @Override
+    public void setUp() throws Exception {
+        setSupportedDatabases(
+            org.apache.openjpa.jdbc.sql.DB2Dictionary.class);
+        if (isTestsDisabled()) {
+            return;
+        }
+        
+        super.setUp(org.apache.openjpa.persistence.delimited.identifiers.xml.EntityB.class, DROP_TABLES);
+        assertNotNull(emf);
+        
+        conf = (JDBCConfiguration) emf.getConfiguration();
+        dict = conf.getDBDictionaryInstance();
+        supportsNativeSequence = dict.nextSequenceQuery != null;
+        
+        if (supportsNativeSequence) {
+            em = emf.createEntityManager();
+            assertNotNull(em);
+        }
+    }
+    
+    @Override
+    protected String getPersistenceUnitName() {
+        return "delimited-identifiers-seq-gen-xml";
+    }    
+    
+    public void createEntityB() {
+        entityB = new EntityB("b name");
+    }
+    
+    public void testSeqGen() {
+        if (!supportsNativeSequence) {
+            return;
+        }
+        createEntityB();
+        
+        em.getTransaction().begin();
+        em.persist(entityB);
+        em.getTransaction().commit();
+        
+        int genId = entityB.getId();
+        em.clear();
+        em.getTransaction().begin();
+        EntityB bA = em.find(EntityB.class, genId);
+        assertEquals("b name", bA.getName());
+        em.getTransaction().commit();
+        em.close();
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimIdSeqGen.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimInheritance.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimInheritance.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimInheritance.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimInheritance.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,113 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import java.util.List;
+
+import javax.persistence.Query;
+
+import org.apache.openjpa.persistence.OpenJPAEntityManager;
+import org.apache.openjpa.persistence.OpenJPAEntityManagerFactorySPI;
+import org.apache.openjpa.persistence.test.SQLListenerTestCase;
+
+public class TestXmlDelimInheritance extends SQLListenerTestCase {
+    OpenJPAEntityManager em;
+    int id = 0;
+    Pontiac pontiac;
+    Chevrolet chevrolet;
+    
+    @Override
+    public void setUp() throws Exception {
+        setSupportedDatabases(
+            org.apache.openjpa.jdbc.sql.DerbyDictionary.class,
+            org.apache.openjpa.jdbc.sql.DB2Dictionary.class);
+        if (isTestsDisabled()) {
+            return;
+        }
+        
+        super.setUp(
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Car.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Pontiac.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.Chevrolet.class,
+            DROP_TABLES);
+        assertNotNull(emf);
+        
+        em = emf.createEntityManager();
+        assertNotNull(em);
+    }
+    
+    @Override
+    protected String getPersistenceUnitName() {
+        return "delimited-identifiers-inheritance-xml";
+    }    
+    
+    private void createPontiac(int id) {
+        pontiac = new Pontiac(id);
+        pontiac.setModel("G6");
+        pontiac.setColor("red");
+    }
+    
+    private void createChevrolet(int id) {
+        chevrolet = new Chevrolet(id);
+        chevrolet.setModel("Malibu");
+        chevrolet.setColor("black");
+    }
+    
+    public void testCreate() {
+        id++;
+        createPontiac(id);
+        id++;
+        createChevrolet(id);
+        
+        em.getTransaction().begin();
+        em.persist(pontiac);
+        em.persist(chevrolet);
+        em.getTransaction().commit();
+        
+        runQueries();
+    }
+    
+    private void runQueries() {
+        em.clear();
+        queryChevrolet();
+        em.clear();
+        queryPontiac();
+    }
+    
+    private void queryChevrolet() {
+        String query =
+            "SELECT DISTINCT c " +
+            "FROM Car c " +
+            "WHERE c.model = 'Malibu'";
+        Query q = em.createQuery(query);
+        List<Car> results = (List<Car>)q.getResultList();
+        assertEquals(1,results.size());
+    }
+    
+    // Use native query
+    private void queryPontiac() {
+        String query = 
+            "SELECT * " +
+            "FROM \"XICar\" c " +
+            "WHERE c.\"discr col\" = 'Pontiac'";
+        Query q = em.createNativeQuery(query);
+        List<Car> results = (List<Car>)q.getResultList();
+        assertEquals(1,results.size());
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimInheritance.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedIdentifiers.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedIdentifiers.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedIdentifiers.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedIdentifiers.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,74 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import org.apache.openjpa.jdbc.sql.DB2Dictionary;
+import org.apache.openjpa.jdbc.sql.DerbyDictionary;
+import org.apache.openjpa.persistence.OpenJPAEntityManager;
+import org.apache.openjpa.persistence.test.SQLListenerTestCase;
+
+public class TestXmlDelimitedIdentifiers extends SQLListenerTestCase {
+    OpenJPAEntityManager em;
+    int id = 0;
+    
+    EntityA entityA;
+    
+    public void setUp() throws Exception {
+        setSupportedDatabases(DB2Dictionary.class, DerbyDictionary.class);
+        if (isTestsDisabled())
+            return;
+        
+        super.setUp(org.apache.openjpa.persistence.delimited.identifiers.xml.EntityA.class, DROP_TABLES);
+        assertNotNull(emf);
+        
+        em = emf.createEntityManager();
+        assertNotNull(em);
+    }
+    
+    @Override
+    protected String getPersistenceUnitName() {
+        return "delimited-identifiers-xml";
+    }
+    
+    public void createEntityA(int id) {
+        entityA = new EntityA(id, "aName");
+        entityA.setSecName("sec name");
+        entityA.addDelimSet("aaa");
+        entityA.addDelimSet("bbb");
+        entityA.addDelimMap("ccc", "ddd");
+    }
+    
+    public void testTableName() {
+        id++;
+        createEntityA(id);
+        
+        em.getTransaction().begin();
+        em.persist(entityA);
+        em.getTransaction().commit();
+        
+        int genId = entityA.getId();
+        em.clear();
+        em.getTransaction().begin();
+        EntityA eA = em.find(EntityA.class, genId);
+        assertEquals("aName", eA.getName());
+        
+        em.getTransaction().commit();
+        em.close();
+    }
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedIdentifiers.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedJoinAnnotation.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedJoinAnnotation.java?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedJoinAnnotation.java (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedJoinAnnotation.java Fri Jan 15 19:38:18 2010
@@ -0,0 +1,161 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing,
+ * software distributed under the License is distributed on an
+ * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ * KIND, either express or implied.  See the License for the
+ * specific language governing permissions and limitations
+ * under the License.
+ */
+package org.apache.openjpa.persistence.delimited.identifiers.xml;
+
+import java.util.List;
+
+import javax.persistence.Query;
+
+import org.apache.openjpa.jdbc.conf.JDBCConfiguration;
+import org.apache.openjpa.persistence.OpenJPAEntityManager;
+import org.apache.openjpa.persistence.OpenJPAEntityManagerFactorySPI;
+import org.apache.openjpa.persistence.test.SQLListenerTestCase;
+
+public class TestXmlDelimitedJoinAnnotation extends SQLListenerTestCase {
+    OpenJPAEntityManager em;
+    int id = 0;
+    EntityH entityH;
+    EntityI entityI;
+    EntityI2 entityI2;
+    EntityI3 entityI3;
+    EntityI4 entityI4;
+    
+    @Override
+    public void setUp() throws Exception {
+        setSupportedDatabases(
+            org.apache.openjpa.jdbc.sql.DerbyDictionary.class,
+            org.apache.openjpa.jdbc.sql.DB2Dictionary.class);
+        if (isTestsDisabled()) {
+            return;
+        }
+        
+        super.setUp(
+            org.apache.openjpa.persistence.delimited.identifiers.xml.EntityH.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI2.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI3.class,
+            org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI4.class,
+            DROP_TABLES);
+        assertNotNull(emf);
+        
+        em = emf.createEntityManager();
+        assertNotNull(em);
+    }
+    
+    @Override
+    protected String getPersistenceUnitName() {
+        return "delimited-identifiers-joins-xml";
+    }    
+    
+    public void createHandI(int id) {
+        entityH = new EntityH(id);
+        entityH.setName("eh");
+        entityH.setSecName("secName1");
+        
+        entityI = new EntityI(id);
+        entityI.setName("ei");
+        
+        entityI2 = new EntityI2(id);
+        entityI2.setName("ei2");
+        
+        entityI3 = new EntityI3(id);
+        entityI3.setName("ei3");
+        
+        entityI4 = new EntityI4(id);
+        entityI4.setName("ei4");
+        
+        entityH.addEntityI(entityI);
+        entityI.addEntityH(entityH);
+        
+        entityH.setEntityI2(entityI2);
+        
+        entityH.addMapValues(entityI3, entityI4);
+        entityH.addMap2Values(entityI4, entityI3);
+        
+        entityI2.setEntityI3(entityI3);
+    }
+
+    public void testCreate() {
+        id++;
+        createHandI(id);
+        
+        em.getTransaction().begin();
+        em.persist(entityH);
+        em.persist(entityI);
+        em.persist(entityI2);
+        em.persist(entityI3);
+        em.persist(entityI4);
+        em.getTransaction().commit();
+        
+        runQueries();
+    }
+    
+    private void runQueries() {
+        em.clear();
+        queryJoinTable();
+        em.clear();
+        queryJoinColumn();
+        em.clear();
+        querySecondaryTableValue();
+        em.clear();
+        queryMapValue();
+    }
+    
+    private void queryJoinTable() {
+        String query =
+            "SELECT h " +
+            "FROM EntityH h JOIN h.entityIs i " +
+            "WHERE i.name = 'ei'";
+        Query q = em.createQuery(query);
+        List<EntityH> results = (List<EntityH>)q.getResultList();
+        assertEquals(1,results.size());
+    }
+
+    private void queryJoinColumn() {
+        String query = 
+            "SELECT h " +
+            "FROM EntityH h JOIN h.entityI2 i2 " +
+            "WHERE i2.name = 'ei2'";
+        Query q = em.createQuery(query);
+        List<EntityH> results = (List<EntityH>)q.getResultList();
+        assertEquals(1,results.size());
+    }
+
+    private void querySecondaryTableValue() {
+        String query = 
+            "SELECT h " +
+            "FROM EntityH h " +
+            "WHERE h.secName = 'secName1'";
+        Query q = em.createQuery(query);
+        List<EntityH> results = (List<EntityH>)q.getResultList();
+        assertEquals(1,results.size());
+    }
+
+    private void queryMapValue() {
+        String query =
+            "SELECT h " +
+            "FROM EntityH h, IN(h.map2) m " +
+            "WHERE m.name = 'ei3'";
+        Query q = em.createQuery(query);
+        List<EntityH> results = (List<EntityH>)q.getResultList();
+        assertEquals(1,results.size());
+    }
+    
+    
+}

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/delimited/identifiers/xml/TestXmlDelimitedJoinAnnotation.java
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delim_persistence.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delim_persistence.xml?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delim_persistence.xml (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delim_persistence.xml Fri Jan 15 19:38:18 2010
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements.  See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership.  The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License.  You may obtain a copy of the License at
+ 
+ http://www.apache.org/licenses/LICENSE-2.0
+ 
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied.  See the License for the
+ specific language governing permissions and limitations
+ under the License.   
+-->
+<persistence xmlns="http://java.sun.com/xml/ns/persistence"
+    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+    version="2.0">
+    <persistence-unit name="delim-persistence-unit">
+        <description>
+            Special PU for enhancing XML-defined entities used in delimited
+            identifiers tests.  Mixing them in the default xml PU caused problems
+            on databases such as Oracle and MySQL which do not behave well when
+            a non-default schema name is specified in the mapping information.
+        </description>
+        <mapping-file>META-INF/delimited-identifiers-joins-orm.xml</mapping-file>
+        <mapping-file>META-INF/delimited-identifiers-result-set-orm.xml</mapping-file>
+        <mapping-file>META-INF/delimited-identifiers-xml-orm.xml</mapping-file>
+        <mapping-file>META-INF/delimited-identifiers-seq-gen-xml-orm.xml</mapping-file>
+        <properties>
+            <property name="openjpa.jdbc.SynchronizeMappings"
+                value="buildSchema(ForeignKeys=true)"/>
+        </properties>
+    </persistence-unit>
+</persistence>
\ No newline at end of file

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delim_persistence.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-inheritance-xml-orm.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-inheritance-xml-orm.xml?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-inheritance-xml-orm.xml (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-inheritance-xml-orm.xml Fri Jan 15 19:38:18 2010
@@ -0,0 +1,51 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements.  See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership.  The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License.  You may obtain a copy of the License at
+ 
+ http://www.apache.org/licenses/LICENSE-2.0
+ 
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied.  See the License for the
+ specific language governing permissions and limitations
+ under the License.   
+-->
+<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm" 
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
+                    http://java.sun.com/xml/ns/persistence/orm_2_0.xsd" 
+version="2.0">
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Car">
+		<table name="&quot;XICar&quot;"/>
+		<inheritance/>
+		<discriminator-column name="&quot;discr col&quot;" column-definition="VARCHAR(10)"/>
+		<attributes>
+			<id name="id"/>
+			<basic name="model">
+				<column name="&quot;car model&quot;"/>
+			</basic>
+			<basic name="color">
+				<column name="&quot;car color&quot;"/>
+			</basic>
+			<basic name="modelYear">
+				<column name="&quot;model year&quot;"/>
+			</basic>
+		</attributes>
+	</entity>	
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Pontiac">
+		<discriminator-value>Pontiac</discriminator-value>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Chevrolet">
+		<discriminator-value>Chevrolet</discriminator-value>
+	</entity>
+
+</entity-mappings>
\ No newline at end of file

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-inheritance-xml-orm.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-joins-orm.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-joins-orm.xml?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-joins-orm.xml (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-joins-orm.xml Fri Jan 15 19:38:18 2010
@@ -0,0 +1,104 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements.  See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership.  The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License.  You may obtain a copy of the License at
+ 
+ http://www.apache.org/licenses/LICENSE-2.0
+ 
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied.  See the License for the
+ specific language governing permissions and limitations
+ under the License.   
+-->
+<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm" 
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
+                    http://java.sun.com/xml/ns/persistence/orm_2_0.xsd" 
+version="2.0">
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityH">
+		<table name="&quot;entity h&quot;" schema="&quot;delim xml&quot;"/>
+		<secondary-table name="&quot;h sec join table&quot;" schema="&quot;delim xml&quot;">
+			<primary-key-join-column name="&quot;entity h&quot;" referenced-column-name="&quot;h id&quot;"/>
+		</secondary-table>
+		<attributes>
+			<id name="id">
+				<column name="&quot;h id&quot;"/>
+			</id>
+			<basic name="name"/>
+			<basic name="secName">
+				<column name="&quot;h sec join table&quot;"/>
+			</basic>
+			
+			<one-to-one name="entityI2">
+				<join-column name="&quot;enti2 id&quot;" referenced-column-name="&quot;entityI2 id&quot;"
+					table="&quot;join column&quot;"/>
+			</one-to-one>
+			
+			<many-to-many name="entityIs">
+				<join-table name="&quot;h i&quot;" schema="&quot;delim xml&quot;"/>
+			</many-to-many>
+			
+			<many-to-many name="map">
+				<map-key-join-column name="&quot;map_ei3&quot;" referenced-column-name="&quot;entityI3 id&quot;"/>
+				<join-table name="&quot;map3 join table&quot;" schema="&quot;delim xml&quot;"/>
+			</many-to-many>
+			
+			<many-to-many name="map2">
+				<map-key-join-column name="&quot;map ei4&quot;" referenced-column-name="&quot;entityI4 id&quot;"
+					table="&quot;map key join column&quot;"/>
+				<join-table name="&quot;map4 join table&quot;" schema="&quot;delim xml&quot;"/>
+			</many-to-many>
+		</attributes>
+	</entity>	
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI">
+		<table name="&quot;entity i&quot;" schema="&quot;delim xml&quot;"/>
+		<attributes>
+			<id name="id"/>
+			<many-to-many name="entityHs" mapped-by="entityIs"/>
+		</attributes>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI2">
+		<table name="&quot;entity i2&quot;" schema="&quot;delim xml&quot;"/>
+		<attributes>
+			<id name="id">
+				<column name="&quot;entityI2 id&quot;"/>
+			</id>
+			<basic name="name"/>
+			<one-to-one name="entityI3">
+				<primary-key-join-column/>
+			</one-to-one>
+		</attributes>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI3">
+		<table name="&quot;entity i3&quot;" schema="&quot;delim xml&quot;"/>
+		<attributes>
+			<id name="id">
+				<column name="&quot;entityI3 id&quot;"/>
+			</id>
+			<basic name="name"/>
+		</attributes>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityI4">
+		<table name="&quot;entity i4&quot;" schema="&quot;delim xml&quot;"/>
+		<attributes>
+			<id name="id">
+				<column name="&quot;entityI4 id&quot;"/>
+			</id>
+			<basic name="name"/>
+		</attributes>
+	</entity>
+	
+	
+
+</entity-mappings>
\ No newline at end of file

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-joins-orm.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-result-set-orm.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-result-set-orm.xml?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-result-set-orm.xml (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-result-set-orm.xml Fri Jan 15 19:38:18 2010
@@ -0,0 +1,79 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements.  See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership.  The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License.  You may obtain a copy of the License at
+ 
+ http://www.apache.org/licenses/LICENSE-2.0
+ 
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied.  See the License for the
+ specific language governing permissions and limitations
+ under the License.   
+-->
+<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm" 
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
+                    http://java.sun.com/xml/ns/persistence/orm_2_0.xsd" 
+version="2.0">
+	<sql-result-set-mapping name="XmlCarResultSet">
+		<entity-result entity-class="org.apache.openjpa.persistence.delimited.identifiers.xml.Car2"
+				discriminator-column="&quot;discr col&quot;">
+			<field-result name="model" column="&quot;car model&quot;"/>
+			<field-result name="color" column="&quot;car color&quot;"/>
+		</entity-result>
+		<column-result name="&quot;model year&quot;"/>
+	</sql-result-set-mapping>
+
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Car">
+		<table name="&quot;XmlCar&quot;"/>
+		<inheritance/>
+		<discriminator-column name="&quot;discr col&quot;" column-definition="VARCHAR(10)"/>
+		<attributes>
+			<id name="id"/>
+			<basic name="model">
+				<column name="&quot;car model&quot;"/>
+			</basic>
+			<basic name="color">
+				<column name="&quot;car color&quot;"/>
+			</basic>
+			<basic name="modelYear">
+				<column name="&quot;model year&quot;"/>
+			</basic>
+		</attributes>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Car2">
+		<table name="&quot;XmlCar2&quot;"/>
+		<inheritance/>
+		<discriminator-column name="&quot;discr col&quot;" column-definition="VARCHAR(10)"/>
+		<attributes>
+			<id name="id"/>
+			<basic name="color"/>
+			<basic name="model"/>
+		</attributes>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Pontiac">
+		<discriminator-value>Pontiac</discriminator-value>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Chevrolet">
+		<discriminator-value>Chevrolet</discriminator-value>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Pontiac2">
+		<discriminator-value>Pontiac</discriminator-value>
+	</entity>
+	
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.Chevrolet2">
+		<discriminator-value>Chevrolet</discriminator-value>
+	</entity>
+
+</entity-mappings>
\ No newline at end of file

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-result-set-orm.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-seq-gen-xml-orm.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-seq-gen-xml-orm.xml?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-seq-gen-xml-orm.xml (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-seq-gen-xml-orm.xml Fri Jan 15 19:38:18 2010
@@ -0,0 +1,39 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements.  See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership.  The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License.  You may obtain a copy of the License at
+ 
+ http://www.apache.org/licenses/LICENSE-2.0
+ 
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied.  See the License for the
+ specific language governing permissions and limitations
+ under the License.   
+-->
+<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm" 
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
+                    http://java.sun.com/xml/ns/persistence/orm_2_0.xsd" 
+version="2.0">
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityB">
+		<table name="&quot;entityB xml&quot;" schema="&quot;delim xml&quot;"/>
+		<attributes>
+			<id name="id">
+				<generated-value strategy="SEQUENCE" generator="xml-seq-gen"/>
+				<sequence-generator name="xml-seq-gen" sequence-name="&quot;xml seq gen&quot;"
+					schema="&quot;delim xml&quot;"/>
+			</id>
+			<basic name="name">
+				<column name="&quot;b name&quot;"/>
+			</basic>
+		</attributes>
+	</entity>	
+
+</entity-mappings>
\ No newline at end of file

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-seq-gen-xml-orm.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Added: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-xml-orm.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-xml-orm.xml?rev=899784&view=auto
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-xml-orm.xml (added)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-xml-orm.xml Fri Jan 15 19:38:18 2010
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one
+ or more contributor license agreements.  See the NOTICE file
+ distributed with this work for additional information
+ regarding copyright ownership.  The ASF licenses this file
+ to you under the Apache License, Version 2.0 (the
+ "License"); you may not use this file except in compliance
+ with the License.  You may obtain a copy of the License at
+ 
+ http://www.apache.org/licenses/LICENSE-2.0
+ 
+ Unless required by applicable law or agreed to in writing,
+ software distributed under the License is distributed on an
+ "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+ KIND, either express or implied.  See the License for the
+ specific language governing permissions and limitations
+ under the License.   
+-->
+<entity-mappings xmlns="http://java.sun.com/xml/ns/persistence/orm" 
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+xsi:schemaLocation="http://java.sun.com/xml/ns/persistence/orm
+                    http://java.sun.com/xml/ns/persistence/orm_2_0.xsd" 
+version="2.0">
+	<entity class="org.apache.openjpa.persistence.delimited.identifiers.xml.EntityA">
+		<table name="&quot;xml entityA&quot;" schema="&quot;delim xml&quot;"/>
+		<secondary-table name="&quot;sec tbl A xml&quot;" schema="&quot;delim xml&quot;">
+			<unique-constraint name="&quot;xml sec unq&quot;">
+				<column-name>&quot;sec col name&quot;</column-name>
+			</unique-constraint>
+		</secondary-table>
+		<attributes>
+			<id name="id">
+				<generated-value strategy="TABLE" generator="xml-id-gen"/>
+				<table-generator name="xml-id-gen" table="&quot;xml id gen&quot;" schema="&quot;delim xml&quot;"
+					pk-column-name="&quot;xml gen pk&quot;" value-column-name="&quot;xml gen value&quot;"/>
+			</id>
+			<basic name="name">
+				<column name="&quot;pri col name&quot;" column-definition="VARCHAR"/>
+			</basic>
+			<basic name="secName">
+				<column name="&quot;sec col name&quot;" table="&quot;sec tbl A xml&quot;"/>
+			</basic>
+			<element-collection name="delimSet">
+				<order-column name="&quot;order col xml&quot;"/>
+				<collection-table name="&quot;xml delim set&quot;" schema="&quot;delim xml&quot;"/>
+			</element-collection>
+			<element-collection name="delimMap">
+				<map-key-column name="&quot;xml map key&quot;" column-definition="VARCHAR(20)"
+					table="&quot;xml map key table&quot;"/>
+			</element-collection>
+		</attributes>
+	</entity>
+
+</entity-mappings>
\ No newline at end of file

Propchange: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/delimited-identifiers-xml-orm.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Modified: openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/persistence.xml
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/persistence.xml?rev=899784&r1=899783&r2=899784&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/persistence.xml (original)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/resources/META-INF/persistence.xml Fri Jan 15 19:38:18 2010
@@ -53,6 +53,7 @@
         <mapping-file>org/apache/openjpa/persistence/detach/detach-orm.xml</mapping-file>
         <mapping-file>org/apache/openjpa/persistence/enhance/identity/mapsId-orm.xml</mapping-file>
         <mapping-file>org/apache/openjpa/persistence/entity/orm.xml</mapping-file>
+        
         <properties>
             <property name="openjpa.jdbc.SynchronizeMappings"
                 value="buildSchema(ForeignKeys=true)"/>
@@ -276,5 +277,44 @@
                 value="buildSchema"/>
         </properties>
     </persistence-unit>
+    
+    <persistence-unit name="delimited-identifiers-xml">
+    	<mapping-file>META-INF/delimited-identifiers-xml-orm.xml</mapping-file>
+    	<properties>
+            <property name="openjpa.jdbc.SynchronizeMappings"
+                  value="buildSchema"/>
+        </properties>
+	</persistence-unit>
+	
+	<persistence-unit name="delimited-identifiers-seq-gen-xml">
+    	<mapping-file>META-INF/delimited-identifiers-seq-gen-xml-orm.xml</mapping-file>
+    	<properties>
+            <property name="openjpa.jdbc.SynchronizeMappings"
+                  value="buildSchema"/>
+        </properties>
+	</persistence-unit>
+	
+	<persistence-unit name="delimited-identifiers-inheritance-xml">
+    	<mapping-file>META-INF/delimited-identifiers-inheritance-xml-orm.xml</mapping-file>
+    	<properties>
+            <property name="openjpa.jdbc.SynchronizeMappings"
+                  value="buildSchema"/>
+        </properties>
+	</persistence-unit>
+	
+	<persistence-unit name="delimited-identifiers-joins-xml">
+    	<mapping-file>META-INF/delimited-identifiers-joins-orm.xml</mapping-file>
+    	<properties>
+            <property name="openjpa.jdbc.SynchronizeMappings"
+                  value="buildSchema"/>
+        </properties>
+	</persistence-unit>
+	
+	<persistence-unit name="delimited-identifiers-result-set-xml">
+    	<mapping-file>META-INF/delimited-identifiers-result-set-orm.xml</mapping-file>
+    	<properties>
+            <property name="openjpa.jdbc.SynchronizeMappings"
+                  value="buildSchema"/>
+        </properties>
+	</persistence-unit>
 </persistence>
-

Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.java?rev=899784&r1=899783&r2=899784&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.java (original)
+++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/AnnotationPersistenceMetaDataParser.java Fri Jan 15 19:38:18 2010
@@ -142,12 +142,6 @@
     private static final Map<Class<?>, MetaDataTag> _tags =
         new HashMap<Class<?>, MetaDataTag>();
 
-    // The following is needed for input into the delimitString() method
-    protected static enum DBIdentifiers {
-        SEQUENCE_GEN_SEQ_NAME,
-        SEQUENCE_GEN_SCHEMA
-    }
-
     static {
         _tags.put(Access.class, ACCESS);
         _tags.put(Cacheable.class, CACHEABLE);
@@ -1706,11 +1700,15 @@
 
         // create new sequence
         meta = getRepository().addSequenceMetaData(name);
-        String seq = delimitString(gen.sequenceName(), DBIdentifiers.SEQUENCE_GEN_SEQ_NAME);
+        String seq = gen.sequenceName();
+        // Do not normalize the sequence name if it appears to be a plugin 
+        if (seq.indexOf('(') == -1){
+            seq = normalizeSequenceName(seq);
+        }
         int initial = gen.initialValue();
         int allocate = gen.allocationSize();
-        String schema = delimitString(gen.schema(), DBIdentifiers.SEQUENCE_GEN_SCHEMA);
-        String catalog = gen.catalog();
+        String schema = normalizeSchemaName(gen.schema());
+        String catalog = normalizeCatalogName(gen.catalog());
         // don't allow initial of 0 b/c looks like def value
         if (initial == 0)
             initial = 1;
@@ -1898,8 +1896,16 @@
 		}
 	}
 
-    protected String delimitString(String name, DBIdentifiers type) {
-        return name;
+    protected String normalizeSequenceName(String seqName) {
+        return seqName;
+    }
+
+    protected String normalizeSchemaName(String schName) {
+        return schName;
+    }
+
+    protected String normalizeCatalogName(String catName) {
+        return catName;
     }
 }
 

Modified: openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java?rev=899784&r1=899783&r2=899784&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java (original)
+++ openjpa/trunk/openjpa-persistence/src/main/java/org/apache/openjpa/persistence/XMLPersistenceMetaDataParser.java Fri Jan 15 19:38:18 2010
@@ -67,6 +67,7 @@
 import org.apache.openjpa.meta.QueryMetaData;
 import org.apache.openjpa.meta.SequenceMetaData;
 import org.apache.openjpa.meta.ValueMetaData;
+
 import static org.apache.openjpa.persistence.MetaDataTag.*;
 import static org.apache.openjpa.persistence.PersistenceStrategy.*;
 import org.apache.openjpa.util.ImplHelper;
@@ -107,6 +108,12 @@
     protected static final String ELEM_PU_DEF = "persistence-unit-defaults";
     protected static final String ELEM_XML_MAP_META_COMPLETE = "xml-mapping-metadata-complete";
     protected static final String ELEM_DELIM_IDS = "delimited-identifiers";
+    
+    // The following is needed for input into the delimitString() method
+    protected static enum localDBIdentifiers {
+        SEQUENCE_GEN_SEQ_NAME,
+        SEQUENCE_GEN_SCHEMA
+    }    
 
     private static final Map<String, Object> _elems =
         new HashMap<String, Object>();
@@ -1008,12 +1015,16 @@
 
         meta = getRepository().addSequenceMetaData(name);
         String seq = attrs.getValue("sequence-name");
+        // Do not normalize the sequence name if it appears to be a plugin 
+        if (seq.indexOf('(') == -1){
+            seq = normalizeSequenceName(seq);
+        }
         String val = attrs.getValue("initial-value");
         int initial = val == null ? 1 : Integer.parseInt(val);
         val = attrs.getValue("allocation-size");
         int allocate = val == null ? 50 : Integer.parseInt(val);
-        String schema = attrs.getValue("schema");
-        String catalog = attrs.getValue("catalog");
+        String schema = normalizeSchemaName(attrs.getValue("schema"));
+        String catalog = normalizeCatalogName(attrs.getValue("catalog"));
 
         String clsName, props;
         if (seq == null || seq.indexOf('(') == -1) {
@@ -2109,4 +2120,16 @@
     protected boolean startDelimitedIdentifiers() {
         return false;
     }
+    
+    protected String normalizeSequenceName(String seqName) {
+        return seqName;
+    }
+
+    protected String normalizeSchemaName(String schName) {
+        return schName;
+    }
+
+    protected String normalizeCatalogName(String catName) {
+        return catName;
+    }
 }



Mime
View raw message