SQL connection closed?

kanaida

Active Member
Licensed User
Longtime User
Im trying to make business objects like .net with save/load built in. I have a context class that holds a reference to SQL in process globals. My object classes have initializers with context as a parameter so i can always easily access its sql object reference.

My problem is after initializing sql, creating its table, inserting default records, the next line gets all those objects with a select * from table. However it tells me connection 0 is closed. I never closed it though... and there is no sql.open() so im not sure what went wrong exactly. I want to just keep it open until it gets destroyed or paused. Then reconnect and re-read values on load.

Sent from my LG-MS840 using Tapatalk 2
 
Last edited:

kanaida

Active Member
Licensed User
Longtime User
You're da man lol... :D I couldn't find it cause it was like 4am and my eyes were too fuzzy to see it.

Sure enough, in a sub of a sub of another sub there was a close. I overlooked it because I thought it was the cursor variable and I was done with the results :)
 
Upvote 0
Top