From the course: Learning phpMyAdmin
Unlock the full course today
Join today to access over 22,600 courses taught by industry experts or purchase this course individually.
Using variables with bookmarks in phpMyAdmin 4.5
From the course: Learning phpMyAdmin
Using variables with bookmarks in phpMyAdmin 4.5
- phpMyAdmin 4.5 introduced support for embedding multiple variables in a bookmark, so the procedure is slightly different. I've selected the SQL tab for the up and running database in phpMyAdmin 4.5 and the first thing to note is that in the Bookmarked SQL query section at the bottom, there's no input field for variable. That's because phpMyAdmin needs to know how many input fields to create. Let's beginning by creating a bookmark with just one variable. I'm going to base this on an existing bookmark, Budget Cars, we'll select View Only, then click Go to load the bookmark. As in earlier versions of phpMyAdmin, you embed the section of the SQL query that contains a variable in an SQL comment. I'm going to wrap the WHERE clause in comment tags and search by make. Just before WHERE, opening comment tag. After the value, a closing comment tag. Then we change price to make, make it equals and the value is a string so it needs to be inside quotes and the variable needs to be inside square…
Practice while you learn with exercise files
Download the files the instructor uses to teach the course. Follow along and learn by watching, listening and practicing.
Contents
-
-
-
-
-
-
-
-
(Locked)
Performing a simple search8m 28s
-
(Locked)
Using query by example (QBE) to perform a simple search6m 6s
-
(Locked)
Finding and replacing text in a column3m 36s
-
(Locked)
Using QBE to set multiple conditions in a WHERE clause8m 2s
-
(Locked)
Joining multiple tables with QBE5m 2s
-
(Locked)
Building queries manually on a single table6m 48s
-
(Locked)
Building a query manually on multiple tables4m 3s
-
(Locked)
Saving frequently used queries with bookmarks7m 26s
-
(Locked)
Using a variable with a bookmarked query5m 37s
-
(Locked)
Using variables with bookmarks in phpMyAdmin 4.57m 19s
-
(Locked)
Using named parameters in a query4m 53s
-
(Locked)
Running queries from the console6m 31s
-
(Locked)
New Console options in phpMyAdmin 4.52m 17s
-
(Locked)
-
-
-