google-code-export / dblinq2007

Automatically exported from code.google.com/p/dblinq2007
Other
0 stars 0 forks source link

BulkInsert in SqLite now not implemented #281

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
What steps will reproduce the problem?
1.  Use sqlmetal against an sqlite database
2.  Use  Class.BulkInsert(array of class type)

What is the expected output? What do you see instead?

I expected the array to be inserted.  It threw an exception instead
reaching this piece of code in DBLinq.Vendor.Implementation.Vendor templated on 
my classtype.   I wouldn't be surprised except that I used
this about a year ago happily under sqlite and was impressed with the ease
and speed of bulk inserts.  If it has been uninmplemented for some reason
I can live with that, but want to make sure I'm not doing anything stupid.

public virtual void BulkInsert<T>(Table<T> table, List<T> rows, int pageSize, 
IDbTransaction transaction) where T : class
        {
            throw new NotImplementedException();
        }

What version of the product are you using? On what operating system?

Windows vista,  current SVN as of Sep 1st.

Please provide any additional information below.

>   DbLinq.dll!DbLinq.Vendor.Implementation.Vendor.BulkInsert<EmailDB.DoC>(DbLinq.
Data.Linq.Table<EmailDB.DoC> table = {Table(DoC)}, 
System.Collections.Generic.List<EmailDB.DoC> rows = Count = 260, int pageSize = 
0, System.Data.IDbTransaction transaction = 
{System.Data.SQLite.SQLiteTransaction}) Line 83 + 0x28 bytes    C#
    DbLinq.dll!DbLinq.Data.Linq.Table<EmailDB.DoC>.BulkInsert(System.Collections.Generic.IEnumerable<EmailDB.DoC> entities = {EmailDB.DoC[260]}, int pageSize = 0) Line 81 + 0x1ef bytes    C#
    DbLinq.dll!DbLinq.Data.Linq.Table<EmailDB.DoC>.BulkInsert(System.Collections.Generic.IEnumerable<EmailDB.DoC> entities = {EmailDB.DoC[260]}) Line 68 + 0x36 bytes   C#
    mindex.exe!Mindex.loadOneFolder(EmailDB.Main db = {EmailDB.Main}, string rootPath = "Test1", string p = "Test1\\dating") Line 465   F#
    mindex.exe!Mindex.loadAllFolders@510-3.Invoke(string p = "Test1\\dating") Line 510 + 0x1d bytes F#
    [External Code] 
    mindex.exe!Mindex.loadAllFolders(string mbox = "Test1") Line 505 + 0x19b bytes  F#
    mindex.exe!Mindex.procArgs<Microsoft.FSharp.Core.Unit>(Microsoft.FSharp.Collections.FSharpList<string> args = Length = 1) Line 670 + 0x1a bytes F#
    mindex.exe!<StartupCode$mindex>.$Mindex.main@() Line 676 + 0x2d bytes   F#

Original issue reported on code.google.com by dagg...@gmail.com on 1 Sep 2010 at 8:24

GoogleCodeExporter commented 9 years ago
Sorry, brain fart - the previous project was using MySQL not sqlite which I'm 
assuming is why it worked.  I guess I'll have to implement bulk insert for 
sqlite :(

Original comment by dagg...@gmail.com on 1 Sep 2010 at 8:37