Ejemplo n.º 1
0
        static void Main()
        {
            var person = new Person {
                Id        = Guid.NewGuid().ToString(),
                LastName  = "Test",
                FirstName = "User"
            };

            var entity = new PersonEntity(person);
            var repo   = GetRepository();

            repo.Add(entity);

            var foundEntity = repo
                              .Where(e => e.PartitionKey == person.LastName)
                              .Where(e => e.RowKey == person.Id)
                              .SingleOrDefault();

            Console.WriteLine("{0} {1}", foundEntity.FirstName, foundEntity.LastName);

            Console.Write("Press any key to exit...");
            Console.ReadKey(true);
        }
Ejemplo n.º 2
0
        static void Main()
        {
            var person = new Person {
                Id = Guid.NewGuid().ToString(),
                LastName = "Test",
                FirstName = "User"
            };

            var entity = new PersonEntity(person);
            var repo = GetRepository();

            repo.Add(entity);

            var foundEntity = repo
                .Where(e => e.PartitionKey == person.LastName)
                .Where(e => e.RowKey == person.Id)
                .SingleOrDefault();

            Console.WriteLine("{0} {1}", foundEntity.FirstName, foundEntity.LastName);

            Console.Write("Press any key to exit...");
            Console.ReadKey(true);
        }