Home Accessibility Courses Twitter The Mouth Facebook Resources Site Map About Us Contact
 
20.9.2014 - We have just updated our course layouts and descriptions and added our 2015 schedule.


Well House Consultants
You are on the site of Well House Consultants who provide Open Source Training Courses and business hotel accommodation. You are welcome to browse and use our resources subject to our copyright statement and to add in links from your pages to ours.
Other subject areas - resources
Java Resources
Well House Manor Resources
Perl Resources
Python Resources
PHP Resources
Object Orientation and General topics
MySQL Resources
Linux / LAMP / Tomcat Resources
Well House Consultants Resources
Extras Resources
C and C++ Resources
Ruby Resources
Tcl/Tk Resources
Web and Intranet Resources
MySQL module S156
Interfacing Applications to MySQL Databases
Exercises, examples and other material relating to training module S156. This topic is presented on public courses MySQL, Extra Day

Structured Query Language is, as its name implies, a programming language. Application programs send commands in SQL to the relational database and also provide the application's user interface. In other words, they provide the glue between the application user and the database. Such programs can be written in a variety of languages including C, PHP, Java and Perl.

Related technical and longer articles
MySQL version 5, PHP version 5 and mysqli
MySQL and PHP - enquiry tool for ad-hoc requirements
MySQL and PHP - enquiry tool for ad-hoc requirements
Interfacing applications to a MySQL database engine
Accessing a MySQL database via a browser, Perl and CGI

Articles and tips on this subjectupdated
1561Uploading to a MySQL database through PHP - examples and common questions
One of the most popular pages on the technical part of our web site relates to the uploading of images to a server from a local disc file via a browser, then storing those images on a database, and displaying them later. Another popular page relates to the same thing with .pdf file - and really the ...
2013-01-02
 
3455MySQL, MySQLi, PDO or something else - how best to talk to databases from PHP
One of the consideration that users of Open Source programming languages have make is which one of many ways to do any particular task. Open Source tends to result in lots of very clever facilities being provided, many of which overlap in their use, and many modules being provided via libraries such ...
2011-09-24
 
3447Needle in a haystack - finding the web server overload
*Something* on our web server has been causing the loading to rocket a couple of times a day recently, and it's been a bit of a problem to find out what that something is. Rather like searching for a needle in a haystack - except that when you find something that you think may be the problem, you can't ...
2011-09-18
 
3099Perl - database access - DBD, DBI and DBIx modules
Perl's DBI module provides an excellent link from SQL databases to Perl, and the assorted DBD modules that fit underneath it allow it to operate well for a whole lot of different databases. But they are only excellent as far as they go - for the SQL statements have to be generated in your application ...
2010-12-24
 
3035How to display information from a database within a web page
Are you displaying data that's held in an SQL database from within your own PHP program for the first time? Perhaps you have access to a database that's setup / implemented through a standard open source application such as phpBB, the Simple Machines Forum, or Movable Type or be a colleague? Here ...
2010-11-07
 
2790Joining a MySQL table from within a Python program
Python is a big subject. MySQL is a big subject. Yet the two fin so well together that they can be firmly linked, and work well together, using the tiniest drops of glue. I've provided examples here before, but in answer to a request from a recent delegate, I've just added a fresh example onto our ...
2010-06-02
 
2745Connecting Python to sqlite and MySQL databases
For developing a Python application, and for light use, the SQLite database may be a good choice ... but then you may want to be able to expand the system to use a central database with a more classic server such as MySQL at a later date. Using Polymorphism in Python, and with a careful choice of which ...
2010-04-28
 
2381Checking the database connection manually
For an initial database connectivity test from my own code, I use the mysql client program and 'check out' the commands manually through that. Noting all the parameters, I then check through a piece of code in my target language ... in this brief example from Wednesday, it was Perl: use DBI;   # ...
2009-08-28
 
2263Mysqldump fails as a cron job - a work around
Here's a curiosity ... running a mysqldump as a crontab job, nothing happens on one of our servers. Now I HAVE included the full path to the executable file in my crontab line, and I have redirected the output to a full path ... so something else is tripping it up. What do I do? An Internet search ...
2009-07-01
 
