System.Data.SQLite
Check-in [9582604b8d]
Not logged in

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Revise and extend compilation fixes from the previous check-in.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 9582604b8d890f5e91c5fdc502a023a81d13a723
User & Date: mistachkin 2015-08-12 19:59:47
Context
2015-08-12
20:15
Enhance test suite infrastructure to make it work properly without the interop assembly. check-in: e161b486c4 user: mistachkin tags: trunk
19:59
Revise and extend compilation fixes from the previous check-in. check-in: 9582604b8d user: mistachkin tags: trunk
17:53
Compilation fixes for .NET Compact Framework with custom compile options. check-in: 8d08bc1cf9 user: mistachkin tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to System.Data.SQLite/SQLite3.cs.

  1528   1528           if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
  1529   1529           {
  1530   1530               LogBind(handle, index, value);
  1531   1531           }
  1532   1532   
  1533   1533   #if !PLATFORM_COMPACTFRAMEWORK
  1534   1534           SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_double(handle, index, value);
         1535  +        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1535   1536   #elif !SQLITE_STANDARD
  1536   1537           SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_double_interop(handle, index, ref value);
         1538  +        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1537   1539   #else
  1538         -        SQLiteErrorCode n = SQLiteErrorCode.Ok;
  1539   1540           throw new NotImplementedException();
  1540   1541   #endif
  1541         -        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1542   1542       }
  1543   1543   
  1544   1544       internal override void Bind_Int32(SQLiteStatement stmt, SQLiteConnectionFlags flags, int index, int value)
  1545   1545       {
  1546   1546           SQLiteStatementHandle handle = stmt._sqlite_stmt;
  1547   1547   
  1548   1548           if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
................................................................................
  1593   1593   #if !PLATFORM_COMPACTFRAMEWORK
  1594   1594           if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
  1595   1595           {
  1596   1596               LogBind(handle, index, value);
  1597   1597           }
  1598   1598   
  1599   1599           SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_int64(handle, index, value);
         1600  +        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1600   1601   #elif !SQLITE_STANDARD
  1601   1602           SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_int64_interop(handle, index, ref value);
         1603  +        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1602   1604   #else
  1603         -        SQLiteErrorCode n = SQLiteErrorCode.Ok;
  1604   1605           throw new NotImplementedException();
  1605   1606   #endif
  1606         -        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1607   1607       }
  1608   1608   
  1609   1609       internal override void Bind_UInt64(SQLiteStatement stmt, SQLiteConnectionFlags flags, int index, ulong value)
  1610   1610       {
  1611   1611           SQLiteStatementHandle handle = stmt._sqlite_stmt;
  1612   1612   
  1613   1613   #if !PLATFORM_COMPACTFRAMEWORK
  1614   1614           if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
  1615   1615           {
  1616   1616               LogBind(handle, index, value);
  1617   1617           }
  1618   1618   
  1619   1619           SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_uint64(handle, index, value);
         1620  +        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1620   1621   #elif !SQLITE_STANDARD
  1621   1622           SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_uint64_interop(handle, index, ref value);
         1623  +        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1622   1624   #else
  1623         -        SQLiteErrorCode n = SQLiteErrorCode.Ok;
  1624   1625           throw new NotImplementedException();
  1625   1626   #endif
  1626         -        if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1627   1627       }
  1628   1628   
  1629   1629       internal override void Bind_Text(SQLiteStatement stmt, SQLiteConnectionFlags flags, int index, string value)
  1630   1630       {
  1631   1631           SQLiteStatementHandle handle = stmt._sqlite_stmt;
  1632   1632   
  1633   1633   #if !PLATFORM_COMPACTFRAMEWORK
................................................................................
  1683   1683   #if !PLATFORM_COMPACTFRAMEWORK
  1684   1684                       if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
  1685   1685                       {
  1686   1686                           LogBind(handle, index, value);
  1687   1687                       }
  1688   1688   
  1689   1689                       SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_int64(handle, index, value);
         1690  +                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
         1691  +                    break;
  1690   1692   #elif !SQLITE_STANDARD
  1691   1693                       SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_int64_interop(handle, index, ref value);
         1694  +                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
         1695  +                    break;
  1692   1696   #else
  1693         -                    SQLiteErrorCode n = SQLiteErrorCode.Ok;
  1694   1697                       throw new NotImplementedException();
  1695   1698   #endif
  1696         -                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1697         -                    break;
  1698   1699                   }
  1699   1700               case SQLiteDateFormats.JulianDay:
  1700   1701                   {
  1701   1702                       double value = ToJulianDay(dt);
  1702   1703   
  1703   1704   #if !PLATFORM_COMPACTFRAMEWORK
  1704   1705                       if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
  1705   1706                       {
  1706   1707                           LogBind(handle, index, value);
  1707   1708                       }
  1708   1709   
  1709   1710                       SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_double(handle, index, value);
         1711  +                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
         1712  +                    break;
  1710   1713   #elif !SQLITE_STANDARD
  1711   1714                       SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_double_interop(handle, index, ref value);
         1715  +                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
         1716  +                    break;
  1712   1717   #else
  1713         -                    SQLiteErrorCode n = SQLiteErrorCode.Ok;
  1714   1718                       throw new NotImplementedException();
  1715   1719   #endif
  1716         -                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1717         -                    break;
  1718   1720                   }
  1719   1721               case SQLiteDateFormats.UnixEpoch:
  1720   1722                   {
  1721   1723                       long value = Convert.ToInt64(dt.Subtract(UnixEpoch).TotalSeconds);
  1722   1724   
  1723   1725   #if !PLATFORM_COMPACTFRAMEWORK
  1724   1726                       if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
  1725   1727                       {
  1726   1728                           LogBind(handle, index, value);
  1727   1729                       }
  1728   1730   
  1729   1731                       SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_int64(handle, index, value);
         1732  +                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
         1733  +                    break;
  1730   1734   #elif !SQLITE_STANDARD
  1731   1735                       SQLiteErrorCode n = UnsafeNativeMethods.sqlite3_bind_int64_interop(handle, index, ref value);
         1736  +                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
         1737  +                    break;
  1732   1738   #else
  1733         -                    SQLiteErrorCode n = SQLiteErrorCode.Ok;
  1734   1739                       throw new NotImplementedException();
  1735   1740   #endif
  1736         -                    if (n != SQLiteErrorCode.Ok) throw new SQLiteException(n, GetLastError());
  1737         -                    break;
  1738   1741                   }
  1739   1742               default:
  1740   1743                   {
  1741   1744                       byte[] b = ToUTF8(dt);
  1742   1745   
  1743   1746   #if !PLATFORM_COMPACTFRAMEWORK
  1744   1747                       if ((flags & SQLiteConnectionFlags.LogBind) == SQLiteConnectionFlags.LogBind)
................................................................................
  1980   1983         notNull = (nnotNull == 1);
  1981   1984         primaryKey = (nprimaryKey == 1);
  1982   1985         autoIncrement = (nautoInc == 1);
  1983   1986       }
  1984   1987   
  1985   1988       internal override double GetDouble(SQLiteStatement stmt, int index)
  1986   1989       {
  1987         -      double value;
  1988   1990   #if !PLATFORM_COMPACTFRAMEWORK
  1989         -      value = UnsafeNativeMethods.sqlite3_column_double(stmt._sqlite_stmt, index);
         1991  +      return UnsafeNativeMethods.sqlite3_column_double(stmt._sqlite_stmt, index);
  1990   1992   #elif !SQLITE_STANDARD
  1991         -      value = 0.0;
         1993  +      double value = 0.0;
  1992   1994         UnsafeNativeMethods.sqlite3_column_double_interop(stmt._sqlite_stmt, index, ref value);
         1995  +      return value;
  1993   1996   #else
  1994   1997         throw new NotImplementedException();
  1995   1998   #endif
  1996         -      return value;
  1997   1999       }
  1998   2000   
  1999   2001       internal override sbyte GetSByte(SQLiteStatement stmt, int index)
  2000   2002       {
  2001   2003         return unchecked((sbyte)(GetInt32(stmt, index) & byte.MaxValue));
  2002   2004       }
  2003   2005   
