[Implemented] Add SQLite as a standard PB library

Got an idea for enhancing PureBasic? New command(s) you'd like to see?
USCode
Addict
Addict
Posts: 923
Joined: Wed Mar 24, 2004 11:04 pm
Location: Seattle

[Implemented] Add SQLite as a standard PB library

Post by USCode »

:idea: Add SQLite as a standard PB library.

A local SQL DB library for PB that can be linked directly into the executable would be very handy!

With SQLite's very liberal license and source code availability, this could be done.

Discussion on making SQLite a PB library:
viewtopic.php?t=11499&highlight=
kake26
Enthusiast
Enthusiast
Posts: 157
Joined: Sun Jan 25, 2004 7:21 pm
Contact:

Post by kake26 »

I totally agree. I'm writting my own binding and I will make it avail once I'm done and yes I'm doing it in nothing but PB. USCode, if you want a copy when I'm done lemme know I'll send source. I have at least 2 other people wanting a copy too so I figure why not pass it out.
Shannara
Addict
Addict
Posts: 1808
Joined: Thu Oct 30, 2003 11:19 pm
Location: Emerald Cove, Unformed

Post by Shannara »

I am interested in a copy as well :)
User avatar
NoahPhense
Addict
Addict
Posts: 1999
Joined: Thu Oct 16, 2003 8:30 pm
Location: North Florida

Re: Add SQLite as a standard PB library

Post by NoahPhense »

What, no PBDB?! ;)

geesh..

- np
kake26
Enthusiast
Enthusiast
Posts: 157
Joined: Sun Jan 25, 2004 7:21 pm
Contact:

Post by kake26 »

Well, SQLite is cool and there are ODBC drivers for it, but that defeats the purpose. I can write to a DB as of now, but I cannot retrieve results. These damn pointers to pointers are a problem for me I must resolve.
kake26
Enthusiast
Enthusiast
Posts: 157
Joined: Sun Jan 25, 2004 7:21 pm
Contact:

Post by kake26 »

@NoahPhense: (EL kicks ass) , yes that he does. He's helped me with the SQLite once already I may need to ask him again a few things. Once its done I'll use tailbite and make a PureLib from it and distribute that and its source.
User avatar
NoahPhense
Addict
Addict
Posts: 1999
Joined: Thu Oct 16, 2003 8:30 pm
Location: North Florida

..

Post by NoahPhense »

I'm surprised he's not in here as he's already developing a library:

viewtopic.php?t=10724

- np
kake26
Enthusiast
Enthusiast
Posts: 157
Joined: Sun Jan 25, 2004 7:21 pm
Contact:

Post by kake26 »

I know he does it all in ASM which not many people understand. I want to make it in normal purebasic so people have a clue of what I'm doing with the SQLite DLL file.
El_Choni
TailBite Expert
TailBite Expert
Posts: 1007
Joined: Fri Apr 25, 2003 6:09 pm
Location: Spain

Post by El_Choni »

Hi, I was away for a few days. I can help you if you want. However, I can't develop nor test anything these days because I'm at my brother's computer.

Regards,
El_Choni
User avatar
NoahPhense
Addict
Addict
Posts: 1999
Joined: Thu Oct 16, 2003 8:30 pm
Location: North Florida

..

Post by NoahPhense »

kake26 wrote:I know he does it all in ASM which not many people understand. I want to make it in normal purebasic so people have a clue of what I'm doing with the SQLite DLL file.
Ah.. but in the end, it's still standard PB lib with standard PB commands right?

Code: Select all

Person.s = "Smith, John" 
SQLiteExec("INSERT INTO StatusTable VALUES('" + Person + "','OUT','')") 
I'm not trying to discourage you. By all means, this would be an excellent
learning process.

Shoot, that's all I do in here is learn.. maybe I should get back to my todo
list.. ;)

- np
kake26
Enthusiast
Enthusiast
Posts: 157
Joined: Sun Jan 25, 2004 7:21 pm
Contact:

Post by kake26 »

@El_Choni: Yeah, I'm very close to this except the query result stuff since it returns a pointer to a pointer. I'm not sure how to deal with those. I can make thew calls and stuff just fine. I could I not peel the first one then get the addr for the second one and peek that?
Post Reply