<?xml version="1.0" encoding="utf-8" ?>
<objects xmlns='http://www.springframework.net'>

  <object id="Test-SqlServer-2.0" type="Spring.Data.Common.DbProvider, Spring.Data" singleton="false">
    <constructor-arg name="dbMetaData">
      <object type="Spring.Data.Common.DbMetadata">
        <constructor-arg name="productName" value="Microsoft SQL Server, provider V2.0.0.0 in framework .NET V2.0" />
        <constructor-arg name="assemblyName" value="System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="connectionType" value="System.Data.SqlClient.SqlConnection, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="commandType" value="System.Data.SqlClient.SqlCommand, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="parameterType" value="System.Data.SqlClient.SqlParameter, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="dataAdapterType" value="System.Data.SqlClient.SqlDataAdapter, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="commandBuilderType" value="System.Data.SqlClient.SqlCommandBuilder, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="commandBuilderDeriveParametersMethod" value="DeriveParameters"/>
        <constructor-arg name="parameterDbType" value="System.Data.SqlDbType, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="parameterDbTypeProperty" value="SqlDbType"/>
        <constructor-arg name="parameterIsNullableProperty" value="IsNullable"/>
        <constructor-arg name="parameterNamePrefix" value="@"/>
        <constructor-arg name="exceptionType" value="System.Data.SqlClient.SqlException, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="useParameterNamePrefixInParameterCollection" value="true"/>
        <constructor-arg name="useParameterPrefixInSql" value="true"/>
        <constructor-arg name="bindByName" value="true"/>
        <!-- this is only true for .net 1.1 kept it here just in case we want to revert back to this strategy for
             obtaining error codes-->
        <constructor-arg name="errorCodeExceptionExpression" value="Errors[0].Number.ToString()"/>

        <!-- TODO select form system db all errors that have 'incorrect syntax' at the start of the error string-->
        <property name="ErrorCodes.BadSqlGrammarCodes">
          <value>156,170,207,208</value>
        </property>
        <property name="ErrorCodes.PermissionDeniedCodes">
          <value>229</value>
        </property>
        <property name="ErrorCodes.DataIntegrityViolationCodes">
          <value>544,2627,8114,8115</value>
        </property>
        <property name="ErrorCodes.DeadlockLoserCodes">
          <value>1205</value>
        </property>
      </object>
    </constructor-arg>

  </object>

  <object id="Test-SqlServer-2.0-BadErrorCodeExpression" type="Spring.Data.Common.DbProvider, Spring.Data" singleton="false">
    <constructor-arg name="dbMetaData">
      <object type="Spring.Data.Common.DbMetadata">
        <constructor-arg name="productName" value="Microsoft SQL Server, provider V2.0.0.0 in framework .NET V2.0" />
        <constructor-arg name="assemblyName" value="System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="connectionType" value="System.Data.SqlClient.SqlConnection, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="commandType" value="System.Data.SqlClient.SqlCommand, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="parameterType" value="System.Data.SqlClient.SqlParameter, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="dataAdapterType" value="System.Data.SqlClient.SqlDataAdapter, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="commandBuilderType" value="System.Data.SqlClient.SqlCommandBuilder, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="commandBuilderDeriveParametersMethod" value="DeriveParameters"/>
        <constructor-arg name="parameterDbType" value="System.Data.SqlDbType, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="parameterDbTypeProperty" value="SqlDbType"/>
        <constructor-arg name="parameterIsNullableProperty" value="IsNullable"/>
        <constructor-arg name="parameterNamePrefix" value="@"/>
        <constructor-arg name="exceptionType" value="System.Data.SqlClient.SqlException, System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089"/>
        <constructor-arg name="useParameterNamePrefixInParameterCollection" value="true"/>
        <constructor-arg name="useParameterPrefixInSql" value="true"/>
        <constructor-arg name="bindByName" value="true"/>
        <!-- this is only true for .net 1.1 kept it here just in case we want to revert back to this strategy for
             obtaining error codes-->
        <constructor-arg name="errorCodeExceptionExpression" value="156"/>

        <!-- TODO select form system db all errors that have 'incorrect syntax' at the start of the error string-->
        <property name="ErrorCodes.BadSqlGrammarCodes">
          <value>156,170,207,208</value>
        </property>
        <property name="ErrorCodes.PermissionDeniedCodes">
          <value>229</value>
        </property>
        <property name="ErrorCodes.DataIntegrityViolationCodes">
          <value>544,2627,8114,8115</value>
        </property>
        <property name="ErrorCodes.DeadlockLoserCodes">
          <value>1205</value>
        </property>
      </object>
    </constructor-arg>

  </object>
  
</objects>