................................................................................
  2024   2026       internal override uint GetUInt32(SQLiteStatement stmt, int index)
  2025   2027       {
  2026   2028         return unchecked((uint)GetInt32(stmt, index));
  2027   2029       }
  2028   2030   
  2029   2031       internal override long GetInt64(SQLiteStatement stmt, int index)
  2030   2032       {
  2031         -      long value;
  2032   2033   #if !PLATFORM_COMPACTFRAMEWORK
  2033         -      value = UnsafeNativeMethods.sqlite3_column_int64(stmt._sqlite_stmt, index);
         2034  +      return UnsafeNativeMethods.sqlite3_column_int64(stmt._sqlite_stmt, index);
  2034   2035   #elif !SQLITE_STANDARD
  2035         -      value = 0;
         2036  +      long value = 0;
  2036   2037         UnsafeNativeMethods.sqlite3_column_int64_interop(stmt._sqlite_stmt, index, ref value);
         2038  +      return value;
  2037   2039   #else
  2038   2040         throw new NotImplementedException();
  2039   2041   #endif
  2040         -      return value;
  2041   2042       }
  2042   2043   
  2043   2044       internal override ulong GetUInt64(SQLiteStatement stmt, int index)
  2044   2045       {
  2045   2046         return unchecked((ulong)GetInt64(stmt, index));
  2046   2047       }
  2047   2048   
