RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread RB Smissaert
@sqlite.org Subject: Re: [sqlite] How do I know sqlite_get_table is finished > The function ArrayToSheet has nil to do with SQLite and I left that out. Ah, but that's where you access the variant array. That can be tricksy. Do you always access that variant array (arr) in the range

Re: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread Trey Mack
The function ArrayToSheet has nil to do with SQLite and I left that out. Ah, but that's where you access the variant array. That can be tricksy. Do you always access that variant array (arr) in the range (0 To NumRecords, 0 To NumColumns - 1) where the row arr(0, *) holds the column names,

Re: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread Trey Mack
- Original Message - From: "Guy Hachlili" <[EMAIL PROTECTED]> To: <sqlite-users@sqlite.org> Sent: Friday, February 02, 2007 10:13 AM Subject: RE: [sqlite] How do I know sqlite_get_table is finished In any case, I've worked a bit on the function, and here's the

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread bartsmissaert
Thanks for that, will have a look at the altered C code, but not sure yet if I can compile. Just have never done it yet. As I posted earlier I think I have found the trouble. Due to a simple typo I enclosed the queries in that table SQL in double quotes, where it should have been single quotes.

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread Guy Hachlili
Hello. At 14:32 2/2/2007 +, you wrote: lReturnedRows is one of the function arguments, so that is fine. I have made some progress though and that is that this problem only occurs with this particular table, called SQL. It is a table that logs all the SQL statements that run in my app. When

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread bartsmissaert
>> ([STATEMENT_COUNT] INTEGER, >> [DB] TEXT, >> [QUERY_TIME] TEXT, >> [QUERY_LENGTH] REAL, >> [QUERY] TEXT) >> >> Any other ideas what could be wrong with this table? >> >> I could mail a db with that table if that would be helpful. >&g

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread epankoke
> From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] > Sent: 02 February 2007 13:51 > To: sqlite-users@sqlite.org > Subject: RE: [sqlite] How do I know sqlite_get_table is finished > > I'll admit I'm not much of a C expert, so I'd say Guy has a much better > handle on that pa

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread RB Smissaert
with this table? I could mail a db with that table if that would be helpful. RBS -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 02 February 2007 13:51 To: sqlite-users@sqlite.org Subject: RE: [sqlite] How do I know sqlite_get_table is finished I'll admit I'm

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread epankoke
I'll admit I'm not much of a C expert, so I'd say Guy has a much better handle on that part than I do. As far as your code goes I only had one thought, and forgive me if this is just my ignorance of VBA. I didn't see a declaration for lReturnedRows anywhere. If you don't declare a variable,

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread bartsmissaert
Thanks for looking at that. The crash can happen at the actual call to sqlite_get_table or it can happen when I assign the resulting array to the wrapper function, so when I do: GetFromDB = arr Yes, I would be interested in making a boolean (optional) argument in sqlite_get_table that can leave

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-02 Thread Guy Hachlili
At 07:44 2/2/2007 +, you wrote: Sure, here it is: Looking at the C code published at http://www.tannertech.net/sqlite3vb/index.htm , it seems very risky - there are a lot of places it can fail to allocate memory (for example), and the use of some variables looks like it could randomly

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread RB Smissaert
SQLiteTableIsEmpty = True End If If bNoNewConnection = False Then OpenDB strDB, True End If Exit Function ERROROUT: If bNoNewConnection = False Then OpenDB strDB, True End If SQLiteTableIsEmpty = True End Function The function ArrayToSheet has nil to do wit

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread Eric Pankoke
lto:[EMAIL PROTECTED] Sent: Thursday, February 01, 2007 7:06 PM To: sqlite-users@sqlite.org Subject: RE: [sqlite] How do I know sqlite_get_table is finished Good thought, but 1. I set the connection 2. get the array 3. dump it in the sheet 4. and then close the connection. The crash happens at numb

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread RB Smissaert
Hachlili [mailto:[EMAIL PROTECTED] Sent: 01 February 2007 23:50 To: sqlite-users@sqlite.org Subject: RE: [sqlite] How do I know sqlite_get_table is finished Well... At 23:17 2/1/2007 +, you wrote: >Thanks, yes, I somehow didn't think my explanation made sense and in fact I >just had a

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread Guy Hachlili
Well... At 23:17 2/1/2007 +, you wrote: Thanks, yes, I somehow didn't think my explanation made sense and in fact I just had another Excel crash, caused by the same call to sqlite_get_table. I just can't understand why this is happening. There is a valid connection, there is a valid SQL,

RE: [sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread RB Smissaert
@sqlite.org Subject: Re: [sqlite] How do I know sqlite_get_table is finished sqlite_get_table does not terminate unless there is an error or it has retrieved all the records you asked for. Something else must have been causing the error, or the wrapper you are using is not implementing

Re: [sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread epankoke
sqlite_get_table does not terminate unless there is an error or it has retrieved all the records you asked for. Something else must have been causing the error, or the wrapper you are using is not implementing the function call correctly. -- Eric Pankoke Founder / Lead Developer Point Of

[sqlite] How do I know sqlite_get_table is finished

2007-02-01 Thread RB Smissaert
Using the VB wrapper dll SQLite3VB.dll from Todd Tanner's site: http://www.tannertech.net/sqlite3vb/index.htm In one particular procedure I had a serious problem when doing a call to sqlite_get_table, causing Excel to crash. It took me a long time to pinpoint the trouble as VBA debugging methods