Exemplo n.º 1
0
        private Dictionary <string, ActualIndex> readIndexes(DbDataReader reader)
        {
            var dict = new Dictionary <string, ActualIndex>();

            reader.NextResult();
            while (reader.Read())
            {
                if (reader.IsDBNull(2))
                {
                    continue;
                }

                var schemaName = reader.GetString(1);
                var tableName  = reader.GetString(2);

                if ((Identifier.Schema == schemaName && Identifier.Name == tableName) || Identifier.QualifiedName == tableName)
                {
                    var index = new ActualIndex(Identifier, reader.GetString(3),
                                                reader.GetString(4));

                    dict.Add(index.Name, index);
                }
            }

            return(dict);
        }
Exemplo n.º 2
0
    public void OnDrop(PointerEventData eventData)
    {
        if (!item)
        {
            ActualIndex item_index = ImageDragger.item_being_dragged.transform.GetChild(0).GetComponent <ActualIndex>();
            my_index = numberPositionHandler.num_handler_instance.returnMyIndex(this.gameObject);

            if (item_index.actual_index == my_index)
            {
                ImageDragger.item_being_dragged.transform.SetParent(transform);
                numberPositionHandler.num_completed += 1;
            }
        }
    }
Exemplo n.º 3
0
        public async Task matching_index_ddl(string description, Action <Table> configure)
        {
            configure(theTable);
            await CreateSchemaObjectInDatabase(theTable);

            var existing = await theTable.FetchExisting(theConnection);

            // The index DDL should match what the database thinks it is in order to match

            var actualSql   = ActualIndex.CanonicizeDdl(existing.Indexes.Single(), theTable);
            var expectedSql = ActualIndex.CanonicizeDdl(theTable.Indexes.Single(), theTable);

            actualSql.ShouldBe(expectedSql);

            // And no deltas
            var delta = await theTable.FindDelta(theConnection);

            delta.Indexes.Matched.Count.ShouldBe(1);
        }
Exemplo n.º 4
0
 protected bool Equals(ActualIndex other)
 {
     return string.Equals(Name, other.Name) && string.Equals(DDL, other.DDL);
 }
Exemplo n.º 5
0
 protected bool Equals(ActualIndex other)
 {
     return(string.Equals(Name, other.Name) && string.Equals(DDL, other.DDL));
 }
 public bool Matches(ActualIndex index)
 {
     return(index != null);
 }