................................................................................
  2255   2256         }
  2256   2257   
  2257   2258         return nCopied;
  2258   2259       }
  2259   2260   
  2260   2261       internal override double GetParamValueDouble(IntPtr ptr)
  2261   2262       {
  2262         -      double value;
  2263   2263   #if !PLATFORM_COMPACTFRAMEWORK
  2264         -      value = UnsafeNativeMethods.sqlite3_value_double(ptr);
         2264  +      return UnsafeNativeMethods.sqlite3_value_double(ptr);
  2265   2265   #elif !SQLITE_STANDARD
  2266         -      value = 0.0;
         2266  +      double value = 0.0;
  2267   2267         UnsafeNativeMethods.sqlite3_value_double_interop(ptr, ref value);
         2268  +      return value;
  2268   2269   #else
  2269   2270         throw new NotImplementedException();
  2270   2271   #endif
  2271         -      return value;
  2272   2272       }
  2273   2273   
  2274   2274       internal override int GetParamValueInt32(IntPtr ptr)
  2275   2275       {
  2276   2276         return UnsafeNativeMethods.sqlite3_value_int(ptr);
  2277   2277       }
  2278   2278   
  2279   2279       internal override long GetParamValueInt64(IntPtr ptr)
  2280   2280       {
  2281         -      Int64 value;
  2282   2281   #if !PLATFORM_COMPACTFRAMEWORK
  2283         -      value = UnsafeNativeMethods.sqlite3_value_int64(ptr);
         2282  +      return UnsafeNativeMethods.sqlite3_value_int64(ptr);
  2284   2283   #elif !SQLITE_STANDARD
  2285         -      value = 0;
         2284  +      Int64 value = 0;
  2286   2285         UnsafeNativeMethods.sqlite3_value_int64_interop(ptr, ref value);
         2286  +      return value;
  2287   2287   #else
  2288   2288         throw new NotImplementedException();
  2289   2289   #endif
  2290         -      return value;
  2291   2290       }
  2292   2291   
  2293   2292       internal override string GetParamValueText(IntPtr ptr)
  2294   2293       {
  2295   2294   #if !SQLITE_STANDARD
  2296   2295         int len = 0;
  2297   2296         return UTF8ToString(UnsafeNativeMethods.sqlite3_value_text_interop(ptr, ref len), len);

Changes to System.Data.SQLite/SQLiteBase.cs.

   947    947   
   948    948         /// <summary>
   949    949         /// Prevent this <see cref="SQLiteConnection" /> object instance from
   950    950         /// loading extensions.
   951    951         /// </summary>
   952    952         NoLoadExtension = 0x200,
   953    953   
          954  +#if INTEROP_VIRTUAL_TABLE
   954    955         /// <summary>
   955    956         /// Prevent this <see cref="SQLiteConnection" /> object instance from
   956    957         /// creating virtual table modules.
   957    958         /// </summary>
   958    959         NoCreateModule = 0x400,
          960  +#endif
   959    961   
   960    962         /// <summary>
   961    963         /// Skip binding any functions provided by other managed assemblies when
   962    964         /// opening the connection.
   963    965         /// </summary>
   964    966         NoBindFunctions = 0x800,
   965    967   
          968  +#if INTEROP_VIRTUAL_TABLE
   966    969         /// <summary>
   967    970         /// Skip setting the logging related properties of the
   968    971         /// <see cref="SQLiteModule" /> object instance that was passed to
   969    972         /// the <see cref="SQLiteConnection.CreateModule" /> method.
   970    973         /// </summary>
   971    974         NoLogModule = 0x1000,
   972    975   
................................................................................
   977    980         LogModuleError = 0x2000,
   978    981   
   979    982         /// <summary>
   980    983         /// Enable logging of certain virtual table module exceptions that cannot
   981    984         /// be easily discovered via other means.
   982    985         /// </summary>
   983    986         LogModuleException = 0x4000,
          987  +#endif
   984    988   
   985    989         /// <summary>
   986    990         /// Enable tracing of potentially important [non-fatal] error conditions
   987    991         /// that cannot be easily reported through other means.
   988    992         /// </summary>
   989    993         TraceWarning = 0x8000,
   990    994   
................................................................................
  1161   1165         /// </summary>
  1162   1166         ConvertAndBindAndGetAllAsInvariantText = BindAndGetAllAsText |
  1163   1167                                                  ConvertAndBindInvariantText,
  1164   1168   
  1165   1169         /// <summary>
  1166   1170         /// Enable all logging.
  1167   1171         /// </summary>
         1172  +#if INTEROP_VIRTUAL_TABLE
  1168   1173         LogAll = LogPrepare | LogPreBind | LogBind |
  1169   1174                  LogCallbackException | LogBackup | LogModuleError |
  1170   1175                  LogModuleException,
         1176  +#else
         1177  +      LogAll = LogPrepare | LogPreBind | LogBind |
         1178  +               LogCallbackException | LogBackup,
         1179  +#endif
  1171   1180   
  1172   1181         /// <summary>
  1173   1182         /// The default extra flags for new connections.
  1174   1183         /// </summary>
         1184  +#if INTEROP_VIRTUAL_TABLE
  1175   1185         Default = LogCallbackException | LogModuleException,
         1186  +#else
         1187  +      Default = LogCallbackException,
         1188  +#endif
  1176   1189   
  1177   1190         /// <summary>
  1178   1191         /// The default extra flags for new connections with all logging enabled.
  1179   1192         /// </summary>
  1180   1193         DefaultAndLogAll = Default | LogAll
  1181   1194     }
  1182   1195   

