[sqlite] Re: Re: Table Schema

2007-01-20 Thread ivailo91
On Saturday, January 20, 2007, 11:29:51 PM, RB Smissaert wrote: > As said you can run > pragma table_info(table) > in C as a query against the database table and it will give you all the info > you need without any awkward parsing. > RBS > -Original Message- >

Re: [sqlite] SQLite JSON interface?

2007-01-20 Thread Christian Werner
Michael Ruck wrote: > > Hi, > > Is there a JSON interface for SQLite (in C/C++)? Any GPL/LGPL compatible > license or public domain would do. Someone must have written something like > it. I need to export a set of tables to JSON .js files to serve on a > webserver, the files are generated

RE: [sqlite] Re: Table Schema

2007-01-20 Thread RB Smissaert
As said you can run pragma table_info(table) in C as a query against the database table and it will give you all the info you need without any awkward parsing. RBS -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: 20 January 2007 20:05 To: RB Smissaert

[sqlite] SQLite JSON interface?

2007-01-20 Thread Michael Ruck
Hi, Is there a JSON interface for SQLite (in C/C++)? Any GPL/LGPL compatible license or public domain would do. Someone must have written something like it. I need to export a set of tables to JSON .js files to serve on a webserver, the files are generated off-line, not on demand. Michael

RE: [sqlite] Re[2]: Table Schema; 2. Using this list

2007-01-20 Thread RB Smissaert
I need table info all the time and I used to parse the table sqlite_master, but as you say that is a bit of a hassle and I have now switched to using pragma table_info('" & strTable & "') This is a VB function, but you will get the idea: Function GetSQLiteTableInfo(strDB As String, _

Re: [sqlite] Fix for sqlite3.h in version 3.3.10

2007-01-20 Thread Joe Wilson
> On a related but separate note, is there any standard that guarantees > that casting -1 to a function pointer type is reasonably portable? This idiom is used widely enough to overload an argument so that it can contain either a valid pointer, or convey a non-pointer state. Take

Re: [sqlite] Fix for sqlite3.h in version 3.3.10

2007-01-20 Thread drh
"James Dennett" <[EMAIL PROTECTED]> wrote: > > On a related but separate note, is there any standard that guarantees > that casting -1 to a function pointer type is reasonably portable? My > experience is that it doesn't cause problems, but certainly it's not > portable C or C++ from the

Re: [sqlite] 1. Table Schema; 2. Using this list

2007-01-20 Thread P Kishor
On 1/20/07, Thomas Fjellstrom <[EMAIL PROTECTED]> wrote: On Saturday 20 January 2007 6:29 am, [EMAIL PROTECTED] wrote: > Mark Richards wrote: > > [EMAIL PROTECTED] wrote: .. > > 2. How am i supposed to write replies to someone's post in this mailing > list? Actually, the Reply-To: header is

Re: [sqlite] 1. Table Schema; 2. Using this list

2007-01-20 Thread Thomas Fjellstrom
On Saturday 20 January 2007 6:29 am, [EMAIL PROTECTED] wrote: > Mark Richards wrote: > > [EMAIL PROTECTED] wrote: > > > What is the easiest way to retrieve the structure of a table? The only > > > thing i have found so far is by parsing the `sqlite_master`.`sql` > > > which seems to be too much

[sqlite] SQLite via Mac AppleScript (was: pipe or redirect a series of commands)

2007-01-20 Thread T
Hi again Bill, Following up on: OSX comes with sqlite already installed. A guy named "Adam Bell" wrote a sample AppleScript that showed how to access sqlite, create, search, modify, etc from within AppleScript issuing the commands directly to any one of the Unix Shells. Basically I can

[sqlite] AppleScript and shell script series of commands (was: pipe or redirect a series of commands)

2007-01-20 Thread T
Hi Bill, It's great to see a fellow AppleScript programmer here on the SQLite discussion list. I tried finding a pragma command for .headers on, but didn't have any luck. As I understand it, the .headers (and other dot commands) only affect the sqlite3 shell command output, so

[sqlite] 1. Table Schema; 2. Using this list

2007-01-20 Thread ivailo91
Mark Richards wrote: > [EMAIL PROTECTED] wrote: > > What is the easiest way to retrieve the structure of a table? The only > > thing i have found so far is by parsing the `sqlite_master`.`sql` > > which seems to be too much coding. I want them as (char** > > column_names), (char **column_types) or

Re: [sqlite] Retrieve Table Structure

2007-01-20 Thread Mark Richards
[EMAIL PROTECTED] wrote: What is the easiest way to retrieve the structure of a table? The only thing i have found so far is by parsing the `sqlite_master`.`sql` which seems to be too much coding. I want them as (char** column_names), (char **column_types) or something similar. thanks in advance

[sqlite] Retrieve Table Structure

2007-01-20 Thread ivailo91
What is the easiest way to retrieve the structure of a table? The only thing i have found so far is by parsing the `sqlite_master`.`sql` which seems to be too much coding. I want them as (char** column_names), (char **column_types) or something similar. thanks in advance Ivailo Karamanolev