Title: Web access to RDBMS using ODBC Open Database Connectivity
1Web access to RDBMS using ODBC (Open Database
Connectivity)
Filbert Minj National Centre for Science
Information (NCSI)Indian Institute of Science
Bangalore - 560 012 (E-Mail filbert_at_ncsi.iisc.er
net.in)
2Web access to RDBMS using ODBC (Open Database
Connectivity)
- ODBC is a standardized API (Application
Programming Interface) - ODBC provides a robust set of functions for
access to a database. - ODBC is a function set that provides an interface
that is portable to multiple platforms and RDBMSs - Web access to RDBMS is basically for Structured
Database
IISc 22-26 Nov99
IIRML P18
2
3Software Requirements (Windows platform only)
- Windows95/98, Windows NT with Web Browser
- RDBMS
- ODBC Driver for that RDBMS
- Web Server
- CGI Program
- Client Server Architecture
IISc 22-26 Nov99
IIRML P18
3
4IISc 22-26 Nov99
IIRML P18
4
5Web access to FoxPro Database
- Basic steps
- Create FoxPro Database
- Create data source using ODBC administrator
- Double click Start/Control Panel/ODBC Data
Sources (32bit) - Click System DSN tab then Add button
IISc 22-26 Nov99
IIRML P18
5
6IISc 22-26 Nov99
IIRML P18
6
7- Choose the ODBC Driver and press Finish button
IISc 22-26 Nov99
IIRML P18
7
8Give new Data Source Name, Description and path
of the Database then press OK
IISc 22-26 Nov99
IIRML P18
8
9To Configure Connection press File DSN tab, Add,
choose Driver and give same data source as System
DSN
IISc 22-26 Nov99
IIRML P18
9
10Give the path of the database
IISc 22-26 Nov99
IIRML P18
10
11Web access to FoxPro Database Cont
- If no error then done
- Create HTML file with forms where ACTION
attribute points a CGI program. - Put HTML file in document root directory of the
web server - Write CGI program
- Put CGI program in script alias directory
(CGI-BIN usually)
IISc 22-26 Nov99
IIRML P18
11
12For Demo
- Microsoft Personal Web Server is used
- C\WEBSHARE\WWWROOT is the (default) document
root directory - C\WEBSHARE\SCRIPTS is the (default) directory
where executables (CGI programs) reside - Active Perl is used for writing CGI program
IISc 22-26 Nov99
IIRML P18
12
13For Demo Cont
- It is installed in
- C\PERL\BIN - executables
- C\PERL\LIB and C\PERL\SITE\LIB - library files
- ODBC.pm (perl module) and ODBC.PLL files are
needed for writing CGI program using ODBC - These files are in C\PERL\LIB or
C\PERL\SITE\LIBÂ directory - Microsoft Visual FoxPro is used for creating
database
IISc 22-26 Nov99
IIRML P18
13
14For Demo
- Table book with the following fields have been
created - Title char (200)
- Author char (50)
- Pub_year char (4)
- Publisher char (20)
- Acc_no char (10)
- Language char (10) with Acc_no as a primary key
IISc 22-26 Nov99
IIRML P18
14
15Demo Follows
IISc 22-26 Nov99
IIRML P18
15