Changes to System.Data.SQLite/SQLiteConnection.cs.

   803    803       /// <param name="connectionString">The connection string to use.</param>
   804    804       public SQLiteConnection(string connectionString)
   805    805           : this(connectionString, false)
   806    806       {
   807    807           // do nothing.
   808    808       }
   809    809   
          810  +#if INTEROP_VIRTUAL_TABLE
   810    811       /// <summary>
   811    812       /// Initializes the connection with a pre-existing native connection handle.
   812    813       /// This constructor overload is intended to be used only by the private
   813    814       /// <see cref="SQLiteModule.CreateOrConnect" /> method.
   814    815       /// </summary>
   815    816       /// <param name="db">
   816    817       /// The native connection handle to use.
................................................................................
   832    833           _flags = SQLiteConnectionFlags.None;
   833    834   
   834    835           _connectionState = (db != IntPtr.Zero) ?
   835    836               ConnectionState.Open : ConnectionState.Closed;
   836    837   
   837    838           _connectionString = null; /* unknown */
   838    839       }
          840  +#endif
   839    841   
   840    842       /// <summary>
   841    843       /// Initializes the connection with the specified connection string.
   842    844       /// </summary>
   843    845       /// <param name="connectionString">
   844    846       /// The connection string to use.
   845    847       /// </param>

