On Wed, Feb 16, 2011 at 4:56 PM, Hailiang Shen <[email protected]> wrote:

> Dear All,
>
> I am trying to apply multiple threads with sqlite to just query (no insert,
> update, delete operation) to compute objective values in optimization. But
> I
> cannot get it correct. I compiled pthread to a dll for use with sqlite in
> VC++. I am using separate database connection for each thread.
>

Using threads is like running with scissors - You are likely to get hurt and
so the best approach is to not do it.

If you want to run queries in parallel, I suggest putting each query in a
separate process.

If your knowledge of threads is so limited that you don't know how to enable
them and you are trying to use pthreads on windows, then your chances of
getting hurt are compounded.  This is all the more reason to use separate
processes, not threads, for parallelism.


>
>
>
> Any sample codes would be best.
>
>
>
> Thanks,
>
> Hailiang
>
>
>
> /**********************/
>
> Hailiang Shen
>
> Ph.D. Candidate
>
> Water Resources Engineering
>
> University of Guelph
>
> 315,  Engineering bldg.
>
>
>
> _______________________________________________
> sqlite-users mailing list
> [email protected]
> http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users
>



-- 
D. Richard Hipp
[email protected]
_______________________________________________
sqlite-users mailing list
[email protected]
http://sqlite.org:8080/cgi-bin/mailman/listinfo/sqlite-users

Reply via email to