Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Now that your database is set up, the pet store owner wants you to add new pets to their inventory. The pet store owner also
Now that your database is set up, the pet store owner wants you to add new pets to their inventory. The pet store owner also wants the ability to remove pets from the database. Complete the functions below so that it inserts a new record into the table created above using the values of the parameters as the values for the record and it removes the pet with the specified id from the database. const mysql = require('mysql'); const config = require('./dbConfig'); // import config exports.addPet = function(name, breed, age, color) { const con = mysql.createConnection(config); // db connection }; exports.removePet = function(id) { const con = mysql.createConnection(config); // db connection }; Feel free to copy the snippet above into your solution
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started