Ejemplo n.º 1
0
        static void Main(string[] args)
        {
            List <SeasonData> seasons = new List <SeasonData>();

            Console.WriteLine("Starting Legacy Extractions");

            seasons = GetAllSeasons();
            //seasons = GetOneShlSeason(22);

            Console.WriteLine("----");
            Console.WriteLine("Uploading Data to DB");

            DatabaseHelpers.AddLeagues();
            DatabaseHelpers.AddSeasonTypes();

            foreach (var season in seasons)
            {
                Console.Write(" - Season " + season.SourceSeason.Number);
                season.SaveDataToDB();
                Console.Write(" [DONE]");
                Console.WriteLine();
            }

            DatabaseHelpers.AddFranchises();
            DatabaseHelpers.RemoveExtraPlayers();

            Console.WriteLine("----");
            Console.WriteLine("Extraction Complete");
            Console.WriteLine();
        }