[Weberp-svn] SF.net SVN: weberp:[8231] trunk
Brought to you by:
sotandeka,
tim_schofield
From: <tim...@us...> - 2011-10-03 20:06:20
|
Revision: 8231 http://weberp.svn.sourceforge.net/weberp/?rev=8231&view=rev Author: tim_schofield Date: 2011-10-03 20:06:13 +0000 (Mon, 03 Oct 2011) Log Message: ----------- Remove all SELECT * references, only choose those fields that are needed Modified Paths: -------------- trunk/GLBalanceSheet.php trunk/GLProfit_Loss.php trunk/GLTagProfit_Loss.php trunk/GLTrialBalance.php trunk/geo_displaymap_suppliers.php trunk/includes/UpgradeDB_mysql.inc Modified: trunk/GLBalanceSheet.php =================================================================== --- trunk/GLBalanceSheet.php 2011-10-03 20:05:54 UTC (rev 8230) +++ trunk/GLBalanceSheet.php 2011-10-03 20:06:13 UTC (rev 8231) @@ -54,7 +54,7 @@ echo '<br /><div class="centre"><input type="submit" name="ShowBalanceSheet" value="'._('Show on Screen (HTML)').'" /></div>'; echo '<br /><div class="centre"><input type="submit" name="PrintPDF" value="'._('Produce PDF Report').'" /></div>'; - /*Now do the posting while the user is thinking about the period to select */ + /*Now do the posting while the user is thinking about the period to select*/ include ('includes/GLPostings.inc'); } elseif (isset($_POST['PrintPDF'])) { Modified: trunk/GLProfit_Loss.php =================================================================== --- trunk/GLProfit_Loss.php 2011-10-03 20:05:54 UTC (rev 8230) +++ trunk/GLProfit_Loss.php 2011-10-03 20:06:13 UTC (rev 8231) @@ -98,7 +98,7 @@ echo '<br /><div class="centre"><input type="submit" name="ShowPL" value="'._('Show on Screen (HTML)').'" /></div>'; echo '<br /><div class="centre"><input type="submit" name="PrintPDF" value="'._('Produce PDF Report').'" /></div>'; - /*Now do the posting while the user is thinking about the period to select */ + /*Now do the posting while the user is thinking about the period to select*/ include ('includes/GLPostings.inc'); Modified: trunk/GLTagProfit_Loss.php =================================================================== --- trunk/GLTagProfit_Loss.php 2011-10-03 20:05:54 UTC (rev 8230) +++ trunk/GLTagProfit_Loss.php 2011-10-03 20:06:13 UTC (rev 8231) @@ -115,7 +115,7 @@ echo '<div class="centre"><input type="submit" name="ShowPL" value="'._('Show Statement of Income and Expenditure').'" /><br />'; echo '<br /><input type="submit" name="PrintPDF" value="'._('PrintPDF').'" /></div>'; - /*Now do the posting while the user is thinking about the period to select */ + /*Now do the posting while the user is thinking about the period to select*/ include ('includes/GLPostings.inc'); Modified: trunk/GLTrialBalance.php =================================================================== --- trunk/GLTrialBalance.php 2011-10-03 20:05:54 UTC (rev 8230) +++ trunk/GLTrialBalance.php 2011-10-03 20:06:13 UTC (rev 8231) @@ -93,7 +93,7 @@ echo '<div class="centre"><input type="submit" name="ShowTB" value="' . _('Show Trial Balance') .'" />'; echo '<input type="submit" name="PrintPDF" value="'._('PrintPDF').'" /></div>'; -/*Now do the posting while the user is thinking about the period to select */ +/*Now do the posting while the user is thinking about the period to select*/ include ('includes/GLPostings.inc'); Modified: trunk/geo_displaymap_suppliers.php =================================================================== --- trunk/geo_displaymap_suppliers.php 2011-10-03 20:05:54 UTC (rev 8230) +++ trunk/geo_displaymap_suppliers.php 2011-10-03 20:06:13 UTC (rev 8231) @@ -8,7 +8,13 @@ include ('includes/header.inc'); include('includes/SQL_CommonFunctions.inc'); -$sql="SELECT * FROM geocode_param WHERE 1"; +$sql="SELECT geocode_key, + center_long, + center_lat, + map_height, + map_width, + map_host + FROM geocode_param WHERE 1"; $ErrMsg = _('An error occurred in retrieving the currency information');; $result = DB_query($sql, $db, $ErrMsg); $myrow = DB_fetch_array($result); Modified: trunk/includes/UpgradeDB_mysql.inc =================================================================== --- trunk/includes/UpgradeDB_mysql.inc 2011-10-03 20:05:54 UTC (rev 8230) +++ trunk/includes/UpgradeDB_mysql.inc 2011-10-03 20:06:13 UTC (rev 8231) @@ -316,7 +316,7 @@ function DropPrimaryKey($Table, $OldKey, $db) { $Total=0; foreach ($OldKey as $Field) { - $sql="SELECT * FROM information_schema.key_column_usage WHERE table_name='".$Table."' AND constraint_name='primary' AND + $sql="SELECT table_name FROM information_schema.key_column_usage WHERE table_name='".$Table."' AND constraint_name='primary' AND table_schema='".$_SESSION['DatabaseName']."' AND COLUMN_NAME='".$Field."'"; $result = DB_query($sql, $db); $Total = $Total + DB_num_rows($result); @@ -334,7 +334,7 @@ } function AddPrimaryKey($Table, $Fields, $db) { - $sql="SELECT * FROM information_schema.key_column_usage WHERE table_name='".$Table."' AND constraint_name='primary' AND + $sql="SELECT table_name FROM information_schema.key_column_usage WHERE table_name='".$Table."' AND constraint_name='primary' AND table_schema='".$_SESSION['DatabaseName']."'"; $result = DB_query($sql, $db); if (DB_num_rows($result)!=sizeOf($Fields)) { This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |