Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
data-networks-web
lab-exercises
Commits
5a70ad5f
Commit
5a70ad5f
authored
Nov 30, 2016
by
Sorrel Harriet
Browse files
ongoing work on lab 8 script
parent
f8f194d9
Changes
1
Hide whitespace changes
Inline
Side-by-side
lab-8/music-store-app/views/place-order.php
View file @
5a70ad5f
...
...
@@ -14,9 +14,13 @@ mysqli_query($link, 'START TRANSACTION');
// fetch the albums so that we have access to their names and upc's
// lock in shared mode so affected data cannot be altered by other
// sessions BEFORE the transaction is committed or rolled back
// sessions BEFORE the transaction is committed or rolled back.
// only list albums that are in stock.
$sql
=
"SELECT title, upc
FROM Album
INNER JOIN Inventory
ON Album.upc=Inventory.album_upc
WHERE Inventory.stock>0
ORDER BY title LOCK IN SHARE MODE"
;
$result
=
mysqli_query
(
$link
,
$sql
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment