Opening SQLite Database

BlitzMax Forums/BlitzMax Programming/Opening SQLite Database

ponyboy(Posted 2008) [#1]
I'm dabbling in the SQLiter mod and I was wondering if it's wise to open the database connection upon intializing your app/game and keep it open throughout the duration, while closing it at the end of the app/game life cycle? Or is it better to open it when you need it, and then close it after your done, resulting in many open and close calls throughout the life cycle of the app/game? Which is better on performance?


DavidDC(Posted 2008) [#2]
Well I'd leave it open personally. Is there any particular reason you'd prefer to close it?


ponyboy(Posted 2008) [#3]
Nope, I'd rather leave it open too. I just wasn't sure if leaving it open was common practice or if there was a right or wrong way.