referential integrity

This commit is contained in:
Marc Delisle
2002-03-27 15:53:55 +00:00
parent 4904166668
commit f6d4cb4f1f
41 changed files with 53 additions and 45 deletions

View File

@@ -9,7 +9,7 @@ $Source$
* libraries/display_tbl.lib.php3, changed a variable name for
better doc.
* tbl_properties.php3, lang/*, Documentation.html:
new feature: Relational integrity
new feature: Referential integrity
2002-03-26 Lo<4C>c Chapeaux <lolo@phpheaven.net>
* libraries/common.lib.php3, lines 146-152, 519-524 & 567: fixed bug

View File

@@ -163,7 +163,8 @@
<li>create (*) and read dumps of tables</li>
<li>export (*) and import data to CSV values</li>
<li>administer multiple servers and single databases</li>
<li>communicate in more than 20 different languages</li>
<li>check referential integrity</li>
<li>communicate in more than 38 different languages</li>
</ul>
<table border="0" cellspacing="0" cellpadding="0">
@@ -570,8 +571,15 @@ $cfgPmaAbsoluteUri = (!empty($HTTPS) ? 'https' : 'http') . '://'
<dd>
Since release 2.2.4 you can describe, in a special 'relation' table, which field
is a key in another table (a foreign key). phpMyAdmin currently uses
this to make clickable, when you browse the src table, the data values
that point to the dest table.
this to
<ul>
<li>
make clickable, when you browse the src table, the data values
that point to the dest table </li>
<li>
display links on the table properties page, to check referential
integrity (display missing foreign keys) for each described key</li>
</ul>
<br /><br />
The keys can be numeric or character.

View File

@@ -352,5 +352,5 @@ $strSelectADb = 'Please select a database';
$strSelectAll = 'Select All'; //to translate
$strUnselectAll = 'Unselect All'; //to translate
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -1,2 +1,2 @@
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strZip = '"zip-
$strChangePassword = 'Change password';
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strZip = '"zip-
$strChangePassword = 'Change password';
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = 'Si';
$strZip = '"comprimit amb zip"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -350,5 +350,5 @@ $strYes = '
$strZip = '"zipped"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -353,5 +353,5 @@ $strNoIndex = 'No index defined!';
$strPrimaryKeyName = 'The name of the primary key must be... PRIMARY!';
$strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)';
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strYes = 'Ano';
$strZip = '"zazipov<6F>no"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strYes = 'Ano';
$strZip = '"zazipov<6F>no"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b
$strSelectADb = 'Please select a database';
$strSelectAll = 'Select All'; //to translate
$strUnselectAll = 'Unselect All'; //to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strNoIndex = 'No index defined!';
$strPrimaryKeyName = 'The name of the primary key must be... PRIMARY!';
$strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)';
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -242,7 +242,7 @@ $strQBEIns = 'Ins';
$strQueryOnDb = 'SQL-query on database <b>%s</b>:';
$strRecords = 'Records';
$strRelationalIntegrity = 'Check relational integrity:';
$strReferentialIntegrity = 'Check referential integrity:';
$strReloadFailed = 'MySQL reload failed.';
$strReloadMySQL = 'Reload MySQL';
$strRememberReload = 'Remember reload the server.';

View File

@@ -347,5 +347,5 @@ $strYes = 'Jah';
$strZip = '"zipitud"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -351,5 +351,5 @@ $strYes = 'Kyll
$strZip = '"zip-pakattu"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -242,7 +242,6 @@ $strQBEIns = 'Ajouter';
$strQueryOnDb = 'Requ<71>te SQL sur la base <b>%s</b>&nbsp;:';
$strRecords = 'Enregistrements';
$strRelationalIntegrity = 'V<>rifier l\'int<6E>grit<69> relationnelle';
$strReloadFailed = 'MySQL n\'a pu <20>tre recharg<72>.';
$strReloadMySQL = 'Recharger MySQL';
$strRememberReload = 'N\'oubliez pas de recharger MySQL';
@@ -347,4 +346,5 @@ $strYes = 'Oui';
$strZip = '"zipp<70>"';
$strReferentialIntegrity = 'V<>rifier l\'int<6E>grit<69> r<>f<EFBFBD>rentielle';
?>

View File

@@ -351,5 +351,5 @@ $strCardinality = 'Cardinality';
$strLogin = 'Login';
$strLogPassword = 'Password:';
$strLogUsername = 'Username:';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = 'Ja';
$strZip = '"Zip komprimiert"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -349,5 +349,5 @@ $strNoIndexPartsDefined = 'No index parts defined!';
$strNoIndex = 'No index defined!';
$strPrimaryKeyName = 'The name of the primary key must be... PRIMARY!';
$strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strZip = '"Zipped"';
// To translate
$strChangePassword = 'Change password';
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strYes = 'Igen';
$strZip = '"zippel t<>m<EFBFBD>r<EFBFBD>tve"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -351,5 +351,5 @@ $strZip = '"compresso con zip"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -352,5 +352,5 @@ $strXkana = '
// To translate
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -352,5 +352,5 @@ $strXkana = '
// To translate
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -352,5 +352,5 @@ $strNoIndexPartsDefined = 'No index parts defined!';
$strNoIndex = 'No index defined!';
$strPrimaryKeyName = 'The name of the primary key must be... PRIMARY!';
$strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -351,5 +351,5 @@ $strYes = 'J
$strZip = 'arhiv<69>ts ar zip';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -346,5 +346,5 @@ $strYes = 'Ja';
$strZip = '"komprimert (zip)"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = 'Tak';
$strZip = '".zip"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strBzip = '"bzipped"'; //to translate
$strGzip = '"gzipped"'; //to translate
$strHomepageSourceforge = 'Sourceforge phpMyAdmin Download Page'; //to translate
$strZip = '"zipped"'; //to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -348,5 +348,5 @@ $strZip = '"zipped"';
// To translate
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strZip = '
$strChangePassword = 'Change password';
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = '
$strZip = '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> "zip"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -350,5 +350,5 @@ $strZip = '"zo zipovan
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strZip = '"zozipovan
$strChangePassword = 'Change password';
$strDatabaseWildcard = 'Database (wildcards allowed):'; //to translate
$strPmaUriError = 'The <tt>$cfgPmaAbsoluteUri</tt> directive MUST be set in your configuration file!';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -345,5 +345,5 @@ $strZip = '"comprimido con zip"';
// To translate
$strFlushTable = 'Flush the table ("FLUSH")';//to translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = 'Ja';
$strZip = '"zippad"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -353,5 +353,5 @@ $strNoIndexPartsDefined = 'No index parts defined!';
$strNoIndex = 'No index defined!';
$strPrimaryKeyName = 'The name of the primary key must be... PRIMARY!';
$strPrimaryKeyWarning = '("PRIMARY" <b>must</b> be the name of and <b>only of</b> a primary key!)';
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = 'Evet';
$strZip = '"ziplenmi<6D>"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -347,5 +347,5 @@ $strYes = '
$strZip = '<27><><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD> <20> "zip"';
// To translate
$strRelationalIntegrity = 'Check relational integrity:'; //to translate
$strReferentialIntegrity = 'Check referential integrity:'; //to translate
?>

View File

@@ -1209,7 +1209,7 @@ else if (PMA_MYSQL_INT_VERSION >= 32306
echo "\n";
} // end 3.23.06 < MySQL < 3.23.22
// Relational integrity check
// Referential integrity check
if (!empty($cfgServer['relation'])) {
$local_query = 'SELECT src_column, dest_table, dest_column'
@@ -1219,8 +1219,8 @@ if (!empty($cfgServer['relation'])) {
$result = @mysql_query($local_query);
if ($result != FALSE && mysql_num_rows($result) > 0) {
echo " <!-- Relational integrity check -->\n";
echo " <li>" . $strRelationalIntegrity . "<br />\n";
echo " <!-- Referential integrity check -->\n";
echo " <li>" . $strReferentialIntegrity . "<br />\n";
while ($rel = mysql_fetch_row($result)) {
echo ' <a href="sql.php3?' . $url_query .'&amp;sql_query='
. urlencode('SELECT ' . PMA_backquote($table) . '.* FROM '