1885Hiding a MySQL database behind a web page
"Keep the browser simple - with a single route in (http) to a server." That's the philosophy behind the web and one of the things that's made it a huge success. It means that a straightforward browser can contact a single server, and Joe Public, Joan Whiting and Mahatma Ali can all view content. But ...
2008-11-16
 
104mysql_connect or mysql_pconnect in PHP?
If you're connecting to a MySQL database in your PHP application, you'll find that there are two alternative connections - mysql_connect which establishes a new connection "each time" and mysql_pconnect which uses persistent connections. Which should you use? Mysql_connect opens a new connection each ...
2008-05-11
 
1518Downloading data for use in Excel (from PHP / MySQL)
Requirement: To allow a visitor to your web site to click on a link that downloads data from the server into a Microsoft Excel spreadhseet. Solutions - I'm going to offer you two: a) To send the output as a text file - delimited by tabs between columns, and with new lines for each new line. Add appropriate ...
2008-01-25
 
1450Easy selection of multiple SQL conditions from PHP
Are you automating an SQL query in a web page, wanting to select records to display only where they match a whole series of criteria from what could be a long list of options - for example looking for houses: * Only in Melksham * Less that 200k * With a large garden and other criteria that perhaps ...
2007-11-30
 
1381Using a MySQL database to control mod_rewrite via PHP
Question: How can I set up Apache httpd / mod_proxy to use a program rather that a list of URL patterns to control my rewrites? Specify a rewrite map type prg in your httpd.conf or .htaccess file. For example: RewriteEngine On RewriteMap tryme prg:/home/trainee/website/andy RewriteRule (.*\.htm) ${tryme:$1} Question: ...
2007-10-05
 
644Using a MySQL database from Perl
Both Perl and MySQL are major pieces of open source software with a multitude of facilities available - yet you can use them together with just a tiny piece of software "glue" - the DBI and DBD::MySQL module pair from the CPAN (comprehensive Perl archive network). Once you've got Perl and MySQL installed, ...
2006-06-09
 
663Python to MySQL
We've added some Python to MySQL connection examples on our web site - using the mysql-python open source download from sourceforge. For the installation, you MUST ensure that you have the MySQL include files and libraries installed before you attempt a build, and that you set your PATH to point to ...
2006-06-05
 
723Viewing images held in a MySQL database via PHP
LOTS of questions on this at the moment. We have a couple of sample scripts that do it - have a look at: * feeder.php which adds images into a database if they've been uploaded as plain text files, displays them from the database if that's where they are already, and generates a rather more informative ...
2006-05-17
 
Examples from our training material
mkexcel.php   Returning data from a database via a URL as an excel spread sheet in PHP
mkexcel2.php   Returning data, opening Excel including formulas, from PHP
mqxyz.php   Simple demo of PHP table from SQL
t1.php4   PHP table insert into two tables / join / enquire
t1.sql   create tables for t1 demo
Background information
This module is available under an Open Training Notes License for free download from http://www.training-notes.co.uk.
Topics covered in this module
Interfacing MySQL to Perl.
The Perl program in detail.
A Further Example.
Interfacing MySQL to PHP.
Interfacing MySQL to Java.
Interfacing MySQL to Tcl/Tk.
Interfacing MySQL to C.
When should I choose MySQL?.
Brief comparisons.
Limitations of MySQL, and work-arounds.
subselects.
transactions and commit/rollback.
Foreign keys and referential Integrity.
Stored procedures and triggers.
Views.
Record level privileges and locking.
Why are the limitations not always limitations?.
Complete learning
If you are looking for a complete course and not just a information on a single subject, visit our Listing and schedule page.

Well House Consultants specialise in training courses in Python, Perl, PHP, and MySQL. We run Private Courses throughout the UK (and beyond for longer courses), and Public Courses at our training centre in Melksham, Wiltshire, England. It's surprisingly cost effective to come on our public courses - even if you live in a different country or continent to us.

We have a technical library of over 700 books on the subjects on which we teach. These books are available for reference at our training centre. Also available is the Opentalk Forum for discussion of technical questions.


You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2014: Well House Manor • 48 Spa Road • Melksham, Wiltshire • United Kingdom • SN12 7NY
PH: 01144 1225 708225 • FAX: 01144 1225 899360 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho

PAGE: http://www.wellho.net/resources/S156.html • PAGE BUILT: Thu Sep 18 11:03:17 2014 • BUILD SYSTEM: WomanWithCat