Пример #1
0
            override public int RunCommand()
            {
                using (var conn = new SnowflakeDbConnection())
                {
                    conn.ConnectionString = configuration.GetConnectionString("SnowFlake");

                    conn.Open();
                    var cmd          = conn.CreateCommand();
                    var CommandText  = "SELECT * from DB_APPS.PUBLIC.BOOKINGS as b ORDER BY b.CREATED_AT DESC LIMIT 10";
                    var reservations = conn.Query <Reservation>(CommandText);

                    foreach (var reservation in reservations)
                    {
                        console.WriteLine("= " + reservation.Id);
                    }
                }

                return(0);
            }