SHARE
Facebook X Pinterest WhatsApp

IBM developerWorks: Integrating database access into Linux applications; Building a MySQL-backed Web site

Written By
thumbnail
Web Webster
Web Webster
Feb 26, 2001

[ Thanks to Shailendra for this link.
]

“This article describes MySQL, a useful tool for developing
e-commerce and other complicated, dynamic Web sites that make use
of third-party databases. MySQL is a fast, multi-threaded, and
fully functional SQL server. In addition to describing the
basic architecture of the MySQL system, this article offers simple
examples in both Tcl and C++ that can start you down the path to
developing database-aware Web applications.”

“Integrating databases into Linux applications can be easy,
using both scripting languages and compiled system languages such
as C. A freely available (released under the Gnu Public License)
database known as MySQL provides a comprehensive set of SQL
functionality, and easily integrates into applications. MySQL is
fast, multi-threaded, and supports the ANSI and ODBC SQL standards.
With the addition of third-party software, MySQL supports
transaction-safe tables for transaction-processing
applications.”

“MySQL APIs are available for a variety of languages, including
almost all languages used in practice to write the back end of a
Web site. Using these APIs, we can build a MySQL client controlled
by the Web server.”

“The APIs (for database access) work on a connection-based
model. The first thing a client must do is open a connection to the
MySQL server. This includes properly authenticating the connection
with a username and password recognized by the server. After
establishing a connection, the server selects the particular
database with which to work. Upon establishing this initialization,
the client application (in our case a server-side CGI script) is
free to interact with the database in one of two ways: It can run
general SQL commands, including adding and deleting tables as well
as adding records to them; or, it can run queries on the database
which returns results. Queries generate a list of records that
match the query, which the client can then access record by record
until either all of the records have been viewed or the client
cancels the pending record retrieval. Once the script completes
working with the database, the connection to the server is
closed.”


Complete Story

thumbnail
Web Webster

Web Webster

Web Webster has more than 20 years of writing and editorial experience in the tech sector. He’s written and edited news, demand generation, user-focused, and thought leadership content for business software solutions, consumer tech, and Linux Today, he edits and writes for a portfolio of tech industry news and analysis websites including webopedia.com, and DatabaseJournal.com.

Recommended for you...

Red Hat reveals major enhancements to Red Hat Enterprise Linux AI
sjvn
Oct 22, 2024
How to Find AWS EC2 Instance Type Over SSH (6 Methods)
Benny Lanco
Sep 23, 2024
Crond: Daemon to Execute Scheduled Commands
Rose Hosting Blog
Sep 20, 2024
A Detailed Introduction to Oracle VirtualBox
Senthil Kumar
Sep 19, 2024
Linux Today Logo

LinuxToday is a trusted, contributor-driven news resource supporting all types of Linux users. Our thriving international community engages with us through social media and frequent content contributions aimed at solving problems ranging from personal computing to enterprise-level IT operations. LinuxToday serves as a home for a community that struggles to find comparable information elsewhere on the web.

Property of TechnologyAdvice. © 2025 TechnologyAdvice. All Rights Reserved

Advertiser Disclosure: Some of the products that appear on this site are from companies from which TechnologyAdvice receives compensation. This compensation may impact how and where products appear on this site including, for example, the order in which they appear. TechnologyAdvice does not include all companies or all types of products available in the marketplace.