Changes to testce/TestCases.cs.

   288    288         try { UserCollation(cnn); frm.WriteLine("SUCCESS - UserCollation"); passed++; }
   289    289         catch (Exception) { frm.WriteLine("FAIL - UserCollation"); failed++; }
   290    290   
   291    291         total++;
   292    292         try { Int64Properties(cnn); frm.WriteLine("SUCCESS - Int64Properties"); passed++; }
   293    293         catch (Exception) { frm.WriteLine("FAIL - Int64Properties"); failed++; }
   294    294   
          295  +#if INTEROP_VIRTUAL_TABLE
   295    296         total++;
   296    297         try { ManagedVirtualTable(cnn); frm.WriteLine("SUCCESS - ManagedVirtualTable"); passed++; }
   297    298         catch (Exception) { frm.WriteLine("FAIL - ManagedVirtualTable"); failed++; }
          299  +#endif
   298    300   
   299    301         total++;
   300    302         try { MultipleThreadStress(cnn); frm.WriteLine("SUCCESS - MultipleThreadStress"); passed++; }
   301    303         catch (Exception) { frm.WriteLine("FAIL - MultipleThreadStress"); failed++; }
   302    304   
   303    305         total++;
   304    306         try { SimpleRTree(cnn); frm.WriteLine("SUCCESS - SimpleRTree"); passed++; }
................................................................................
  1035   1037   
  1036   1038               return;
  1037   1039           }
  1038   1040   
  1039   1041           throw new NotSupportedException("not a SQLite connection");
  1040   1042       }
  1041   1043   
         1044  +#if INTEROP_VIRTUAL_TABLE
  1042   1045       // Make sure that managed virtual table support works on the .NET Compact Framework.
  1043   1046       internal void ManagedVirtualTable(DbConnection cnn)
  1044   1047       {
  1045   1048           SQLiteConnection cnn2 = cnn as SQLiteConnection;
  1046   1049   
  1047   1050           if (cnn2 != null)
  1048   1051           {
................................................................................
  1095   1098               }
  1096   1099   
  1097   1100               return;
  1098   1101           }
  1099   1102   
  1100   1103           throw new NotSupportedException("not a SQLite connection");
  1101   1104       }
         1105  +#endif
  1102   1106   
  1103   1107       private int nextId = 0;
  1104   1108       private const int MAX_THREADS = 3;
  1105   1109       private const int MAX_ITERATIONS = 100;
  1106   1110       private ManualResetEvent goEvent = new ManualResetEvent(false);
  1107   1111   
  1108   1112       private static int GetThreadId()

Changes to testce/testce.2005.csproj.

   101    101     </ItemGroup>
   102    102     <ItemGroup>
   103    103       <ProjectReference Include="..\System.Data.SQLite\System.Data.SQLite.Compact.2005.csproj">
   104    104         <Project>{AC139951-261A-4463-B6FA-AEBC25283A66}</Project>
   105    105         <Name>System.Data.SQLite.Compact.2005</Name>
   106    106       </ProjectReference>
   107    107     </ItemGroup>
          108  +  <Import Project="$(SQLiteNetDir)\System.Data.SQLite\Targets\System.Data.SQLite.Properties.targets" />
   108    109     <Import Condition="'$(TargetFrameworkVersion)' == 'v1.0'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.v1.targets" />
   109    110     <Import Condition="'$(TargetFrameworkVersion)' == 'v2.0'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
   110    111     <Import Condition="'$(TargetFrameworkVersion)' == 'v3.5'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
   111    112     <ProjectExtensions>
   112    113       <VisualStudio>
   113    114         <FlavorProperties GUID="{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}">
   114    115           <HostingProcess disable="1" />
   115    116         </FlavorProperties>
   116    117       </VisualStudio>
   117    118     </ProjectExtensions>
   118    119   </Project>

Changes to testce/testce.2008.csproj.

   102    102     </ItemGroup>
   103    103     <ItemGroup>
   104    104       <ProjectReference Include="..\System.Data.SQLite\System.Data.SQLite.Compact.2008.csproj">
   105    105         <Project>{AC139951-261A-4463-B6FA-AEBC25283A66}</Project>
   106    106         <Name>System.Data.SQLite.Compact.2008</Name>
   107    107       </ProjectReference>
   108    108     </ItemGroup>
          109  +  <Import Project="$(SQLiteNetDir)\System.Data.SQLite\Targets\System.Data.SQLite.Properties.targets" />
   109    110     <Import Condition="'$(TargetFrameworkVersion)' == 'v1.0'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.v1.targets" />
   110    111     <Import Condition="'$(TargetFrameworkVersion)' == 'v2.0'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
   111    112     <Import Condition="'$(TargetFrameworkVersion)' == 'v3.5'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
   112    113     <ProjectExtensions>
   113    114       <VisualStudio>
   114    115         <FlavorProperties GUID="{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}">
   115    116           <HostingProcess disable="1" />
   116    117         </FlavorProperties>
   117    118       </VisualStudio>
   118    119     </ProjectExtensions>
   119    120   </Project>

