[Carbon-commits] [Carbon] svn commit r113617 - in trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core: . src/test/java/org/wso2/carbon/dataservices/core/test/sql src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle src/test/java/org/wso2/carbon/dataservices/core/test/util src/test/resources/lib src/test/resources/sql src/test/resources/test-dbs src/test/resources/xsd
anjana at wso2.com
anjana at wso2.com
Fri Oct 7 10:34:46 EDT 2011
Author: anjana
Date: Fri Oct 7 07:34:46 2011
New Revision: 113617
URL: http://wso2.org/svn/browse/wso2?view=rev&revision=113617
Log:
Adding Oracle Test Suite by Lakmali
Added:
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleAdvancedStoredProcServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBasicTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBinaryDataServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleDMLServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleFinalizeTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInitTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInputMappingServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleNestedQueryTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleStoredProcedureServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleTestSuite.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/lib/
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/lib/ojdbc6.jar (contents, props changed)
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTables.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTestDB.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/DropOracleUser.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredFuncs.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredProcs.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleAdvancedStoredProcService.dbs
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBasicService.dbs
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBinaryDataService.dbs
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleDMLService.dbs
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleInputMappingService.dbs
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleNestedQueryStoredProcService.dbs
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested_with_date_time.xsd
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders_with_date_time.xsd
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payment_info_nested_with_date_time.xsd
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payments_with_date_time.xsd
Modified:
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/pom.xml
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractBasicServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractInputMappingServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractNestedQueryServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractStoredProcedureServiceTest.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/util/TestUtils.java
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Customers.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Products.sql
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested.xsd
trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders.xsd
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/pom.xml
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/pom.xml?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/pom.xml (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/pom.xml Fri Oct 7 07:34:46 2011
@@ -146,10 +146,17 @@
<version>${bsh.wso2.version.data-services}</version>
</dependency>
<dependency>
- <groupId>org.htmlcleaner.wso2</groupId>
- <artifactId>htmlcleaner</artifactId>
- <version>${htmlcleaner.version.data-services}</version>
- </dependency>
+ <groupId>org.htmlcleaner.wso2</groupId>
+ <artifactId>htmlcleaner</artifactId>
+ <version>${htmlcleaner.version.data-services}</version>
+ </dependency>
+ <dependency>
+ <groupId>ojdbc</groupId>
+ <artifactId>ojdbc6</artifactId>
+ <scope>system</scope>
+ <version>6</version>
+ <systemPath>${basedir}/src/test/resources/lib/ojdbc6.jar</systemPath>
+ </dependency>
</dependencies>
<build>
@@ -172,6 +179,7 @@
</includes>
<excludes>
<exclude>**/MySQLTestSuite.java</exclude>
+ <exclude>**/OracleTestSuite.java</exclude>
</excludes>
</configuration>
</plugin>
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractBasicServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractBasicServiceTest.java?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractBasicServiceTest.java (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractBasicServiceTest.java Fri Oct 7 07:34:46 2011
@@ -101,6 +101,21 @@
fail(e.getMessage());
}
}
+
+ /**
+ * Test with a simple select statement with attributes and DateTime field
+ */
+ protected void basicSelectWithAttributesForDateTime(){
+ TestUtils.showMessage(this.epr + " -basicSelectWithAttributesForDateTime");
+ try{
+ OMElement result = TestUtils.callOperation(this.epr, "select_attributes_for_date_time_op", null);
+ assertTrue(TestUtils.validateResultStructure(result, TestUtils.PAYMENTS_WITH_DATETIME_XSD_PATH));
+
+ }catch(Exception e){
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
/**
* Test to merge data from several call-query statements in an operation
@@ -120,6 +135,7 @@
}
assertTrue(c == 5);
} catch (Exception e) {
+ System.out.println("got a exception");
e.printStackTrace();
fail(e.getMessage());
}
@@ -155,6 +171,7 @@
TestUtils.DEFAULT_DS_WS_NAMESPACE);
assertTrue(Integer.parseInt(val) > 0);
} catch (Exception e) {
+
e.printStackTrace();
fail(e.getMessage());
}
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractInputMappingServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractInputMappingServiceTest.java?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractInputMappingServiceTest.java (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractInputMappingServiceTest.java Fri Oct 7 07:34:46 2011
@@ -28,7 +28,8 @@
/**
* Class to represent input mappings test cases.
*/
-public abstract class AbstractInputMappingServiceTest extends DataServiceBaseTestCase {
+public abstract class AbstractInputMappingServiceTest extends
+ DataServiceBaseTestCase {
private String epr = null;
@@ -36,7 +37,7 @@
super(testName);
this.epr = this.baseEpr + serviceName;
}
-
+
/**
* Test with simple input mappings - 1.
*/
@@ -59,7 +60,31 @@
fail(e.getMessage());
}
}
-
+
+ /**
+ * Test with simple input mapping - 1 - For DateTime
+ */
+ protected void inputMappings1ForDateTime() {
+ TestUtils.showMessage(this.epr + " - inputMappings1ForDateTime");
+ Map<String, String> params = new HashMap<String, String>();
+ params.put("orderNumber", "10242");
+ params.put("orderDate", "2004-04-20");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "select_input_mappings_for_date_time_op1", params);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.ORDERS_WITH_DATETIME_PATH));
+ String val = TestUtils.getFirstValue(result,
+ "/Orders/Order/orderNumber",
+ TestUtils.DEFAULT_DS_WS_NAMESPACE);
+ assertTrue(params.get("orderNumber").equals(val));
+
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
/**
* Test with simple input mappings - 2.
*/
@@ -74,10 +99,10 @@
"select_input_mappings_op2", params);
assertTrue(TestUtils.validateResultStructure(result,
TestUtils.PAYMENTS_XSD_PATH));
- //TODO: check attribute value
-// String val1 = TestUtils.getFirstValue(result,
-// "/Payments/Payment at customerNumber",
-// TestUtils.DEFAULT_DS_WS_NAMESPACE);
+ // TODO: check attribute value
+ // String val1 = TestUtils.getFirstValue(result,
+ // "/Payments/Payment at customerNumber",
+ // TestUtils.DEFAULT_DS_WS_NAMESPACE);
String val2 = TestUtils.getFirstValue(result,
"/Payments/Payment/checkNumber",
TestUtils.DEFAULT_DS_WS_NAMESPACE);
@@ -89,6 +114,34 @@
}
/**
+ * Test with simple input mappings - 2 - For DateTime
+ */
+ protected void inputMappings2ForDateTime(){
+ TestUtils.showMessage(this.epr + " - inputMappings2ForDateTime");
+ Map<String, String> params = new HashMap<String, String>();
+ params.put("customerNumber", "141");
+ params.put("checkNumber", "HJ32686");
+ params.put("amount", "59830.55");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "select_input_mappings_for_date_time_op2", params);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.PAYMENTS_WITH_DATETIME_XSD_PATH));
+ // TODO: check attribute value
+ // String val1 = TestUtils.getFirstValue(result,
+ // "/Payments/Payment at customerNumber",
+ // TestUtils.DEFAULT_DS_WS_NAMESPACE);
+ String val2 = TestUtils.getFirstValue(result,
+ "/Payments/Payment/checkNumber",
+ TestUtils.DEFAULT_DS_WS_NAMESPACE);
+ assertTrue(params.get("checkNumber").equals(val2));
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
+ /**
* Test call-query merge with input mappings.
*/
@SuppressWarnings("unchecked")
@@ -102,7 +155,8 @@
"select_input_mappings_merge_op", params);
assertTrue(TestUtils.validateResultStructure(result,
TestUtils.PAYMENTS_XSD_PATH));
- Iterator<OMElement> elItr = result.getChildrenWithName(new QName("Payment"));
+ Iterator<OMElement> elItr = result.getChildrenWithName(new QName(
+ "Payment"));
int c = 0;
while (elItr.hasNext()) {
assertNotNull(elItr.next());
@@ -115,22 +169,66 @@
}
}
- /**
- * Test with simple input mappings with default values
- */
-
- protected void inputMappingsWithDefValue() {
- TestUtils.showMessage(this.epr + " - inputMappingsWithDefValue");
- Map<String, String> params = new HashMap<String, String>();
- try {
- OMElement result = TestUtils.callOperation(this.epr,
+ /**
+ * Test call-query merge with input mappings - For DateTime
+ */
+ @SuppressWarnings("unchecked")
+ protected void inputMappingsCallQueryMergeForDateTime(){
+ TestUtils.showMessage(this.epr + " - inputMappingsCallQueryMergeForDateTime");
+ Map<String, String> params = new HashMap<String, String>();
+ params.put("customerNumber", "103");
+ params.put("paymentDate", "2004-12-18");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "select_input_mappings_merge_for_date_time_op", params);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.PAYMENTS_WITH_DATETIME_XSD_PATH));
+ Iterator<OMElement> elItr = result.getChildrenWithName(new QName("Payment"));
+ int c = 0;
+ while (elItr.hasNext()) {
+ assertNotNull(elItr.next());
+ c++;
+ }
+ assertTrue(c == 3);
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
+ /**
+ * Test with simple input mappings with default values
+ */
+
+ protected void inputMappingsWithDefValue() {
+ TestUtils.showMessage(this.epr + " - inputMappingsWithDefValue");
+ Map<String, String> params = new HashMap<String, String>();
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
"results_with_default_values_op", params);
assertTrue(TestUtils.validateResultStructure(result,
TestUtils.PAYMENTS_XSD_PATH));
- } catch (Exception e) {
+ } catch (Exception e) {
e.printStackTrace();
fail(e.getMessage());
}
- }
+ }
+ /**
+ * Test with simple input mappings with default values - For DateTime
+ */
+ protected void inputMappingsWithDefValueForDateTime(){
+ TestUtils.showMessage(this.epr + " - inputMappingsWithDefValueForDateTime");
+ Map<String, String> params = new HashMap<String, String>();
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "results_with_default_values_for_date_time_op", params);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.PAYMENTS_WITH_DATETIME_XSD_PATH));
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
}
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractNestedQueryServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractNestedQueryServiceTest.java?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractNestedQueryServiceTest.java (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractNestedQueryServiceTest.java Fri Oct 7 07:34:46 2011
@@ -57,5 +57,21 @@
fail(e.getMessage());
}
}
+
+ /*
+ * Test nested query with DateTime
+ */
+ protected void nestedQuery2ForDateTime(){
+ TestUtils.showMessage(this.epr + " - nestedQuery2ForDateTime");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "order_details_for_date_time_op", null);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.ORDER_DETAILS_NESTED_WITH_DATETIME_XSD_PATH));
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
}
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractStoredProcedureServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractStoredProcedureServiceTest.java?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractStoredProcedureServiceTest.java (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/AbstractStoredProcedureServiceTest.java Fri Oct 7 07:34:46 2011
@@ -92,6 +92,22 @@
}
/**
+ * Test with a nested stored procedure call - 1 - For DateTime
+ */
+ protected void storedProcNested1ForDateTime(){
+ TestUtils.showMessage(this.epr + " - storedProcNested1ForDateTime");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "stored_procedure_nested_for_date_time_op1", null);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.PAYMENT_INFO_NESTED_WITH_DATE_TIME_XSD_PATH));
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
+ /**
* Test with a nested stored procedure call - 2.
*/
protected void storedProcNested2() {
@@ -108,6 +124,22 @@
}
/**
+ * Test with a nested stored procedure call -2 - For DateTime
+ */
+ protected void storedProcNested2ForDateTime(){
+ TestUtils.showMessage(this.epr + " - storedProcNested2ForDateTime");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "stored_procedure_nested_for_date_time_op2", null);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.PAYMENT_INFO_NESTED_WITH_DATE_TIME_XSD_PATH));
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
+ /**
* Test with a nested stored procedure call - 3.
*/
protected void storedProcNested3() {
@@ -124,6 +156,22 @@
}
/**
+ * Test with a nested stored procedure call -3 - For DateTime
+ */
+ protected void storedProcNested3ForDateTime(){
+ TestUtils.showMessage(this.epr + " - storedProcNested3ForDateTime");
+ try {
+ OMElement result = TestUtils.callOperation(this.epr,
+ "stored_procedure_nested_for_date_time_op3", null);
+ assertTrue(TestUtils.validateResultStructure(result,
+ TestUtils.PAYMENT_INFO_NESTED_WITH_DATE_TIME_XSD_PATH));
+ } catch (Exception e) {
+ e.printStackTrace();
+ fail(e.getMessage());
+ }
+ }
+
+ /**
* Test with a stored function call with no params.
*/
protected void storedFuncNoParams() {
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleAdvancedStoredProcServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleAdvancedStoredProcServiceTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleAdvancedStoredProcServiceTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,23 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractAdvancedStoredProcServiceTest;
+
+public class OracleAdvancedStoredProcServiceTest extends AbstractAdvancedStoredProcServiceTest {
+
+ public OracleAdvancedStoredProcServiceTest(String testName) {
+ super(testName, "OracleAdvancedStoredProcService");
+ }
+
+ public void testStoredProcWithOutParams() {
+ this.storedProcWithOutParams();
+ }
+
+ public void testStoredProcWithOutParamsAndRS() {
+ this.storedProcWithOutParamsAndRS();
+ }
+
+ public void testStoredProcWithInOutParamsAndRS() {
+ this.storedProcWithInOutParamsAndRS();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBasicTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBasicTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBasicTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,35 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractBasicServiceTest;
+
+public class OracleBasicTest extends AbstractBasicServiceTest {
+
+ public OracleBasicTest(String testName) {
+ super(testName, "OracleBasicService");
+ }
+
+ public void testOracleBasicSelectWithFields() {
+ this.basicSelectWithFields();
+ }
+
+ public void testOracleBasicSelectAll() {
+ this.basicSelectAll();
+ }
+
+ public void testOracleBasicSelectCount() {
+ this.basicSelectCount();
+ }
+
+ public void testOracleBasicSelectWithAttributesForDateTime() {
+ this.basicSelectWithAttributesForDateTime();
+ }
+
+ public void testOracleBasicCallQueryMerge() {
+ this.basicCallQueryMerge();
+ }
+
+ public void testOracleBasicArrayInputTypes() {
+ this.basicArrayInputTypes();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBinaryDataServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBinaryDataServiceTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleBinaryDataServiceTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,15 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractBinaryDataServiceTest;
+
+public class OracleBinaryDataServiceTest extends AbstractBinaryDataServiceTest {
+
+ public OracleBinaryDataServiceTest(String testName) {
+ super(testName, "OracleBinaryDataService");
+ }
+
+ public void testMySQLBinaryDataStoreRetrieve() {
+ this.binaryDataStoreRetrieve();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleDMLServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleDMLServiceTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleDMLServiceTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,47 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractDMLServiceTest;
+
+public class OracleDMLServiceTest extends AbstractDMLServiceTest {
+
+ public OracleDMLServiceTest(String testName) {
+ super(testName, "OracleDMLService");
+ }
+
+ public void testOracleDMLOperations() {
+ this.doDMLOperations();
+ }
+
+ public void testOracleDMLOperationsWithNoResultNestedQuery() {
+ this.doDMLOperationsWithNoResultNestedQuery();
+ }
+
+ public void testOracleDMLOperationsWithNoResultStoredProcNestedQuery() {
+ this.doDMLOperationsWithNoResultStoredProcNestedQuery();
+ }
+
+ public void testOracleDMLOperationsVal1() {
+ this.doDMLOperationsVal1();
+ }
+
+ public void testOracleDMLOperationsVal2() {
+ this.doDMLOperationsVal2();
+ }
+
+ public void testOracleDMLOperationsVal3() {
+ this.doDMLOperationsVal3();
+ }
+
+ public void testOracleDMLOperationsVal4() {
+ this.doDMLOperationsVal4();
+ }
+
+ public void testOracleDMLOperationsVal5() {
+ this.doDMLOperationsVal5();
+ }
+
+ public void testOracleDMLOperationsVal6() {
+ this.doDMLOperationsVal6();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleFinalizeTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleFinalizeTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleFinalizeTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,16 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.DataServiceBaseTestCase;
+import org.wso2.carbon.dataservices.core.test.util.UtilServer;
+
+public class OracleFinalizeTest extends DataServiceBaseTestCase {
+
+ public OracleFinalizeTest() {
+ super("OracleFinalizeTest");
+ }
+
+ public void testMySQLStop() throws Exception {
+ UtilServer.stop();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInitTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInitTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInitTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,17 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.DataServiceBaseTestCase;
+import org.wso2.carbon.dataservices.core.test.util.UtilServer;
+
+public class OracleInitTest extends DataServiceBaseTestCase{
+
+ public OracleInitTest() {
+ super("OracleInitTest");
+ System.setProperty("user.timezone", "CDT");
+ }
+
+ public void testOracleStartup() throws Exception {
+ UtilServer.start(repository, axis2Conf);
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInputMappingServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInputMappingServiceTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleInputMappingServiceTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,27 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractInputMappingServiceTest;
+
+public class OracleInputMappingServiceTest extends AbstractInputMappingServiceTest {
+
+ public OracleInputMappingServiceTest(String testName) {
+ super(testName, "OracleInputMappingService");
+ }
+
+ public void testOracleInputMappings1ForDateTime() {
+ this.inputMappings1ForDateTime();
+ }
+
+ public void testOracleInputMappings2ForDateTime() {
+ this.inputMappings2ForDateTime();
+ }
+
+ public void testOracleInputMappingsCallQueryMergeForDateTime() {
+ this.inputMappingsCallQueryMergeForDateTime();
+ }
+
+ public void testInputMappingsWithDefValueForDateTime() {
+ this.inputMappingsWithDefValueForDateTime();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleNestedQueryTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleNestedQueryTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleNestedQueryTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,15 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractNestedQueryServiceTest;
+
+public class OracleNestedQueryTest extends AbstractNestedQueryServiceTest {
+
+ public OracleNestedQueryTest(String testName) {
+ super(testName, "OracleNestedQueryStoredProcService");
+ }
+
+ public void testOracleNestedQuery2ForDateTime() {
+ this.nestedQuery2ForDateTime();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleStoredProcedureServiceTest.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleStoredProcedureServiceTest.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleStoredProcedureServiceTest.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,39 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import org.wso2.carbon.dataservices.core.test.sql.AbstractStoredProcedureServiceTest;
+
+public class OracleStoredProcedureServiceTest extends AbstractStoredProcedureServiceTest{
+
+ public OracleStoredProcedureServiceTest(String testName) {
+ super(testName, "OracleNestedQueryStoredProcService");
+ }
+
+ public void testOracleStoredProcNoParams() {
+ this.storedProcNoParams();
+ }
+
+ public void testOracleStoredProcWithParams() {
+ this.storedProcWithParams();
+ }
+
+ public void testStoredProcNested1ForDateTime() {
+ this.storedProcNested1ForDateTime();
+ }
+
+ public void testStoredProcNested2ForDateTime() {
+ this.storedProcNested2ForDateTime();
+ }
+
+ public void testStoredProcNested3ForDateTime() {
+ this.storedProcNested3ForDateTime();
+ }
+
+ public void testOracleStoredFuncNoParams() {
+ this.storedFuncNoParams();
+ }
+
+ public void testOracleStoredFuncWithParams() {
+ this.storedFuncWithParams();
+ }
+
+}
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleTestSuite.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleTestSuite.java?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/sql/oracle/OracleTestSuite.java Fri Oct 7 07:34:46 2011
@@ -0,0 +1,25 @@
+package org.wso2.carbon.dataservices.core.test.sql.oracle;
+
+import junit.framework.Test;
+import junit.framework.TestCase;
+import junit.framework.TestSuite;
+
+public class OracleTestSuite extends TestCase {
+
+ public static Test suite() {
+ TestSuite suite = new TestSuite(
+ "Test for org.wso2.carbon.dataservices.core.test.sql.oracle");
+ suite.addTestSuite(OracleInitTest.class);
+ suite.addTestSuite(OracleBasicTest.class);
+ suite.addTestSuite(OracleDMLServiceTest.class);
+ suite.addTestSuite(OracleInputMappingServiceTest.class);
+ suite.addTestSuite(OracleNestedQueryTest.class);
+ suite.addTestSuite(OracleAdvancedStoredProcServiceTest.class);
+ suite.addTestSuite(OracleBinaryDataServiceTest.class);
+ suite.addTestSuite(OracleStoredProcedureServiceTest.class);
+ suite.addTestSuite(OracleFinalizeTest.class);
+
+ return suite;
+ }
+
+}
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/util/TestUtils.java
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/util/TestUtils.java?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/util/TestUtils.java (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/java/org/wso2/carbon/dataservices/core/test/util/TestUtils.java Fri Oct 7 07:34:46 2011
@@ -55,12 +55,20 @@
public static final String PAYMENTS_XSD_PATH = "./src/test/resources/xsd/payments.xsd";
+ public static final String PAYMENTS_WITH_DATETIME_XSD_PATH = "./src/test/resources/xsd/payments_with_date_time.xsd";
+
public static final String ORDERS_XSD_PATH = "./src/test/resources/xsd/orders.xsd";
+ public static final String ORDERS_WITH_DATETIME_PATH = "./src/test/resources/xsd/orders_with_date_time.xsd";
+
public static final String PAYMENT_INFO_NESTED_XSD_PATH = "./src/test/resources/xsd/payment_info_nested.xsd";
+ public static final String PAYMENT_INFO_NESTED_WITH_DATE_TIME_XSD_PATH = "./src/test/resources/xsd/payment_info_nested_with_date_time.xsd";
+
public static final String ORDER_DETAILS_NESTED_XSD_PATH = "./src/test/resources/xsd/order_details_nested.xsd";
+ public static final String ORDER_DETAILS_NESTED_WITH_DATETIME_XSD_PATH = "./src/test/resources/xsd/order_details_nested_with_date_time.xsd";
+
public static final String OFFICES_XSD_PATH = "./src/test/resources/xsd/offices.xsd";
/**
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/lib/ojdbc6.jar
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/lib/ojdbc6.jar?pathrev=113617
==============================================================================
Binary file. No diff available.
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTables.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTables.sql?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTables.sql Fri Oct 7 07:34:46 2011
@@ -0,0 +1,110 @@
+CREATE TABLE Customers(
+ customerNumber NUMBER,
+ customerName VARCHAR2(50),
+ contactLastName VARCHAR2(50),
+ contactFirstName VARCHAR2(50),
+ phone VARCHAR2(50),
+ addressLine1 VARCHAR2(50),
+ addressLine2 VARCHAR2(50),
+ city VARCHAR2(50),
+ state VARCHAR2(50),
+ postalCode VARCHAR2(15),
+ country VARCHAR2(50),
+ salesRepEmployeeNumber NUMBER,
+ creditLimit BINARY_DOUBLE
+);
+
+ALTER TABLE Customers ADD CONSTRAINT customers_pk PRIMARY KEY (customerNumber);
+
+CREATE TABLE Employees(
+ employeeNumber NUMBER,
+ lastName VARCHAR2(50),
+ firstName VARCHAR2(50),
+ extension VARCHAR2(10),
+ email VARCHAR2(100),
+ officeCode VARCHAR2(10),
+ reportsTo NUMBER,
+ jobTitle VARCHAR2(50)
+);
+
+ALTER TABLE Employees ADD CONSTRAINT employees_pk PRIMARY KEY (employeeNumber );
+
+CREATE TABLE Offices(
+ officeCode VARCHAR2(10),
+ city VARCHAR2(50),
+ phone VARCHAR2(50),
+ addressLine1 VARCHAR2(50),
+ addressLine2 VARCHAR2(50),
+ state VARCHAR2(50),
+ country VARCHAR2(50),
+ postalCode VARCHAR2(15),
+ territory VARCHAR2(10)
+);
+
+ALTER TABLE Offices ADD CONSTRAINT offices_pk PRIMARY KEY (officeCode );
+
+CREATE TABLE Products(
+ productCode VARCHAR2(15),
+ productName VARCHAR2(70),
+ productLine VARCHAR2(50),
+ productScale VARCHAR2(10),
+ productVendor VARCHAR2(50),
+ productDescription VARCHAR2(4000),
+ quantityInStock NUMBER,
+ buyPrice BINARY_DOUBLE,
+ MSRP BINARY_DOUBLE
+);
+
+ALTER TABLE Products ADD CONSTRAINT products_pk PRIMARY KEY (productCode );
+
+CREATE TABLE ProductLines(
+ productLine VARCHAR2(50),
+ textDescription VARCHAR2(4000),
+ htmlDescription VARCHAR2(4000),
+ image BLOB
+);
+
+ALTER TABLE ProductLines ADD CONSTRAINT productLines_pk PRIMARY KEY (productLine );
+
+CREATE TABLE Orders(
+ orderNumber NUMBER,
+ orderDate DATE,
+ requiredDate DATE,
+ shippedDate DATE,
+ status VARCHAR2(15),
+ comments VARCHAR2(4000),
+ customerNumber NUMBER
+);
+
+ALTER TABLE Orders ADD CONSTRAINT orders_pk PRIMARY KEY (orderNumber );
+CREATE INDEX orders_cutomer ON Orders( customerNumber );
+
+CREATE TABLE OrderDetails(
+ orderNumber NUMBER,
+ productCode VARCHAR2(15),
+ quantityOrdered NUMBER,
+ priceEach BINARY_DOUBLE,
+ orderLineNumber NUMBER);
+
+ALTER TABLE OrderDetails ADD CONSTRAINT orderDetails_pk PRIMARY KEY (orderNumber, productCode );
+
+CREATE TABLE Payments(
+ customerNumber NUMBER,
+ checkNumber VARCHAR2(50),
+ paymentDate DATE,
+ amount BINARY_DOUBLE
+);
+
+ALTER TABLE Payments ADD CONSTRAINT payments_pk PRIMARY KEY (customerNumber, checkNumber );
+
+CREATE TABLE department(
+ id NUMBER,
+ name VARCHAR2(200)
+);
+
+CREATE TABLE BinaryData(
+ id NUMBER,
+ data BLOB
+);
+
+
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTestDB.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTestDB.sql?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/CreateOracleTestDB.sql Fri Oct 7 07:34:46 2011
@@ -0,0 +1,31 @@
+START DropOracleUser;
+
+CREATE USER datauser IDENTIFIED BY wso2;
+
+GRANT CONNECT,RESOURCE to datauser with admin option;
+
+CONNECT datauser/wso2;
+alter session set NLS_DATE_FORMAT='YYYY-MM-DD';
+
+SET ESCAPE ON
+SET ESCAPE '#'
+
+
+START CreateOracleTables;
+START Offices;
+START Employees;
+START Customers;
+START Products;
+START Orders;
+START Payments;
+START ProductLines;
+START OrderDetails;
+START OracleStoredProcs;
+START OracleStoredFuncs;
+
+
+
+exit;
+
+
+
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Customers.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Customers.sql?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Customers.sql (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Customers.sql Fri Oct 7 07:34:46 2011
@@ -4,19 +4,19 @@
insert into Customers values (119,'La Rochelle Gifts','Labrune','Janine ','40.67.8555','67, rue des Cinquante Otages',NULL,'Nantes',NULL,'44000','France',1370,118200.0);
insert into Customers values (121,'Baane Mini Imports','Bergulfsen','Jonas ','07-98 9555','Erling Skakkes gate 78',NULL,'Stavern',NULL,'4110','Norway',1504,81700.0);
insert into Customers values (124,'Mini Gifts Distributors Ltd.','Nelson','Susan','4155551450','5677 Strong St.',NULL,'San Rafael','CA','97562','USA',1165,210500.0);
-insert into Customers values (125,'Havel & Zbyszek Co','Piestrzeniewicz','Zbyszek ','(26) 642-7555','ul. Filtrowa 68',NULL,'Warszawa',NULL,'01-012','Poland',NULL,0.0);
+insert into Customers values (125,'Havel / Zbyszek Co','Piestrzeniewicz','Zbyszek ','(26) 642-7555','ul. Filtrowa 68',NULL,'Warszawa',NULL,'01-012','Poland',NULL,0.0);
insert into Customers values (128,'Blauer See Auto, Co.','Keitel','Roland','+49 69 66 90 2555','Lyonerstr. 34',NULL,'Frankfurt',NULL,'60528','Germany',1504,59700.0);
insert into Customers values (129,'Mini Wheels Co.','Murphy','Julie','6505555787','5557 North Pendale Street',NULL,'San Francisco','CA','94217','USA',1165,64600.0);
insert into Customers values (131,'Land of Toys Inc.','Lee','Kwai','2125557818','897 Long Airport Avenue',NULL,'NYC','NY','10022','USA',1323,114900.0);
insert into Customers values (141,'Euro+ Shopping Channel','Freyre','Diego ','(91) 555 94 44','C/ Moralzarzal, 86',NULL,'Madrid',NULL,'28034','Spain',1370,227600.0);
insert into Customers values (144,'Volvo Model Replicas, Co','Berglund','Christina ','0921-12 3555','Berguvsv�gen 8',NULL,'Lule�',NULL,'S-958 22','Sweden',1504,53100.0);
insert into Customers values (145,'Danish Wholesale Imports','Petersen','Jytte ','31 12 3555','Vinb�ltet 34',NULL,'Kobenhavn',NULL,'1734','Denmark',1401,83400.0);
-insert into Customers values (146,'Saveley & Henriot, Co.','Saveley','Mary ','78.32.5555','2, rue du Commerce',NULL,'Lyon',NULL,'69004','France',1337,123900.0);
+insert into Customers values (146,'Saveley / Henriot, Co.','Saveley','Mary ','78.32.5555','2, rue du Commerce',NULL,'Lyon',NULL,'69004','France',1337,123900.0);
insert into Customers values (148,'Dragon Souveniers, Ltd.','Natividad','Eric','+65 221 7555','Bronz Sok.','Bronz Apt. 3/6 Tesvikiye','Singapore',NULL,'079903','Singapore',1621,103800.0);
insert into Customers values (151,'Muscle Machine Inc','Young','Jeff','2125557413','4092 Furth Circle','Suite 400','NYC','NY','10022','USA',1286,138500.0);
insert into Customers values (157,'Diecast Classics Inc.','Leong','Kelvin','2155551555','7586 Pompton St.',NULL,'Allentown','PA','70267','USA',1216,100600.0);
insert into Customers values (161,'Technics Stores Inc.','Hashimoto','Juri','6505556809','9408 Furth Circle',NULL,'Burlingame','CA','94217','USA',1165,84600.0);
-insert into Customers values (166,'Handji Gifts& Co','Victorino','Wendy','+65 224 1555','106 Linden Road Sandown','2nd Floor','Singapore',NULL,'069045','Singapore',1612,97900.0);
+insert into Customers values (166,'Handji Gifts/ Co','Victorino','Wendy','+65 224 1555','106 Linden Road Sandown','2nd Floor','Singapore',NULL,'069045','Singapore',1612,97900.0);
insert into Customers values (167,'Herkku Gifts','Oeztan','Veysel','+47 2267 3215','Brehmen St. 121','PR 334 Sentrum','Bergen',NULL,'N 5804','Norway ',1504,96800.0);
insert into Customers values (168,'American Souvenirs Inc','Franco','Keith','2035557845','149 Spinnaker Dr.','Suite 101','New Haven','CT','97823','USA',1286,0.0);
insert into Customers values (169,'Porto Imports Co.','de Castro','Isabel ','(1) 356-5555','Estrada da sa�de n. 58',NULL,'Lisboa',NULL,'1756','Portugal',NULL,0.0);
@@ -38,7 +38,7 @@
insert into Customers values (209,'Mini Caravy','Citeaux','Fr�d�rique ','88.60.1555','24, place Kl�ber',NULL,'Strasbourg',NULL,'67000','France',1370,53800.0);
insert into Customers values (211,'King Kong Collectables, Co.','Gao','Mike','+852 2251 1555','Bank of China Tower','1 Garden Road','Central Hong Kong',NULL,NULL,'Hong Kong',1621,58600.0);
insert into Customers values (216,'Enaco Distributors','Saavedra','Eduardo ','(93) 203 4555','Rambla de Catalu�a, 23',NULL,'Barcelona',NULL,'08022','Spain',1702,60300.0);
-insert into Customers values (219,'Boards & Toys Co.','Young','Mary','3105552373','4097 Douglas Av.',NULL,'Glendale','CA','92561','USA',1166,11000.0);
+insert into Customers values (219,'Boards / Toys Co.','Young','Mary','3105552373','4097 Douglas Av.',NULL,'Glendale','CA','92561','USA',1166,11000.0);
insert into Customers values (223,'Nat�rlich Autos','Kloss','Horst ','0372-555188','Taucherstra�e 10',NULL,'Cunewalde',NULL,'01307','Germany',NULL,0.0);
insert into Customers values (227,'Heintze Collectables','Ibsen','Palle','86 21 3555','Smagsloget 45',NULL,'�rhus',NULL,'8200','Denmark',1401,120800.0);
insert into Customers values (233,'Qu�bec Home Shopping Network','Fresni�re','Jean ','(514) 555-8054','43 rue St. Laurent',NULL,'Montr�al','Qu�bec','H1J 1C3','Canada',1286,48700.0);
@@ -47,9 +47,9 @@
insert into Customers values (240,'giftsbymail.co.uk','Bennett','Helen ','(198) 555-8888','Garden House','Crowther Way 23','Cowes','Isle of Wight','PO31 7PJ','UK',1501,93900.0);
insert into Customers values (242,'Alpha Cognac','Roulet','Annette ','61.77.6555','1 rue Alsace-Lorraine',NULL,'Toulouse',NULL,'31000','France',1370,61100.0);
insert into Customers values (247,'Messner Shopping Network','Messner','Renate ','069-0555984','Magazinweg 7',NULL,'Frankfurt',NULL,'60528','Germany',NULL,0.0);
-insert into Customers values (249,'Amica Models & Co.','Accorti','Paolo ','011-4988555','Via Monte Bianco 34',NULL,'Torino',NULL,'10100','Italy',1401,113000.0);
+insert into Customers values (249,'Amica Models / Co.','Accorti','Paolo ','011-4988555','Via Monte Bianco 34',NULL,'Torino',NULL,'10100','Italy',1401,113000.0);
insert into Customers values (250,'Lyon Souveniers','Da Silva','Daniel','+33 1 46 62 7555','27 rue du Colonel Pierre Avia',NULL,'Paris',NULL,'75508','France',1337,68100.0);
-insert into Customers values (256,'Auto Associ�s & Cie.','Tonini','Daniel ','30.59.8555','67, avenue de l''Europe',NULL,'Versailles',NULL,'78000','France',1370,77900.0);
+insert into Customers values (256,'Auto Associ�s / Cie.','Tonini','Daniel ','30.59.8555','67, avenue de l''Europe',NULL,'Versailles',NULL,'78000','France',1370,77900.0);
insert into Customers values (259,'Toms Spezialit�ten, Ltd','Pfalzheim','Henriette ','0221-5554327','Mehrheimerstr. 369',NULL,'K�ln',NULL,'50739','Germany',1504,120400.0);
insert into Customers values (260,'Royal Canadian Collectables, Ltd.','Lincoln','Elizabeth ','(604) 555-4555','23 Tsawassen Blvd.',NULL,'Tsawassen','BC','T2F 8M4','Canada',1323,89600.0);
insert into Customers values (273,'Franken Gifts, Co','Franken','Peter ','089-0877555','Berliner Platz 43',NULL,'M�nchen',NULL,'80805','Germany',NULL,0.0);
@@ -57,7 +57,7 @@
insert into Customers values (278,'Rovelli Gifts','Rovelli','Giovanni ','035-640555','Via Ludovico il Moro 22',NULL,'Bergamo',NULL,'24100','Italy',1401,119600.0);
insert into Customers values (282,'Souveniers And Things Co.','Huxley','Adrian','+61 2 9495 8555','Monitor Money Building','815 Pacific Hwy','Chatswood','NSW','2067','Australia',1611,93300.0);
insert into Customers values (286,'Marta''s Replicas Co.','Hernandez','Marta','6175558555','39323 Spinnaker Dr.',NULL,'Cambridge','MA','51247','USA',1216,123700.0);
-insert into Customers values (293,'BG&E Collectables','Harrison','Ed','+41 26 425 50 01','Rte des Arsenaux 41 ',NULL,'Fribourg',NULL,'1700','Switzerland',NULL,0.0);
+insert into Customers values (293,'BG/E Collectables','Harrison','Ed','+41 26 425 50 01','Rte des Arsenaux 41 ',NULL,'Fribourg',NULL,'1700','Switzerland',NULL,0.0);
insert into Customers values (298,'Vida Sport, Ltd','Holz','Mihael','0897-034555','Grenzacherweg 237',NULL,'Gen�ve',NULL,'1203','Switzerland',1702,141300.0);
insert into Customers values (299,'Norway Gifts By Mail, Co.','Klaeboe','Jan','+47 2212 1555','Drammensveien 126A','PB 211 Sentrum','Oslo',NULL,'N 0106','Norway ',1504,95100.0);
insert into Customers values (303,'Schuyler Imports','Schuyler','Bradley','+31 20 491 9555','Kingsfordweg 151',NULL,'Amsterdam',NULL,'1043 GR','Netherlands',NULL,0.0);
@@ -89,7 +89,7 @@
insert into Customers values (379,'Collectables For Less Inc.','Nelson','Allen','6175558555','7825 Douglas Av.',NULL,'Brickhaven','MA','58339','USA',1188,70700.0);
insert into Customers values (381,'Royale Belge','Cartrain','Pascale ','(071) 23 67 2555','Boulevard Tirou, 255',NULL,'Charleroi',NULL,'B-6000','Belgium',1401,23500.0);
insert into Customers values (382,'Salzburg Collectables','Pipps','Georg ','6562-9555','Geislweg 14',NULL,'Salzburg',NULL,'5020','Austria',1401,71700.0);
-insert into Customers values (385,'Cruz & Sons Co.','Cruz','Arnold','+63 2 555 3587','15 McCallum Street','NatWest Center #13-03','Makati City',NULL,'1227 MM','Philippines',1621,81500.0);
+insert into Customers values (385,'Cruz / Sons Co.','Cruz','Arnold','+63 2 555 3587','15 McCallum Street','NatWest Center #13-03','Makati City',NULL,'1227 MM','Philippines',1621,81500.0);
insert into Customers values (386,'L''ordine Souveniers','Moroni','Maurizio ','0522-556555','Strada Provinciale 124',NULL,'Reggio Emilia',NULL,'42100','Italy',1401,121400.0);
insert into Customers values (398,'Tokyo Collectables, Ltd','Shimamura','Akiko','+81 3 3584 0555','2-2-8 Roppongi',NULL,'Minato-ku','Tokyo','106-0032','Japan',1621,94400.0);
insert into Customers values (406,'Auto Canal+ Petit','Perrier','Dominique','(1) 47.55.6555','25, rue Lauriston',NULL,'Paris',NULL,'75016','France',1337,95000.0);
@@ -111,7 +111,7 @@
insert into Customers values (471,'Australian Collectables, Ltd','Clenahan','Sean','61-9-3844-6555','7 Allen Street',NULL,'Glen Waverly','Victoria','3150','Australia',1611,60300.0);
insert into Customers values (473,'Frau da Collezione','Ricotti','Franco','+39 022515555','20093 Cologno Monzese','Alessandro Volta 16','Milan',NULL,NULL,'Italy',1401,34800.0);
insert into Customers values (475,'West Coast Collectables Co.','Thompson','Steve','3105553722','3675 Furth Circle',NULL,'Burbank','CA','94019','USA',1166,55400.0);
-insert into Customers values (477,'Mit Vergn�gen & Co.','Moos','Hanna ','0621-08555','Forsterstr. 57',NULL,'Mannheim',NULL,'68306','Germany',NULL,0.0);
+insert into Customers values (477,'Mit Vergn�gen / Co.','Moos','Hanna ','0621-08555','Forsterstr. 57',NULL,'Mannheim',NULL,'68306','Germany',NULL,0.0);
insert into Customers values (480,'Kremlin Collectables, Co.','Semenov','Alexander ','+7 812 293 0521','2 Pobedy Square',NULL,'Saint Petersburg',NULL,'196143','Russia',NULL,0.0);
insert into Customers values (481,'Raanan Stores, Inc','Altagar,G M','Raanan','+ 972 9 959 8555','3 Hagalim Blv.',NULL,'Herzlia',NULL,'47625','Israel',NULL,0.0);
insert into Customers values (484,'Iberia Gift Imports, Corp.','Roel','Jos� Pedro ','(95) 555 82 82','C/ Romero, 33',NULL,'Sevilla',NULL,'41101','Spain',1702,65700.0);
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/DropOracleUser.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/DropOracleUser.sql?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/DropOracleUser.sql Fri Oct 7 07:34:46 2011
@@ -0,0 +1,26 @@
+DECLARE
+ u_count number;
+ user_name VARCHAR2 (50);
+
+ BEGIN
+
+ u_count :=0;
+ user_name :='datauser';
+ SELECT COUNT (1) INTO u_count FROM dba_users WHERE username = UPPER (user_name);
+
+ IF u_count != 0
+ THEN
+ EXECUTE IMMEDIATE ('DROP USER '||user_name||' CASCADE');
+ END IF;
+
+ u_count := 0;
+
+ EXCEPTION
+ WHEN OTHERS
+ THEN
+ DBMS_OUTPUT.put_line (SQLERRM);
+ DBMS_OUTPUT.put_line (' ');
+
+ END;
+
+/
\ No newline at end of file
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredFuncs.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredFuncs.sql?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredFuncs.sql Fri Oct 7 07:34:46 2011
@@ -0,0 +1,28 @@
+CREATE OR REPLACE FUNCTION getAverageCreditLimit
+RETURN BINARY_DOUBLE IS
+
+totalCL Customers.creditLimit%TYPE;
+average Customers.creditLimit%TYPE;
+noOfCustomers NUMBER;
+
+BEGIN
+ SELECT SUM(creditLimit) into totalCL from Customers;
+ SELECT COUNT(*) into noOfCustomers from Customers;
+ average := totalCL/noOfCustomers;
+ RETURN average;
+END;
+
+/
+
+CREATE OR REPLACE FUNCTION getCustomerPhoneNumber(custNo NUMBER)
+RETURN varchar2 IS
+
+phoneNo Customers.phone%TYPE;
+
+
+BEGIN
+ SELECT phone into phoneNo from Customers WHERE customerNumber = custNo;
+ RETURN phoneNo;
+END;
+
+/
\ No newline at end of file
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredProcs.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredProcs.sql?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/OracleStoredProcs.sql Fri Oct 7 07:34:46 2011
@@ -0,0 +1,94 @@
+CREATE OR REPLACE PACKAGE Types AS
+ TYPE cursor_type IS REF CURSOR;
+END Types;
+/
+
+-------
+
+CREATE OR REPLACE PROCEDURE getCustomerInfo(p_recordset1 OUT Types.cursor_type) AS
+
+BEGIN
+ OPEN p_recordset1 FOR
+ SELECT customerNumber, customerName, contactLastName, phone, city FROM Customers;
+
+END;
+
+/
+
+-------
+
+CREATE OR REPLACE PROCEDURE getCustomerInfoWithId(custNo IN NUMBER, p_recordset1 OUT Types.cursor_type) AS
+
+BEGIN
+ OPEN p_recordset1 FOR
+ SELECT customerNumber, customerName, contactLastName, phone, city FROM Customers WHERE customerNumber = custNo;
+
+END;
+/
+
+-------
+
+CREATE OR REPLACE PROCEDURE getCustomerInfoWithIdLastName(custNo IN NUMBER, custLastName IN VARCHAR2, p_recordset1 OUT Types.cursor_type) AS
+
+BEGIN
+ OPEN p_recordset1 FOR
+ SELECT customerNumber, customerName, contactLastName, phone, city FROM Customers WHERE customerNumber = custNo and contactLastName = custLastName;
+
+END;
+/
+
+-------
+
+CREATE OR REPLACE PROCEDURE getCustomerCreditLimitWithId(custNo IN NUMBER, p_recordset1 OUT Types.cursor_type) AS
+
+BEGIN
+ OPEN p_recordset1 FOR
+ SELECT * FROM Customers WHERE customerNumber=custNo;
+
+END;
+/
+
+-------
+
+CREATE OR REPLACE PROCEDURE getPaymentInfo (p_recordset1 OUT Types.cursor_type) AS
+
+BEGIN
+ OPEN p_recordset1 FOR
+ SELECT customerNumber, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber is NOT NULL;
+
+END;
+/
+
+-------
+
+CREATE OR REPLACE PROCEDURE get103CustomerLim(custNo OUT NUMBER, custName OUT VARCHAR2) AS
+
+BEGIN
+ custNo :=103;
+ SELECT customerName INTO custName FROM Customers WHERE customerNumber=custNo;
+
+END;
+/
+
+------
+
+CREATE OR REPLACE PROCEDURE get103CustomerFull(custNo OUT NUMBER, custName OUT VARCHAR2,contactLastName OUT VARCHAR2,phone OUT VARCHAR2, city OUT VARCHAR2) AS
+
+BEGIN
+ custNo :=103;
+ SELECT customerName, contactLastName, phone, city INTO custName, contactLastName, phone, city FROM Customers WHERE customerNumber=custNo;
+
+END;
+/
+
+------
+
+CREATE OR REPLACE PROCEDURE getCustomerFullWithNumber(custNo IN OUT NUMBER, custName OUT VARCHAR2, contactLastName OUT VARCHAR2,phone OUT VARCHAR2, city OUT VARCHAR2) AS
+
+BEGIN
+
+ SELECT customerName, customerNumber, contactLastName, phone, city INTO custName, custNo, contactLastName, phone, city FROM Customers WHERE customerNumber=custNo;
+
+END;
+/
+
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Products.sql
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Products.sql?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Products.sql (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/sql/Products.sql Fri Oct 7 07:34:46 2011
@@ -6,7 +6,7 @@
insert into Products values ('S10_4962','1962 LanciaA Delta 16V','Classic Cars','1:10','Second Gear Diecast','Features include: Turnable front wheels; steering function; detailed interior; detailed engine; opening hood; opening trunk; opening doors; and detailed chassis.',6791,103.42,147.74);
insert into Products values ('S12_1099','1968 Ford Mustang','Classic Cars','1:12','Autoart Studio Design','Hood, doors and trunk all open to reveal highly detailed interior features. Steering wheel actually turns the front wheels. Color dark green.',68,95.34,194.57);
insert into Products values ('S12_1108','2001 Ferrari Enzo','Classic Cars','1:12','Second Gear Diecast','Turnable front wheels; steering function; detailed interior; detailed engine; opening hood; opening trunk; opening doors; and detailed chassis.',3619,95.59,207.8);
-insert into Products values ('S12_1666','1958 Setra Bus','Trucks and Buses','1:12','Welly Diecast Productions','Model features 30 windows, skylights & glare resistant glass, working steering system, original logos',1579,77.9,136.67);
+insert into Products values ('S12_1666','1958 Setra Bus','Trucks and Buses','1:12','Welly Diecast Productions','Model features 30 windows, skylights / glare resistant glass, working steering system, original logos',1579,77.9,136.67);
insert into Products values ('S12_2823','2002 Suzuki XREO','Motorcycles','1:12','Unimax Art Galleries','Official logos and insignias, saddle bags located on side of motorcycle, detailed engine, working steering, working suspension, two leather seats, luggage rack, dual exhaust pipes, small saddle bag located on handle bars, two-tone paint with chrome accents, superior die-cast detail , rotating wheels , working kick stand, diecast metal with plastic parts and baked enamel finish.',9997,66.27,150.62);
insert into Products values ('S12_3148','1969 Corvair Monza','Classic Cars','1:18','Welly Diecast Productions','1:18 scale die-cast about 10'' long doors open, hood opens, trunk opens and wheels roll',6906,89.14,151.08);
insert into Products values ('S12_3380','1968 Dodge Charger','Classic Cars','1:12','Welly Diecast Productions','1:12 scale model of a 1968 Dodge Charger. Hood, doors and trunk all open to reveal highly detailed interior features. Steering wheel actually turns the front wheels. Color black',9123,75.16,117.44);
@@ -85,7 +85,6 @@
insert into Products values ('S32_1268','1980�s GM Manhattan Express','Trucks and Buses','1:32','Motor City Art Classics','This 1980�s era new look Manhattan express is still active, running from the Bronx to mid-town Manhattan. Has 35 opeining windows and working lights. Needs a battery.',5099,53.93,96.31);
insert into Products values ('S32_1374','1997 BMW F650 ST','Motorcycles','1:32','Exoto Designs','Features official die-struck logos and baked enamel finish. Comes with stand.',178,66.92,99.89);
insert into Products values ('S32_2206','1982 Ducati 996 R','Motorcycles','1:32','Gearbox Collectibles','Features rotating wheels , working kick stand. Comes with stand.',9241,24.14,40.23);
-insert into Products values ('S32_2509','1954 Greyhound Scenicruiser','Trucks and Buses','1:32','Classic Metal Creations','Model features bi-level seating, 50 windows, skylights & glare resistant glass, working steering system, original logos',2874,25.98,54.11);
insert into Products values ('S32_3207','1950''s Chicago Surface Lines Streetcar','Trains','1:32','Gearbox Collectibles','This streetcar is a joy to see. It has 80 separate windows, electric wire guides, detailed interiors with seats, poles and drivers controls, rolling and turning wheel assemblies, plus authentic factory baked-enamel finishes (Green Hornet for Chicago and Cream and Crimson for Boston).',8601,26.72,62.14);
insert into Products values ('S32_3522','1996 Peterbilt 379 Stake Bed with Outrigger','Trucks and Buses','1:32','Red Start Diecast','This model features, opening doors, detailed engine, working steering, tinted windows, detailed interior, die-struck logos, removable stakes operating outriggers, detachable second trailer, functioning 360-degree self loader, precision molded resin trailer and trim, baked enamel finish on cab',814,33.61,64.64);
insert into Products values ('S32_4289','1928 Ford Phaeton Deluxe','Vintage Cars','1:32','Highway 66 Mini Classics','This model features grille-mounted chrome horn, lift-up louvered hood, fold-down rumble seat, working steering system',136,33.02,68.79);
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleAdvancedStoredProcService.dbs
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleAdvancedStoredProcService.dbs?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleAdvancedStoredProcService.dbs Fri Oct 7 07:34:46 2011
@@ -0,0 +1,76 @@
+<data name="OracleAdvancedStoredProcService">
+ <config>
+ <property name="org.wso2.ws.dataservice.driver">oracle.jdbc.driver.OracleDriver</property>
+ <property name="org.wso2.ws.dataservice.protocol">jdbc:oracle:thin:@localhost:1521/xe</property>
+ <property name="org.wso2.ws.dataservice.user">datauser</property>
+ <property name="org.wso2.ws.dataservice.password">wso2</property>
+ <property name="org.wso2.ws.dataservice.minpoolsize">2</property>
+ <property name="org.wso2.ws.dataservice.maxpoolsize">100</property>
+
+ </config>
+
+ <!-- Query for a stored procedure with out params -->
+ <query id="stored_procedure_with_out_params_query">
+ <sql>CALL get103CustomerLim(?,?)</sql>
+ <param name="customerNumber" sqlType="INTEGER" type="OUT" />
+ <param name="customerName" sqlType="STRING" type="OUT" />
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ </result>
+ </query>
+
+ <!-- Query for a stored procedure with out params and a result set -->
+ <query id="stored_procedure_with_out_params_result_set_query">
+ <sql>CALL get103CustomerFull(?,?,?,?,?)</sql>
+ <param name="customerNumber" sqlType="INTEGER" type="OUT" />
+ <param name="customerName" sqlType="STRING" type="OUT" />
+ <param name="contactLastName" sqlType="STRING" type="OUT" />
+ <param name="phone" sqlType="STRING" type="OUT" />
+ <param name="city" sqlType="STRING" type="OUT" />
+
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+ <!-- Query for a stored procedure with out params and a result set -->
+ <query id="stored_procedure_with_inout_params_result_set_query">
+ <sql>CALL getCustomerFullWithNumber(?,?,?,?,?)</sql>
+ <param name="customerNumber" sqlType="INTEGER" type="INOUT" />
+ <param name="customerName" sqlType="STRING" type="OUT" />
+ <param name="contactLastName" sqlType="STRING" type="OUT" />
+ <param name="phone" sqlType="STRING" type="OUT" />
+ <param name="city" sqlType="STRING" type="OUT" />
+
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+ <operation name="stored_procedure_with_out_params_op">
+ <call-query href="stored_procedure_with_out_params_query">
+ </call-query>
+ </operation>
+
+ <operation name="stored_procedure_with_out_params_result_set_op">
+ <call-query href="stored_procedure_with_out_params_result_set_query">
+ </call-query>
+ </operation>
+
+ <operation name="stored_procedure_with_inout_params_result_set_op">
+ <call-query href="stored_procedure_with_inout_params_result_set_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+</data>
+
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBasicService.dbs
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBasicService.dbs?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBasicService.dbs Fri Oct 7 07:34:46 2011
@@ -0,0 +1,165 @@
+<data name="OracleBasicService">
+ <config>
+ <property name="org.wso2.ws.dataservice.driver">oracle.jdbc.driver.OracleDriver</property>
+ <property name="org.wso2.ws.dataservice.protocol">jdbc:oracle:thin:@localhost:1521/xe</property>
+ <property name="org.wso2.ws.dataservice.user">datauser</property>
+ <property name="org.wso2.ws.dataservice.password">wso2</property>
+ <property name="org.wso2.ws.dataservice.minpoolsize">2</property>
+ <property name="org.wso2.ws.dataservice.maxpoolsize">100</property>
+
+ </config>
+
+ <!-- Query and Operation for a plain SELECT with given fields test -->
+ <query id="select_query_given_fields">
+ <sql>SELECT customerNumber, customerName, contactLastName, phone, city
+ FROM Customers</sql>
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber"
+ xsdType="xs:integer" />
+ <element name="customerName" column="customerName" xsdType="xs:string" />
+ <element name="contactLastName" column="contactLastName"
+ xsdType="xs:string" />
+ <element name="phone" column="phone" xsdType="xs:string" />
+ <element name="city" column="city" xsdType="xs:string" />
+ </result>
+ </query>
+
+ <operation name="select_op_given_fields">
+ <call-query href="select_query_given_fields">
+ </call-query>
+ </operation>
+
+ <resource path="customers1" method="GET">
+ <call-query href="select_query_given_fields" />
+ </resource>
+
+ <!-- Query and Operation for a plain SELECT with all fields test -->
+ <query id="select_query_all_fields">
+ <sql>SELECT * FROM Products</sql>
+
+ <result element="Products" rowName="Product">
+ <element name="productCode" column="productCode" xsdType="xs:string" />
+ <element name="productName" column="productName" xsdType="xs:string" />
+ <element name="quantityInStock" column="quantityInStock"
+ xsdType="xs:integer" />
+ <element name="buyPrice" column="buyPrice" xsdType="xs:double" />
+ </result>
+ </query>
+
+ <operation name="select_op_all_fields">
+ <call-query href="select_query_all_fields">
+ </call-query>
+ </operation>
+
+ <resource path="customers2" method="POST">
+ <call-query href="select_query_given_fields" />
+ </resource>
+
+ <!-- Query and Operation for a SELECT COUNT -->
+ <query id="select_query_count">
+ <sql>SELECT COUNT(*) as orderDetailsCount FROM OrderDetails</sql>
+
+ <result element="Orders" rowName="OrderDetails">
+ <element name="orderDetailsCount" column="orderDetailsCount"
+ xsdType="xs:integer" />
+ </result>
+ </query>
+
+ <operation name="select_op_count">
+ <call-query href="select_query_count">
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for a SELECT with attributes test -->
+ <query id="select_attributes_query">
+ <sql>SELECT customerNumber, checkNumber, paymentDate, amount FROM
+ Payments</sql>
+
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber"
+ xsdType="xs:integer" />
+ <attribute name="paymentDate" column="paymentDate" xsdType="xs:dateTime" />
+ <attribute name="amount" column="amount" xsdType="xs:double" />
+ <element name="checkNumber" column="checkNumber" xsdType="xs:string" />
+ </result>
+ </query>
+
+ <operation name="select_attributes_for_date_time_op">
+ <call-query href="select_attributes_query">
+ </call-query>
+ </operation>
+
+ <query id="basic_merge_query1" useConfig="default">
+ <sql>SELECT customerNumber, customerName, contactLastName, phone, city
+ FROM Customers WHERE rownum BETWEEN 1 AND 2</sql>
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber"
+ xsdType="xs:integer" />
+ <element name="customerName" column="customerName" xsdType="xs:string" />
+ <element name="contactLastName" column="contactLastName"
+ xsdType="xs:string" />
+ <element name="phone" column="phone" xsdType="xs:string" />
+ <element name="city" column="city" xsdType="xs:string" />
+ </result>
+ </query>
+ <query id="basic_merge_query2" useConfig="default">
+ <sql>SELECT customerNumber, customerName, contactLastName, phone, city
+ FROM (select rownum r,customerNumber, customerName, contactLastName,
+ phone, city FROM Customers ) WHERE r BETWEEN 4 AND 6</sql>
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber"
+ xsdType="xs:integer" />
+ <element name="customerName" column="customerName" xsdType="xs:string" />
+ <element name="contactLastName" column="contactLastName"
+ xsdType="xs:string" />
+ <element name="phone" column="phone" xsdType="xs:string" />
+ <element name="city" column="city" xsdType="xs:string" />
+ </result>
+ </query>
+
+ <operation name="basic_merge_op">
+ <call-query-group>
+ <call-query href="basic_merge_query1">
+ </call-query>
+ <call-query href="basic_merge_query2">
+ </call-query>
+ </call-query-group>
+ </operation>
+
+ <!-- Array types -->
+ <query id="testArrayTypes" useConfig="default">
+ <sql>select customerNumber,customerName,contactLastName,phone,city
+ from Customers where country = ? and state IN (?) and creditLimit > ?
+ and city IN (?) and contactFirstName = ?</sql>
+
+ <param name="country" sqlType="STRING" ordinal="1" paramType="SCALAR" />
+ <param name="state" sqlType="STRING" ordinal="2" paramType="ARRAY" />
+ <param name="creditLimit" sqlType="INTEGER" ordinal="3"
+ paramType="SCALAR" />
+ <param name="city" sqlType="STRING" ordinal="4" paramType="ARRAY" />
+ <param name="contactFirstName" sqlType="STRING" ordinal="5"
+ paramType="SCALAR" />
+
+ <result element="Customers" rowName="Customer"
+ useColumnNumbers="true">
+ <element name="customerNumber" column="1" xsdType="xs:integer" />
+ <element name="customerName" column="2" xsdType="xs:string" />
+ <element name="contactLastName" column="3" xsdType="xs:string" />
+ <element name="phone" column="4" xsdType="xs:string" />
+ <element name="city" column="5" xsdType="xs:string" />
+ </result>
+ </query>
+
+ <operation name="basic_array_type_op">
+ <call-query href="testArrayTypes">
+ <with-param name="country" query-param="country" />
+ <with-param name="state" query-param="state" />
+ <with-param name="creditLimit" query-param="creditLimit" />
+ <with-param name="city" query-param="city" />
+ <with-param name="contactFirstName" query-param="contactFirstName" />
+ </call-query>
+ </operation>
+
+
+</data>
+
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBinaryDataService.dbs
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBinaryDataService.dbs?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleBinaryDataService.dbs Fri Oct 7 07:34:46 2011
@@ -0,0 +1,52 @@
+<data name="OracleBinaryDataService">
+ <config>
+ <property name="org.wso2.ws.dataservice.driver">oracle.jdbc.driver.OracleDriver</property>
+ <property name="org.wso2.ws.dataservice.protocol">jdbc:oracle:thin:@localhost:1521/xe</property>
+ <property name="org.wso2.ws.dataservice.user">datauser</property>
+ <property name="org.wso2.ws.dataservice.password">wso2</property>
+ <property name="org.wso2.ws.dataservice.minpoolsize">2</property>
+ <property name="org.wso2.ws.dataservice.maxpoolsize">100</property>
+ </config>
+
+ <!-- Query to store binary data -->
+ <query id="store_binary_data_query">
+ <sql>INSERT INTO BinaryData (id,data) values(?,?)</sql>
+ <param name="id" sqlType="INTEGER" />
+ <param name="data" sqlType="BINARY" />
+ </query>
+
+ <!-- Query to retrieve binary data -->
+ <query id="retrieve_binary_data_query">
+ <sql>SELECT * FROM BinaryData WHERE id=?</sql>
+ <param name="id" sqlType="INTEGER" />
+ <result element="DataList" rowName="DataEntry">
+ <element name="data" column="data" />
+ </result>
+ </query>
+
+ <!-- Query to delete binary data -->
+ <query id="delete_binary_data_query">
+ <sql>DELETE FROM BinaryData WHERE id=?</sql>
+ <param name="id" sqlType="INTEGER" />
+ </query>
+
+ <operation name="retrieve_binary_data_op">
+ <call-query href="retrieve_binary_data_query">
+ <with-param name="id" query-param="id" />
+ </call-query>
+ </operation>
+
+ <operation name="store_binary_data_op">
+ <call-query href="store_binary_data_query">
+ <with-param name="id" query-param="id" />
+ <with-param name="data" query-param="data" />
+ </call-query>
+ </operation>
+
+ <operation name="delete_binary_data_op">
+ <call-query href="delete_binary_data_query">
+ <with-param name="id" query-param="id" />
+ </call-query>
+ </operation>
+
+</data>
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleDMLService.dbs
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleDMLService.dbs?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleDMLService.dbs Fri Oct 7 07:34:46 2011
@@ -0,0 +1,159 @@
+<data name="OracleDMLService">
+ <config>
+ <property name="org.wso2.ws.dataservice.driver">oracle.jdbc.driver.OracleDriver</property>
+ <property name="org.wso2.ws.dataservice.protocol">jdbc:oracle:thin:@localhost:1521/xe</property>
+ <property name="org.wso2.ws.dataservice.user">datauser</property>
+ <property name="org.wso2.ws.dataservice.password">wso2</property>
+ <property name="org.wso2.ws.dataservice.minpoolsize">2</property>
+ <property name="org.wso2.ws.dataservice.maxpoolsize">100</property>
+
+ </config>
+
+ <!-- Query and Operation for INSERT test -->
+ <query id="insert_data_query">
+ <sql>INSERT INTO Customers (customerNumber,customerName,contactLastName,phone,city) values(?,?,?,?,?)</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ <param name="customerName" sqlType="STRING" />
+ <param name="contactLastName" sqlType="STRING" />
+ <param name="phone" sqlType="STRING" />
+ <param name="city" sqlType="STRING" />
+ </query>
+
+ <operation name="insert_data_op">
+ <call-query href="insert_data_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ <with-param name="customerName" query-param="customerName" />
+ <with-param name="contactLastName" query-param="contactLastName" />
+ <with-param name="phone" query-param="phone" />
+ <with-param name="city" query-param="city" />
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for UPDATE test with no result nested query -->
+ <query id="update_data_nested_query">
+ <sql>SELECT * FROM Customers WHERE customerNumber=?</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ <result element="Customers" rowName="Customer">
+ <element name="phone" column="phone" />
+ <call-query href="update_data_query">
+ <with-param name="customerName" column="customerName" />
+ <with-param name="contactLastName" column="contactLastName" />
+ <with-param name="phone" column="phone" />
+ <with-param name="city" column="city" />
+ </call-query>
+ </result>
+ </query>
+
+ <query id="update_data_nested_stored_proc_query">
+ <sql>CALL getCustomerInfoWithId(?,?)</sql>
+ <param name="customerNumber" sqlType="INTEGER" type="IN"/>
+ <param name="result" sqlType="ORACLE_REF_CURSOR" type="OUT"/>
+
+ <result element="Customers" rowName="Customer">
+ <element name="phone" column="phone" />
+ <call-query href="update_data_query">
+ <with-param name="customerName" column="customerName" />
+ <with-param name="contactLastName" column="contactLastName" />
+ <with-param name="phone" column="phone" />
+ <with-param name="city" column="city" />
+ </call-query>
+ </result>
+ </query>
+
+ <query id="update_data_query">
+ <sql>UPDATE Customers SET customerName=?,contactLastName=?,phone=?,city=? WHERE customerNumber=450001</sql>
+ <param name="customerName" sqlType="STRING" />
+ <param name="contactLastName" sqlType="STRING" />
+ <param name="phone" sqlType="STRING" />
+ <param name="city" sqlType="STRING" />
+ </query>
+
+ <operation name="update_data_op">
+ <call-query href="update_data_nested_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+ <operation name="update_stored_proc_data_op">
+ <call-query href="update_data_nested_stored_proc_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for DELETE test -->
+ <query id="delete_data_query">
+ <sql>DELETE FROM Customers WHERE customerNumber=?</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ </query>
+
+ <operation name="delete_data_op">
+ <call-query href="delete_data_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for SELECT with a given id test -->
+ <query id="select_data_query">
+ <sql>SELECT * FROM Customers WHERE customerNumber=?</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+ <operation name="select_data_op">
+ <call-query href="select_data_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for a SELECT COUNT with a given id -->
+ <query id="select_count_id_query">
+ <sql>SELECT COUNT(*) as customerCount FROM Customers WHERE customerNumber=?</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ <result element="Customers" rowName="CustomerDetails">
+ <element name="customerCount" column="customerCount" />
+ </result>
+ </query>
+
+ <operation name="select_count_id_op">
+ <call-query href="select_count_id_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for insert operation with validation -->
+
+ <query id="insert_data_val_query">
+ <sql>INSERT INTO Customers (customerNumber,customerName,contactLastName,phone,city) values(?,?,?,?,?)</sql>
+ <param name="customerNumber" sqlType="INTEGER">
+ <validateLongRange minimum="450001" maximum="450001" />
+ </param>
+ <param name="customerName" sqlType="STRING">
+ <validateLength minimum="5" />
+ </param>
+ <param name="contactLastName" sqlType="STRING">
+ <validateLength maximum="20" />
+ <validateCustom class="org.wso2.carbon.dataservices.core.test.util.OddLengthValidator" />
+ </param>
+ <param name="phone" sqlType="STRING">
+ <validatePattern pattern="^\([1-9]\d{2}\)\s?\d{3}\-\d{4}$" />
+ </param>
+ <param name="city" sqlType="STRING" />
+ </query>
+
+ <operation name="insert_data_val_op">
+ <call-query href="insert_data_val_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ <with-param name="customerName" query-param="customerName" />
+ <with-param name="contactLastName" query-param="contactLastName" />
+ <with-param name="phone" query-param="phone" />
+ <with-param name="city" query-param="city" />
+ </call-query>
+ </operation>
+
+</data>
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleInputMappingService.dbs
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleInputMappingService.dbs?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleInputMappingService.dbs Fri Oct 7 07:34:46 2011
@@ -0,0 +1,126 @@
+<data name="OracleInputMappingService">
+ <config>
+ <property name="org.wso2.ws.dataservice.driver">oracle.jdbc.driver.OracleDriver</property>
+ <property name="org.wso2.ws.dataservice.protocol">jdbc:oracle:thin:@localhost:1521/xe</property>
+ <property name="org.wso2.ws.dataservice.user">datauser</property>
+ <property name="org.wso2.ws.dataservice.password">wso2</property>
+ <property name="org.wso2.ws.dataservice.minpoolsize">2</property>
+ <property name="org.wso2.ws.dataservice.maxpoolsize">100</property>
+
+ </config>
+
+ <!-- Query and Operation for a SELECT with a DATE and INTEGER input mapping -->
+ <query id="select_input_mappings_query1" input-event-trigger="id1" output-event-trigger="id1">
+ <sql>SELECT * FROM Orders WHERE orderNumber=? AND orderDate=?</sql>
+ <param name="orderNumber" sqlType="INTEGER" />
+ <param name="orderDate" sqlType="DATE" />
+ <result element="Orders" rowName="Order">
+ <attribute name="customerNumber" column="customerNumber" />
+ <element name="orderNumber" column="orderNumber" />
+ <element name="orderDate" column="orderDate" />
+ <element name="requiredDate" column="requiredDate" />
+ <element name="shippedDate" column="shippedDate" />
+ <element name="status" column="status" />
+ <element name="comments" column="comments" />
+ </result>
+ </query>
+
+ <event-trigger id="id1" language="XPath">
+ <expression>/Orders/Order/orderNumber=100</expression>
+ <target-topic>/a/b/t1</target-topic>
+ <subscriptions>
+ <subscription>mailto:test at test.com</subscription>
+ </subscriptions>
+ </event-trigger>
+
+ <operation name="select_input_mappings_for_date_time_op1">
+ <call-query href="select_input_mappings_query1">
+ <with-param name="orderNumber" query-param="orderNumber" />
+ <with-param name="orderDate" query-param="orderDate" />
+ </call-query>
+ </operation>
+
+ <operation name="select_input_mappings_op1">
+ <call-query href="select_input_mappings_query1">
+ <with-param name="orderNumber" query-param="orderNumber" />
+ <with-param name="orderDate" query-param="orderDate" />
+ </call-query>
+ </operation>
+
+ <!-- Query and Operation for a SELECT with a DOUBLE, INTEGER and STRING input mapping -->
+ <query id="select_input_mappings_query2">
+ <sql>SELECT customerNumber, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber=:customerNumber AND checkNumber=:checkNumber AND amount=?</sql>
+ <param name="checkNumber" sqlType="STRING" ordinal="2" />
+ <param name="amount" sqlType="DOUBLE" ordinal="3" />
+ <param name="customerNumber" sqlType="INTEGER" ordinal="1" />
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ </result>
+ </query>
+
+ <operation name="select_input_mappings_for_date_time_op2">
+ <call-query href="select_input_mappings_query2">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ <with-param name="checkNumber" query-param="checkNumber" />
+ <with-param name="amount" query-param="amount" />
+ </call-query>
+ </operation>
+
+ <query id="select_input_mappings_merge_query1">
+ <sql>SELECT customerNumber, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber=:customerNumber AND paymentDate=:paymentDate</sql>
+ <param name="paymentDate" sqlType="DATE"/>
+ <param name="customerNumber" sqlType="INTEGER"/>
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ </result>
+ </query>
+
+ <query id="select_input_mappings_merge_query2">
+ <sql>SELECT customerNumber, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber=:customerNumber AND rownum BETWEEN 1 AND 2</sql>
+ <param name="customerNumber" sqlType="INTEGER"/>
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ </result>
+ </query>
+
+ <operation name="select_input_mappings_merge_for_date_time_op">
+ <call-query-group>
+ <call-query href="select_input_mappings_merge_query1">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ <with-param name="paymentDate" query-param="paymentDate"/>
+ </call-query>
+ <call-query href="select_input_mappings_merge_query2">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </call-query-group>
+ </operation>
+
+ <!-- Input parameters with default values -->
+ <query id="select_input_mappings_with_def_value">
+ <sql>SELECT customerNumber, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber=:customerNumber AND rownum BETWEEN 1 AND 2</sql>
+ <param name="customerNumber" sqlType="INTEGER" defaultValue="299"/>
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ </result>
+ </query>
+
+ <operation name="results_with_default_values_for_date_time_op">
+ <call-query href="select_input_mappings_with_def_value">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+</data>
+
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleNestedQueryStoredProcService.dbs
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleNestedQueryStoredProcService.dbs?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/test-dbs/OracleNestedQueryStoredProcService.dbs Fri Oct 7 07:34:46 2011
@@ -0,0 +1,226 @@
+<data name="OracleNestedQueryStoredProcService">
+ <config>
+ <property name="org.wso2.ws.dataservice.driver">oracle.jdbc.driver.OracleDriver</property>
+ <property name="org.wso2.ws.dataservice.protocol">jdbc:oracle:thin:@localhost:1521/xe</property>
+ <property name="org.wso2.ws.dataservice.user">datauser</property>
+ <property name="org.wso2.ws.dataservice.password">wso2</property>
+ <property name="org.wso2.ws.dataservice.minpoolsize">2</property>
+ <property name="org.wso2.ws.dataservice.maxpoolsize">100</property>
+
+ </config>
+
+ <!-- Query to retrieve Customer data with the given ID -->
+ <query id="select_customer_query">
+ <sql>SELECT customerNumber, customerName, contactLastName, phone, city FROM Customers WHERE customerNumber=?</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+ <!-- Nested Query to retrieve Payment/Customer data -->
+ <query id="select_payment_query">
+ <sql>SELECT customerNumber AS customerNumberDifferentName, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber is NOT NULL</sql>
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumberDifferentName" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ <call-query href="select_customer_query">
+ <with-param name="customerNumber" column="customerNumberDifferentName" />
+ </call-query>
+ </result>
+ </query>
+
+ <operation name="payment_info_op">
+ <call-query href="select_payment_query">
+ </call-query>
+ </operation>
+
+ <!-- Nested Query to retrieve Order/Customer data with the given ID -->
+ <query id="select_order_query">
+ <sql>SELECT * FROM Orders WHERE orderNumber=?</sql>
+ <param name="orderNumber" sqlType="INTEGER" />
+ <result element="Orders" rowName="Order">
+ <attribute name="customerNumber" column="customerNumber" />
+ <element name="orderNumber" column="orderNumber" />
+ <element name="orderDate" column="orderDate" />
+ <element name="requiredDate" column="requiredDate" />
+ <element name="shippedDate" column="shippedDate" />
+ <element name="status" column="status" />
+ <element name="comments" column="comments" />
+ <call-query href="select_customer_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </result>
+ </query>
+
+ <!-- Query to retrieve OrderDetails -->
+ <query id="select_order_details_query">
+ <sql>SELECT * FROM OrderDetails WHERE rownum BETWEEN 1 AND 100</sql>
+ <result element="OrderDetails" rowName="OrderDetailsInfo">
+ <element name="orderNumber" column="orderNumber" />
+ <element name="productCode" column="productCode" />
+ <element name="quantityOrdered" column="quantityOrdered" />
+ <element name="priceEach" column="priceEach" />
+ <element name="orderLineNumber" column="orderLineNumber" />
+ <call-query href="select_order_query">
+ <with-param name="orderNumber" query-param="orderNumber" />
+ </call-query>
+ </result>
+ </query>
+
+ <operation name="order_details_for_date_time_op">
+ <call-query href="select_order_details_query">
+ </call-query>
+ </operation>
+
+ <!-- Query for a stored procedure with no params -->
+ <query id="stored_procedure_noparam_query">
+ <sql>CALL getCustomerInfo(:result)</sql>
+ <param name="result" sqlType="ORACLE_REF_CURSOR" type="OUT" />
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+ <!-- Query for a stored procedure with params - 1 -->
+ <query id="stored_procedure_withparam_query1">
+ <sql>CALL getCustomerInfoWithIdLastName(:customerNumber,:contactLastName,:result)</sql>
+ <param name="customerNumber" sqlType="INTEGER" type="IN"/>
+ <param name="contactLastName" sqlType="STRING" type="IN"/>
+ <param name="result" sqlType="ORACLE_REF_CURSOR" type="OUT"/>
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+ <operation name="stored_procedure_noparam_op">
+ <call-query href="stored_procedure_noparam_query">
+ </call-query>
+ </operation>
+
+ <operation name="stored_procedure_withparam_op">
+ <call-query href="stored_procedure_withparam_query1">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ <with-param name="contactLastName" query-param="contactLastName" />
+ </call-query>
+ </operation>
+
+ <!-- Query for a stored procedure with params - 2 -->
+ <query id="stored_procedure_withparam_query2">
+ <sql>CALL getCustomerInfoWithId(?,:result)</sql>
+ <param name="customerNumber" sqlType="INTEGER" type="IN"/>
+ <param name="result" sqlType="ORACLE_REF_CURSOR" type="OUT"/>
+
+ <result element="Customers" rowName="Customer">
+ <element name="customerNumber" column="customerNumber" />
+ <element name="customerName" column="customerName" />
+ <element name="contactLastName" column="contactLastName" />
+ <element name="phone" column="phone" />
+ <element name="city" column="city" />
+ </result>
+ </query>
+
+
+ <!-- Nested Query with an inner stored procedure to retrieve Payment/Customer data -->
+ <query id="stored_procedure_nested_query1">
+ <sql>SELECT customerNumber, checkNumber, paymentDate, amount FROM Payments WHERE customerNumber is NOT NULL</sql>
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ <call-query href="stored_procedure_withparam_query2">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </result>
+ </query>
+
+ <operation name="stored_procedure_nested_for_date_time_op1">
+ <call-query href="stored_procedure_nested_query1" />
+ </operation>
+
+ <!-- Nested Query with a with outer stored proc to retrieve Payment/Customer data -->
+ <query id="stored_procedure_nested_query2">
+ <sql>CALL getPaymentInfo(?)</sql>
+ <param name="result" sqlType="ORACLE_REF_CURSOR" type="OUT"/>
+
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <element name="checkNumber" column="checkNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+
+ <call-query href="select_customer_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </result>
+ </query>
+
+ <operation name="stored_procedure_nested_for_date_time_op2">
+ <call-query href="stored_procedure_nested_query2" />
+ </operation>
+
+ <!-- Nested Query with a with inner and outer stored procs to retrieve Payment/Customer data -->
+ <query id="stored_procedure_nested_query3">
+ <sql>CALL getPaymentInfo(?)</sql>
+ <param name="result" sqlType="ORACLE_REF_CURSOR" type="OUT"/>
+ <result element="Payments" rowName="Payment">
+ <attribute name="customerNumber" column="customerNumber" />
+ <attribute name="paymentDate" column="paymentDate" />
+ <attribute name="amount" column="amount" />
+ <element name="checkNumber" column="checkNumber" />
+ <call-query href="stored_procedure_withparam_query2">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </result>
+ </query>
+
+ <operation name="stored_procedure_nested_for_date_time_op3">
+ <call-query href="stored_procedure_nested_query3" />
+ </operation>
+
+ <!-- Query for a stored function with no params -->
+ <query id="stored_func_noparam_query">
+ <sql>SELECT getAverageCreditLimit() averageCreditLimit FROM Customers</sql>
+
+ <result element="CreditLimit" rowName="AverageCreditLimit">
+ <element name="value" column="averageCreditLimit" />
+ </result>
+ </query>
+
+ <operation name="stored_func_noparam_op">
+ <call-query href="stored_func_noparam_query" />
+ </operation>
+
+ <!-- Query for a stored function with params -->
+ <query id="stored_func_withparam_query">
+ <sql>SELECT getCustomerPhoneNumber(?) phoneNumber FROM Customers</sql>
+ <param name="customerNumber" sqlType="INTEGER" />
+ <result element="Customer" rowName="Phone">
+ <element name="value" column="phoneNumber" />
+ </result>
+ </query>
+
+ <operation name="stored_func_withparam_op">
+ <call-query href="stored_func_withparam_query">
+ <with-param name="customerNumber" query-param="customerNumber" />
+ </call-query>
+ </operation>
+
+
+</data>
+
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested.xsd
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested.xsd?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested.xsd (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested.xsd Fri Oct 7 07:34:46 2011
@@ -72,4 +72,4 @@
</xs:complexType>
</xs:element>
-</xs:schema>
\ No newline at end of file
+</xs:schema>
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested_with_date_time.xsd
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested_with_date_time.xsd?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/order_details_nested_with_date_time.xsd Fri Oct 7 07:34:46 2011
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ ~ Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+ ~
+ ~ WSO2 Inc. 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.
+ -->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ws.wso2.org/dataservice" xmlns="http://ws.wso2.org/dataservice" elementFormDefault="qualified" attributeFormDefault="unqualified">
+
+<xs:element name="OrderDetails">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="OrderDetailsInfo" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="orderNumber" type="xs:integer"/>
+ <xs:element name="productCode" type="xs:string"/>
+ <xs:element name="quantityOrdered" type="xs:integer"/>
+ <xs:element name="priceEach" type="xs:decimal"/>
+ <xs:element name="orderLineNumber" type="xs:integer"/>
+ <xs:element name="Orders">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="Order" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="orderNumber" type="xs:string"/>
+ <xs:element name="orderDate" type="xs:dateTime"/>
+ <xs:element name="requiredDate" type="xs:dateTime"/>
+ <xs:element name="shippedDate" type="xs:dateTime"/>
+ <xs:element name="status" type="xs:string"/>
+ <xs:element name="comments" type="xs:string" nillable="true"/>
+ <xs:element name="Customers">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="Customer" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="customerNumber" type="xs:integer"/>
+ <xs:element name="customerName" type="xs:string"/>
+ <xs:element name="contactLastName" type="xs:string"/>
+ <xs:element name="phone" type="xs:string"/>
+ <xs:element name="city" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ <xs:attribute name="customerNumber" type="xs:integer"/>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+</xs:element>
+
+</xs:schema>
Modified: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders.xsd
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders.xsd?rev=113617&r1=113616&r2=113617&view=diff
==============================================================================
--- trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders.xsd (original)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders.xsd Fri Oct 7 07:34:46 2011
@@ -38,4 +38,4 @@
</xs:complexType>
</xs:element>
-</xs:schema>
\ No newline at end of file
+</xs:schema>
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders_with_date_time.xsd
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders_with_date_time.xsd?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/orders_with_date_time.xsd Fri Oct 7 07:34:46 2011
@@ -0,0 +1,41 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ ~ Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+ ~
+ ~ WSO2 Inc. 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.
+ -->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ws.wso2.org/dataservice" elementFormDefault="qualified" attributeFormDefault="unqualified">
+
+<xs:element name="Orders">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="Order" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="orderNumber" type="xs:string"/>
+ <xs:element name="orderDate" type="xs:dateTime"/>
+ <xs:element name="requiredDate" type="xs:dateTime"/>
+ <xs:element name="shippedDate" type="xs:dateTime"/>
+ <xs:element name="status" type="xs:string"/>
+ <xs:element name="comments" type="xs:string"/>
+ </xs:sequence>
+ <xs:attribute name="customerNumber" type="xs:integer"/>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+</xs:element>
+
+</xs:schema>
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payment_info_nested_with_date_time.xsd
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payment_info_nested_with_date_time.xsd?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payment_info_nested_with_date_time.xsd Fri Oct 7 07:34:46 2011
@@ -0,0 +1,55 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ ~ Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+ ~
+ ~ WSO2 Inc. 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.
+ -->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ws.wso2.org/dataservice" elementFormDefault="qualified" attributeFormDefault="unqualified">
+
+<xs:element name="Payments">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="Payment" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="checkNumber" type="xs:string"/>
+ <xs:element name="Customers">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="Customer" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="customerNumber" type="xs:integer"/>
+ <xs:element name="customerName" type="xs:string"/>
+ <xs:element name="contactLastName" type="xs:string"/>
+ <xs:element name="phone" type="xs:string"/>
+ <xs:element name="city" type="xs:string"/>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ <xs:attribute name="customerNumber" type="xs:integer"/>
+ <xs:attribute name="paymentDate" type="xs:dateTime"/>
+ <xs:attribute name="amount" type="xs:decimal"/>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+</xs:element>
+
+</xs:schema>
Added: trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payments_with_date_time.xsd
URL: http://wso2.org/svn/browse/wso2/trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payments_with_date_time.xsd?pathrev=113617
==============================================================================
--- (empty file)
+++ trunk/carbon/components/data-services/org.wso2.carbon.dataservices.core/src/test/resources/xsd/payments_with_date_time.xsd Fri Oct 7 07:34:46 2011
@@ -0,0 +1,38 @@
+<?xml version="1.0" encoding="UTF-8" ?>
+<!--
+ ~ Copyright (c) 2005-2010, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
+ ~
+ ~ WSO2 Inc. 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.
+ -->
+<xs:schema xmlns:xs="http://www.w3.org/2001/XMLSchema" targetNamespace="http://ws.wso2.org/dataservice" elementFormDefault="qualified" attributeFormDefault="unqualified">
+
+<xs:element name="Payments">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="Payment" maxOccurs="unbounded">
+ <xs:complexType>
+ <xs:sequence>
+ <xs:element name="checkNumber" type="xs:string"/>
+ </xs:sequence>
+ <xs:attribute name="customerNumber" type="xs:integer"/>
+ <xs:attribute name="paymentDate" type="xs:dateTime"/>
+ <xs:attribute name="amount" type="xs:decimal"/>
+ </xs:complexType>
+ </xs:element>
+ </xs:sequence>
+ </xs:complexType>
+</xs:element>
+
+</xs:schema>
More information about the Carbon-commits
mailing list