Search the Community
Showing results for tags 'where clause'.
-
I am a beginner with MySQL and was wondering what method advanced users would recommend to perform the simple task of looking through two tables to find one row. I don't need code from you, just a general idea of what type of query is best for this situation. If you can offer an explanation of why you like the method, that's even better. Thanks!
-
I'm very new to MySQL and trying to learn the basics. My question is this: I've created a simple database containing details of items owed to various patients by the pharmacy. I have made a search feature so that the staff can search quickly. In the search results, each patient's name is hyperlinked. When the hyperlink is clicked, I want it to go to a page where it displays all data from that row in the database table related to that patient. I have done this with an OwingID auto-incrementing variable in the table. I have the page set up where the data will display and can make it display any record I choose with this command: $displayowing = mysql_query("SELECT Date, FirstName, LastName, Item, Quantity FROM tOwings WHERE OwingID=1"); but I have to change the OwingID in the code myself from the server side. How do I make the links from the search results do this for me? Thanks...