Hi folks...
As part of an assignment, I have to design and implement a fairly
small MYSQL 4.0.17 database for a fictitious travel agency. This
database will store data from customers submitting it through
application forms. I will test my implementation on an old Linux box
(RedHat 6.x with PHP 4.0.5 and MySQL 4.0.17, running on an AMD
processor and 64MB of memory).
Each APPLICATION form will have 4 parts:
- PASSENGER details: name, surname, etc.
- CONTACT details: phone number(s), postal and e-mail addresses
- INFORMATION on the trip: departure and return dates, etc.
- CONTROL data: agency-specific (e.g., booking operator)
If I put all the above information into 1 table, APPLICATION, it will
have around 30 fields and a record size in the order of 1 KB/customer
(no more than 10,000 records expected).
If I put the information into 4 tables (PASSENGER, CONTACT,
INFORMATION, CONTROL), then none will have more than 10 fields/record,
but I need to associate them with, say, the PASSENGER key. But, if I
use auto increment, I will have to rely on the mysql_insert_id ()
function, which I am not happy about, since multiple simultaneous
accesses of the database is in the specs of the assignment and this
function examines the last INSERT. (Table locks and transaction
processing might help here.)
So, my question is, which design path to follow: 1 table, or 4 tables
and, if the latter, how do I go about reliably retrieving the
auto_increment key?
Cheers,
Dimitris
Jul 19 '05
30 2112
Dear all...
Thanks very much for the invaluable advice! :-)
Cheers,
Dimitris This thread has been closed and replies have been disabled. Please start a new discussion. Similar topics |
by: Patchwork |
last post by:
Hi Everyone,
Please take a look at the following (simple and fun) program:
////////////////////////////////////////////////////////////////////////////
/////////////
// Monster Munch, example program
#include <list>
|
by: Jacek Dziedzic |
last post by:
Hello!
First of all please forgive me for not posting a compilable snippet,
but rather a simplified piece of code with the unimportant
details left out.
Let's say I have two classes 'box_shape' and 'cylinder_shape' that
derive from a common base class 'shape', more or less like this:
namespace Shapes {
|
by: mkdunaway3 |
last post by:
I'm just starting out here and I keep running into a basic problem.
I build a set of tables: First Names, Last Names, Member Status.
I bring these together in a table, Persons' Name & Status, where each
person gets an unique ID and the other info is brought into the table by
lookup.
So far, everything works well.
But then, I try to build the next step and hit a wall that I can't find
|
by: shapper |
last post by:
Hello,
I work mostly in web design and usually I create an administration area.
To access administration my clients usually visit a link on their
browsers.
I would like to create a windows installer which does the following:
1. Opens a directory and copies several files from the CD to the
computer.
2. Places icons on the desktop and start menu.
|
by: Michael S |
last post by:
Why do people spend so much time writing complex generic types?
for fun?
to learn?
for use?
I think of generics like I do about operator overloading.
Great to have as a language-feature, as it defines the language more
completely. Great to use.
| |
by: Jim |
last post by:
I saw a simple web page. It had a frameset with 2 frames. The left frame
was a navigtion frame, with links to interesting websites and a place to
place a username (guess some of the websites were kinda personalized). The
right frame contained the website of the link clicked in the navigation
frame.
Wanting to learn ASP.Net 2.0, I thought I'd start with my own version of
this simple site. Alas, nothing is simple when Microsoft gets...
|
by: aum |
last post by:
Hi,
I'm a Python programmer, just starting to get into javascript. On reading
some of the js guides, and not liking any of the OO usage patterns I saw,
I've cooked up something which python folks might find to taste.
Here's the code - first the 'engine', then some code demonstrating the
usage patterns.
For me (and maybe for some of you), it promotes readability and some
|
by: Chris M. Thomasson |
last post by:
I use the following technique in all of my C++ projects; here is the example
code with error checking omitted for brevity:
_________________________________________________________________
/* Simple Thread Object
______________________________________________________________*/
#include <pthread.h>
extern "C" void* thread_entry(void*);
|
by: maheshgupta0248 |
last post by:
Hi all,
Im a newbie in php, started learning php on my own. I want to create small website using php, that contains links for two simple webpages
> C questions
> C++ questions
C questions page, contains a sequence of questions. Each question is a link to another page which details the answers of the specific question, any user can be able to enter his comments to the question. so the new comment should be queued to the existing...
|
by: marktang |
last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However, people are often confused as to whether an ONU can Work As a Router. In this blog post, we’ll explore What is ONU, What Is Router, ONU & Router’s main usage, and What is the difference between ONU and Router. Let’s take a closer look !
Part I. Meaning of...
|
by: Hystou |
last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can effortlessly switch the default language on Windows 10 without reinstalling. I'll walk you through it.
First, let's disable language synchronization. With a Microsoft account, language settings sync across devices. To prevent any complications,...
| |
by: Oralloy |
last post by:
Hello folks,
I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>".
The problem is that using the GNU compilers, it seems that the internal comparison operator "<=>" tries to promote arguments from unsigned to signed.
This is as boiled down as I can make it.
Here is my compilation command:
g++-12 -std=c++20 -Wnarrowing bit_field.cpp
Here is the code in...
|
by: Hystou |
last post by:
Overview:
Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows Update option using the Control Panel or Settings app; it automatically checks for updates and installs any it finds, whether you like it or not. For most users, this new feature is actually very convenient. If you want to control the update process,...
|
by: agi2029 |
last post by:
Let's talk about the concept of autonomous AI software engineers and no-code agents. These AIs are designed to manage the entire lifecycle of a software development project—planning, coding, testing, and deployment—without human intervention. Imagine an AI that can take a project description, break it down, write the code, debug it, and then launch it, all on its own....
Now, this would greatly impact the work of software developers. The idea...
|
by: conductexam |
last post by:
I have .net C# application in which I am extracting data from word file and save it in database particularly. To store word all data as it is I am converting the whole word file firstly in HTML and then checking html paragraph one by one.
At the time of converting from word file to html my equations which are in the word document file was convert into image.
Globals.ThisAddIn.Application.ActiveDocument.Select();...
|
by: adsilva |
last post by:
A Windows Forms form does not have the event Unload, like VB6. What one acts like?
|
by: 6302768590 |
last post by:
Hai team
i want code for transfer the data from one system to another through IP address by using C# our system has to for every 5mins then we have to update the data what the data is updated we have to send another system
| |
by: bsmnconsultancy |
last post by:
In today's digital era, a well-designed website is crucial for businesses looking to succeed. Whether you're a small business owner or a large corporation in Toronto, having a strong online presence can significantly impact your brand's success. BSMN Consultancy, a leader in Website Development in Toronto offers valuable insights into creating effective websites that not only look great but also perform exceptionally well. In this comprehensive...
| |