Changes to testce/testce.2012.csproj.

    86     86     </ItemGroup>
    87     87     <ItemGroup>
    88     88       <ProjectReference Include="..\System.Data.SQLite\System.Data.SQLite.Compact.2012.csproj">
    89     89         <Project>{AC139951-261A-4463-B6FA-AEBC25283A66}</Project>
    90     90         <Name>System.Data.SQLite.Compact.2012</Name>
    91     91       </ProjectReference>
    92     92     </ItemGroup>
           93  +  <Import Project="$(SQLiteNetDir)\System.Data.SQLite\Targets\System.Data.SQLite.Properties.targets" />
    93     94     <Import Condition="'$(TargetFrameworkVersion)' == 'v1.0'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.v1.targets" />
    94     95     <Import Condition="'$(TargetFrameworkVersion)' == 'v2.0'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
    95     96     <Import Condition="'$(TargetFrameworkVersion)' == 'v3.5'" Project="$(MSBuildBinPath)\Microsoft.CompactFramework.CSharp.targets" />
    96     97     <Import Project="$(MSBuildExtensionsPath)\Microsoft\$(TargetFrameworkIdentifier)\v8.0\Microsoft.$(TargetFrameworkIdentifier).CSharp.targets" />
    97     98     <ProjectExtensions>
    98     99       <VisualStudio>
    99    100         <FlavorProperties GUID="{fae04ec0-301f-11d3-bf4b-00c04f79efbc}">
   100    101           <HostingProcess disable="1" />
   101    102         </FlavorProperties>
   102    103       </VisualStudio>
   103    104     </ProjectExtensions>
   104    105   </Project>

Changes to testlinq/Program.cs.

    90     90   
    91     91                         return SkipTest(pageSize);
    92     92                     }
    93     93                 case "substring":
    94     94                     {
    95     95                         return SubStringTest();
    96     96                     }
           97  +#if USE_INTEROP_DLL && INTEROP_EXTENSION_FUNCTIONS
    97     98                 case "unionall":
    98     99                     {
    99    100                         return UnionAllTest();
   100    101                     }
          102  +#endif
   101    103                 case "endswith":
   102    104                     {
   103    105                         string value = null;
   104    106   
   105    107                         if (args.Length > 1)
   106    108                         {
   107    109                             value = args[1];
................................................................................
   364    366                     once = true;
   365    367                 }
   366    368             }
   367    369   
   368    370             return 0;
   369    371         }
   370    372   
          373  +#if USE_INTEROP_DLL && INTEROP_EXTENSION_FUNCTIONS
   371    374         //
   372    375         // NOTE: Used to test the fix for ticket [0a32885109].
   373    376         //
   374    377         private static int UnionAllTest()
   375    378         {
   376    379             using (northwindEFEntities db = new northwindEFEntities())
   377    380             {
................................................................................
   434    437                     Console.Write(customer.CustomerID);
   435    438                     once = true;
   436    439                 }
   437    440             }
   438    441   
   439    442             return 0;
   440    443         }
          444  +#endif
   441    445   
   442    446         //
   443    447         // NOTE: Used to test the fix for ticket [ccfa69fc32].
   444    448         //
   445    449         private static int EFTransactionTest(bool add)
   446    450         {
   447    451             //
................................................................................
   555    559         //
   556    560         // NOTE: Used to test the INSERT fix (i.e. an extra semi-colon in
   557    561         //       the SQL statement after the actual INSERT statement in
   558    562         //       the follow-up SELECT statement).
   559    563         //
   560    564         private static int InsertTest()
   561    565         {
   562         -          long[] orderIds = new long[] {
   563         -              0
   564         -          };
   565         -
   566    566             using (northwindEFEntities db = new northwindEFEntities())
   567    567             {
   568    568                 int[] counts = { 0 };
   569    569   
   570    570                 //
   571    571                 // NOTE: *REQUIRED* This is required so that the
   572    572                 //       Entity Framework is prevented from opening