DBM405A Lab 6 Stored Procedure HomeTeamScore and AwayTeamScore and Event to Backup DB

I. OBJECTIVES

  1. Understand how to add, change, and delete records.

II. PARTS LIST

  1. EDUPE Omnymbus Environment (https://devry.edupe.net:8300); and/or
  2. MySQL (dev.mysql.com/downloads).

III. PROCEDURE
By now you have set up either the Omnymbus environment or the MySQL Server Community environment, or both. You may do the labs in this class on your own computer equipped with MySQL or you may use the MySQL environment hosted by the vendor Omnymbus. You may even use both.
Lab Procedure Continued (common to both environments)

  1. Create a Store Procedure to update the HomeTeamScore and the AwayTeamScore for the current record every time the procedure is called.
  2. Write a program to step through the “Season” table displaying each record and allowing the user to enter the final score for the game. Call your stored procedure from within the program updating the “Season” table.
  3. Set up an event to back up your database at midnight every Friday night.



This slideshow requires JavaScript.



This assignment includes a zip document.

  • Attachments
  • Preview random excerpt
    xxx xxxxxxxx;
    xxxxxxxxx $$
    xxxxxx xxxxxxxxx xxxxxxxxxxxxxxxxx(xx xxxxxxxxx xxxxxxx(5), xx xxxxxxxxx xxxxxxx(5),xx xxxxxxxxxxxxxx xxx, xx xxxxxxxxxxxxxx xxx)
    xxxxx
    xxx
    SQL_SAFE_UPDATES = 0; UPDATE Season
    xxx
    HomeTeamScore =
    xxxxxxxxxxxxxx
    , AwayTeamScore = pAwayTeamScore
    xxxxx
    HomeTeam =
    xxxxxxxxx
    xxx
    AwayTeam = pAwayTeam;
    xxx
    $$ DELIMITER ; --
    xxxx
    to verify
    xxxxxx
    xxxxxxxxx
    CALL Baseball.UpdateMatchResult('
    xxxxx
    ', '
    xxxxx
    ', 1,
    x
    ); -- SELECT to
    xxxx
    xxx
    updated info SELECT *FROM Season WHERE HomeTeam = '
    xxxxx
    '
    xxx
    AwayTeam = 'Team2';
    xxx xxxxxxxx;
    - - - more text follows - - -
    Preview random excerpt
    {
    xxxxxx xxxxxxx = "xxxxxx=xxxxxxxxx;xxxx=xxxx;xxxxxxxx=xxxxxxxx;xxxxxxxx=****;";
    xxxxxxxxxxxxxxx xxxx = xxx xxxxxxxxxxxxxxx(xxxxxxx);
    xxx
    {
    xxxxxxx
    .WriteLine("Connecting
    xx
    MySQL...");
    xxxx
    .Open();
    xxxxxxxxxxxx
    cmdSeason = new MySqlCommand("Select *
    xxxx
    Season;
    x
    , conn);
    xxxxxxxxx
    .CommandType =
    xxxxxxxxxxx
    .Text;
    xxxxxxxxxxxxxxx
    rdr = cmdSeason.ExecuteReader();
    xxx
    macthCounter =
    x
    ;
    xxx
    xxxxxxxxxxx
    =
    xxx
    List(); //
    xxxx
    all the data from Season
    xxxxx
    ;
    xxxxx (xxx.xxxx())
    {
    xxxxxxxxxxx.xxx(xxx xxxxxxxxxxxx(xxx["xxxxxxxx"].xxxxxxxx(), xxx["xxxxxxxx"].xxxxxxxx()));
    - - - more text follows - - -
    Preview random excerpt
    {
    xxxxxx xxxxxxx = "xxxxxx=xxxxxxxxx;xxxx=xxxx;xxxxxxxx=xxxxxxxx;xxxxxxxx=****;";
    xxxxxxxxxxxxxxx xxxx = xxx xxxxxxxxxxxxxxx(xxxxxxx);
    xxx
    {
    xxxxxxx
    .
    xxxxxxxxx
    ("Connecting to MySQL...
    x
    );
    xxxx
    .
    xxxx
    ();
    xxxxxxxxxxxx
    cmdSeason =
    xxx
    MySqlCommand("Select *
    xxxx
    Season;", conn);
    xxxxxxxxx
    .CommandType = CommandType.Text;
    xxxxxxxxxxxxxxx
    rdr = cmdSeason.ExecuteReader();
    xxx
    macthCounter = 1;
    xxx
    matchesList = new List(); //
    xxxx
    all the data from Season table;
    xxxxx (xxx.xxxx())
    {
    xxxxxxxxxxx.xxx(xxx xxxxxxxxxxxx(xxx["xxxxxxxx"].xxxxxxxx(), xxx["xxxxxxxx"].xxxxxxxx()));
    - - - more text follows - - -



Purchasing Instruction
List Price: $19
Buy Now

Buy More Save More
Buy at least TWO items & save up to 30% OFF your ENTIRE order!
Rack up instant rebates in your shopping cart. Simply add items to your cart, and see the savings add up.
Discounts will automatically be applied on eligible orders.

Add to Cart