> On Thu, Sep 19, 2013 at 4:35 PM, Richard Hipp wrote:
> > On Thu, Sep 19, 2013 at 5:50 PM, Igor Korot
> wrote:
> > > Now, AFAIU, I need to check if the COMMIT is successful.
> > > But what should I do if it fails? Do I just report the failure to
> > >
On Thu, Sep 19, 2013 at 4:35 PM, Richard Hipp wrote:
> On Thu, Sep 19, 2013 at 5:50 PM, Igor Korot wrote:
>
> >
> > Now, AFAIU, I need to check if the COMMIT is successful.
> > But what should I do if it fails? Do I just report the failure to the
> user?
> >
On Thu, Sep 19, 2013 at 5:50 PM, Igor Korot wrote:
>
> Now, AFAIU, I need to check if the COMMIT is successful.
> But what should I do if it fails? Do I just report the failure to the user?
> Do I need to call ROLLBACK? And what if it will also fail?
> And in "else" branch -
Dave Protasowski wrote:
>
> I'm using this library the relevant code snippet is:
> https://github.com/koush/sqlite-net/blob/master/src/SQLite.cs#L150
>
> While debugging I've confirmed that the call to SetDirectory is
> returning SQLITE_OK (0).
>
Are you setting the temporary directory to a
On 9/19/2013 5:43 PM, Igor Korot wrote:
If you do pass a non-NULL pointer as the last parameter, then SQLite would
allocate memory for it. You should then free said memory, or else you leak
it.
Yes, I understand that.
My question was more about re-using the variable between to calls to SQLite.
Hi, ALL,
Consider following piece of code:
int res = sqlite3_exec(..., "BEGIN"... );
if( res != SQLITE_OK )
{
printf( "Error occured on begin transaction. Please try again." );
return;
}
// some operations on the database
// if operations are successful
sqlite3_exec( ...,
Hi, Igor,
On Thu, Sep 19, 2013 at 5:54 AM, Igor Tandetnik wrote:
> On 9/19/2013 2:55 AM, Igor Korot wrote:
>
>> Here is the code I'm trying to use:
>>
>> char *errmsg = NULL;
>> sqlite3_exec( handle, "BEGIN", 0, 0, );
>> if( sqlite3_exec( , ) != SQLITE_OK )
>>
>
> As
> For the first argument to sqlite3_win32_set_directory(), are you passing a
> > value of SQLITE_WIN32_TEMP_DIRECTORY_TYPE (which equals 2)?
Yes
> Is the call to sqlite3_win32_set_directory() being executed prior to
opening
> > the database and is it returning SQLITE_OK?
>
Yes to both
I'm
Hi, Simon,
On Thu, Sep 19, 2013 at 5:16 AM, Simon Slavin wrote:
>
> On 19 Sep 2013, at 9:09am, Stephan Beal wrote:
>
> > What's the
> > difference between and calling sqlite3_errmsg()?
>
> No difference in terms of the result, they're just to cope
After laboriously translating your schema and query into something
readable, I get script shown below.
We (all SQLite developers have been consulted and agree) conclude that the
result of the query is undefined. You are sorting on the rowid of a
subquery. But the rowid of a subquery is
On Wed, 18 Sep 2013 20:53:31 -0700 (PDT), niubao
wrote:
>Thank you very much Simon, for your detailed and very clear explanation on
>this. I wonder if there is some materials, a tutorial or something, that
>are dedicated to SQLite schema change for beginners?
>
>There seems
Dave Protasowski wrote:
>
> I found this page describing how sqlite on Windows RT should set the temp
> file directory. http://www.sqlite.org/c3ref/temp_directory.html
>
> I'm using sqlite3_win32_set_directory method (in C#) to do this but I've
> noticed that in some instances sqlite is still
I have a tool that will do this for you and just about any other schema
changte you can think of while preservbing the data and integrity of your
database. Runs on WIndows and OSX and I could produce a Linux version if
necessary. Check out SQLiteAdmin at www.lcsql.com
Pete
On Thu, Sep 19, 2013
What is the status on this? Is there an official ticket for this so that I
can track the issue without having to look for updates on the mailing list?
Do you need more information from me?
-Jared
___
sqlite-users mailing list
sqlite-users@sqlite.org
On Thu, Sep 19, 2013 at 12:07 PM, Jared Albers wrote:
> What is the status on this? Is there an official ticket for this so that I
> can track the issue without having to look for updates on the mailing list?
>
The status is that I was unable to replicate the problem.
Hey guys,
I found this page describing how sqlite on Windows RT should set the temp
file directory. http://www.sqlite.org/c3ref/temp_directory.html
I'm using sqlite3_win32_set_directory method (in C#) to do this but I've
noticed that in some instances sqlite is still returning cannot open errors
Under normal circumstances only these stmts perform some DB activity:
- BeginTransaction
- ExecuteNonQuery
- Commit
SqliteCommand constructor as well as the following lines (setting parameters
and command text) are memory constructs that prepare data for
ExecuteNonQuery.
If everything works
On 9/19/2013 2:55 AM, Igor Korot wrote:
Here is the code I'm trying to use:
char *errmsg = NULL;
sqlite3_exec( handle, "BEGIN", 0, 0, );
if( sqlite3_exec( , ) != SQLITE_OK )
As you are not checking the return value of the first sqlite3_exec, and
are not using the error message it
On 19 Sep 2013, at 9:09am, Stephan Beal wrote:
> What's the
> difference between and calling sqlite3_errmsg()?
No difference in terms of the result, they're just to cope with two different
programming styles. The function is provided for situations where you have
Stephan,
On Thu, Sep 19, 2013 at 1:09 AM, Stephan Beal wrote:
> On Thu, Sep 19, 2013 at 10:06 AM, Igor Korot wrote:
>
> > OK, so I guess I have to call sqlite3_free().
> > Now, I do have to execute "ROLLBACK" statement, right?
> >
>
> Correct - IMO,
On Thu, Sep 19, 2013 at 10:06 AM, Igor Korot wrote:
> OK, so I guess I have to call sqlite3_free().
> Now, I do have to execute "ROLLBACK" statement, right?
>
Correct - IMO, you have all the pieces in the right place, you just need to
free the errmsg string. (i assume you
Stephan,
On Thu, Sep 19, 2013 at 12:46 AM, Stephan Beal wrote:
> On Thu, Sep 19, 2013 at 8:55 AM, Igor Korot wrote:
>
> > Can I reuse errmsg variable like this or do I have to call sqlite3_free()
>
> and then execute "ROLLBACK" statement?
> >
>
> Per
On Thu, Sep 19, 2013 at 8:55 AM, Igor Korot wrote:
> Can I reuse errmsg variable like this or do I have to call sqlite3_free()
and then execute "ROLLBACK" statement?
>
Per the API docs:
** ^If an error occurs while evaluating the SQL statements passed into
**
Hi, ALL,
Here is the code I'm trying to use:
char *errmsg = NULL;
sqlite3_exec( handle, "BEGIN", 0, 0, );
if( sqlite3_exec( , ) != SQLITE_OK )
{
printf( "Error executing query: %s", sqlite3_errmsg( m_handle ) );
sqlite3_exec( handle, "ROLLBACK", 0, 0, );
}
Can I reuse errmsg
24 matches
Mail list logo