Got problem with prepare statement in sqlite
-
@SGaist I rearrange my code an it began to work but I have got another problem my working code the code is to slow from user vision (firstly it inserts new records to db table and only than add the row (Add function although) it goes first and returns bool result)
what is your ideas about it
-
You are trying to open your database twice.
Again, like already wrote before: open your connection once at application startup and then just do your queries. You'll avoid losing time with that.
As for performance, what else is your application doing ?
-
You are trying to open your database twice.
Again, like already wrote before: open your connection once at application startup and then just do your queries. You'll avoid losing time with that.
As for performance, what else is your application doing ?
@SGaist I understand you but I failed to do it it doesnt see the db as opened (I opened it in constructor)
-
Then fix your database initialisation in the constructor rather than trying to work around.
-
Then fix your database initialisation in the constructor rather than trying to work around.
@SGaist And what about not line by line code execution?
-
What do you mean by that ?
-
There's no way to evaluate why your application is slow based only on one function.
Do some profiling on your application to understand what takes so much time.
-
There's no way to evaluate why your application is slow based only on one function.
Do some profiling on your application to understand what takes so much time.
@SGaist ADD function must execute first!!! But not
-
Full uppercased words and many exclamation marks are not the best way to communicate when people are trying to help you on their own time.
You are only providing a small part of your code and stating that your users find it slow. I already gave you some suggestions to make it a bit faster but you said that you couldn't make it work in some other unknown part of your code.
Now, how can you expect anybody to provide you with advices based on that ?
-
Full uppercased words and many exclamation marks are not the best way to communicate when people are trying to help you on their own time.
You are only providing a small part of your code and stating that your users find it slow. I already gave you some suggestions to make it a bit faster but you said that you couldn't make it work in some other unknown part of your code.
Now, how can you expect anybody to provide you with advices based on that ?
@SGaist yes you are right sorry