summaryrefslogtreecommitdiffstats
path: root/examples/sql/sqltable/README
blob: 701458835372fcb7f6e6cb0888dcf14b951f6fa7 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
This SQL table example retquires a connection to a SQL database.
Modify main.cpp to connect to your specific database.  

This example program expects a table called 'simpletable' to exist in
the database.  You can create this table by running the following SQL
script (modify to suit your backend, if necessary):

drop table simpletable;
create table simpletable
(id number primary key,
name varchar(20),
address varchar(20) );

-- optional, some sample data
insert into simpletable (id, name, address)
values (1, 'Trond', 'Oslo');
insert into simpletable (id, name, address)
values (2, 'Dave', 'Oslo');