Jump to content
Larry Ullman's Book Forums

sandari

Members
  • Content Count

    29
  • Joined

  • Last visited

Community Reputation

1 Neutral

About sandari

  • Rank
    Member
  1. If you go to: http://dev.mysql.com/doc/refman/5.5/en/time-zone-support.html you will find full instructions on loading time zones into MySQL
  2. All fields are correct as are the data types. The code being sent is as follows: update tblClients SET GivenName1='Susanna', GivenName2='Anastasia', PreferredName='Susie', Surname='Barishnakov', DoB='1995-10-25', Gender='Female', PlaceOfBirth='', Address1='', Address2='', Suburb='8836', Phone='', Source='', ReferredBy='', email='', OptOut='0', WrongAddress='0', Campus='2', FirstContact='2012-10-25', Merde='0', Inactive='0', CRN='', AdmissionPack='0', AdmissionProcedure='0', AdmittedBy='', ResidencyContract='0', ContractSigned='0', ContractWitnessed='0, DateContractSigned='0000-00-00', KeyDepositReceived='0', KeyDepositRefunded='0', ReceiptDate='2012-10-25', RefundDate='0000-00-00', PreviousClient='0', PreviousCampus='2', PreviousAdmission='0000-00-00' where (ID='23'); But still I get '> as a response.
  3. I have query in PHP as follows: <code> $query="update tblClients SET GivenName1='$GivenName1', GivenName2='$GivenName2', PreferredName='$PreferredName', Surname='$Surname', DoB='$DoB', Gender='$Gender', PlaceOfBirth='$PlaceOfBirth', Address1='$Address1', Address2='$Address2', Suburb='$Suburb_id', Phone='$Phone', Source='$Source', ReferredBy='$ReferredBy', email='$Email', OptOut='$OptOut', WrongAddress='$WrongAddress', Campus='$Campus', FirstContact='$FirstContact', Merde='$Merde', Inactive='$Inactive', CRN='$CRN', AdmissionPack='$AdmissionPack', AdmissionProcedure='$AdmissionProcedure', AdmittedBy='$AdmittedBy', ResidencyContract='$ResidencyContract', ContractSigned='$ContractSigned', ContractWitnessed='$ContractWitnessed, DateContractSigned='$DateContractSigned', KeyDepositReceived='$KeyDepositReceived', KeyDepositRefunded='$KeyDepositRefunded', ReceiptDate='$ReceiptDate', RefundDate='$RefundDate', PreviousClient='$PreviousClient', PreviousCampus='$PreviousCampus', PreviousAdmission='$PreviousAdmission' where (ID='$ClientID');"; </code> The problem is that when I echo the query to the screen, copy it and paste it into the command line of MySQL it returns what looks like: '> Any suggestions?
  4. Sorry guys but I am having trouble posting the screen shots. Anyway, when using the command line the first screen lists all the tables in the database. The table "award" does not show up. The second shows what happens when I try to create the table. It returns: ERROR 1050 (42S01): Table ''mwwg'.'award' already exists''
  5. This is the first screen shot for the previous post: This is the second screen shot:
  6. The table does not show up either in phpMyAdmin nor from the command line. This is a screen shot: and if I try to create it from the command line I get: What's going on??
  7. <code> CREATE TABLE IF NOT EXISTS `award` ( `award_id` int(11) NOT NULL AUTO_INCREMENT, `show_year` varchar(6) NOT NULL, `category_id` varchar(10) DEFAULT NULL, `category` varchar(100) DEFAULT NULL, `FirstPrize` varchar(40) DEFAULT NULL, `SecondPrize` varchar(40) DEFAULT NULL, `ThirdPrize` varchar(40) DEFAULT NULL, `FourthPrize` varchar(40) DEFAULT NULL, `HighlyCommended` varchar(40) DEFAULT NULL, PRIMARY KEY (`award_id`) ) ENGINE=InnoDB DEFAULT CHARSET=latin1 AUTO_INCREMENT=29 ; </code> When I run the above command I get the response: "#1050 - Table '`mwwg`.`award`' already exists" If I then run "show tables;" the table "award" does not show up. Any clues??
  8. Thanks for your input on this problem. It turned out that I had an error in the code where it had to decide whether Submitted was true or not. The program thought that Submitted was TRUE and just saved the variables back to the database and returned to the calling page. Thanks again.
  9. I give up!! What is wrong with this code? while($row = mysqli_fetch_array($result,MYSQLI_ASSOC)){ echo "<tr class=\"data\" align=\"center\" width=\"100%\"> <form action=\"edit_other_medical_problem.php\" method=\"POST\"> <td align=\"center\">{$row['AssessmentDate']}</td> <td align=\"center\">{$row['MedicalProblem']}</td> <td align=\"center\">{$row['TreatmentPlan']}</td> <td align=\"center\">{$row['OtherDetails']}</td> <td align=\"center\"> <input type=\"submit\" name=\"submit\" value=\"Edit\"> <input type=\"hidden\" name=\"MedicalProblemID\" value=\"{$row['ID']}\"> </td> </form>"; echo "<form action=\"delete_other_medical_problem.php\" method=\"POST\"> <td align=\"center\"> <input type=\"submit\" name=\"submit\" value=\"Delete\"> <input type=\"hidden\" name=\"MedicalProblemID\" value=\"{$row['ID']}\"> </td> </form>"; echo "</tr>"; } The "Delete" button works beautifully but the "Edit" button remains on this page instead of opening "edit_other_medical_problem.php". I cannot see the difference.
  10. I have been using "PHP6 and MySQL5" for some time now and am reasonably comfortable with it. However, when looking for additional info on the web I often come accross the symbol "->". Can someone please explain, in detail, what this means and how it works. I look forward to being educated.
  11. i am sure the logic for this is quite simple. I just cannot see it. My pagination works relly well, too well in fact. I have a file that displays 10 records at a time. However, the pagination dispalys all 1643 page numbers. How do I limit the display to just 3 or 4 page numbers with ellipsis each side after moving beyond the initial 3 or 4 pages?
  12. Thanks Jaepee, It's too easy to make such a silly mistake like this. Took your advice and all is now good.
×
×
  • Create New...