Activity 3.2 – adding image file paths to the database
One of the members with the surname Pettit
has added himself as a member of the Automobile Club. You are asked to add the image of the new member in the members
table using the file path method. You are also asked to fetch the full file path of the new image that is added.
Perform the following steps to achieve the goal of this activity:
- Determine the ID of the member with the surname
Pettit
. - Download the image from https://github.com/PacktWorkshops/The-MySQL-Workshop/tree/master/Chapter03/Activity02 and save it in the
Member/Photos
folder. - Now that you have your image in place, open another SQL tab and create a script to place the path and photo name in your member record.
- Create and run another SQL query to extract the full file path for your image.
On successful completion of the activity, you should get the following output: