Parameters:
     - db_name
     - tbl_name
     - max_parts
426654
def get_partition_names(self, db_name, tbl_name, max_parts):
    
    self.send_get_partition_names(db_name, tbl_name, max_parts)
    return self.recv_get_partition_names()
1049692
def delete_partition_column_statistics(self, db_name, tbl_name, part_name, col_name):
    
    self.send_delete_partition_column_statistics(db_name, tbl_name, part_name, col_name)
    return self.recv_delete_partition_column_statistics()
274671
def name_parts(self):
        """"""

        default = PartialMixin.ANY

        return ([(k, default, True)
                for k, _, _ in PartitionName._name_parts]
                +
                [(k, default, True)
                 for k, _, _ in Name._generated_names]
                )
582657
def get_all_names( self, offset=None, count=None, include_expired=False ):
        
        if offset is not None and offset < 0:
            offset = None

        if count is not None and count < 0:
            count = None 

        cur = self.db.cursor()
        names = namedb_get_all_names( cur, self.lastblock, offset=offset, count=count, include_expired=include_expired )
        return names
597844
def atlasdb_get_zonefiles_missing_count_by_name(name, max_index=None, indexes_exclude=[], con=None, path=None):
    
    with AtlasDBOpen(con=con, path=path) as dbcon:
        sql = 'SELECT COUNT(*) FROM zonefiles WHERE name = ? AND present = 0 {} {};'.format(
                'AND inv_index <= ?' if max_index is not None else '',
                'AND inv_index NOT IN ({})'.format(','.join([str(int(i)) for i in indexes_exclude])) if len(indexes_exclude) > 0 else ''
                )

        args = (name,)
        if max_index is not None:
            args += (max_index,)

        cur = dbcon.cursor()
        res = atlasdb_query_execute(cur, sql, args)
        for row in res:
            return row['COUNT(*)']
424088
def drop_partition_by_name_with_environment_context(self, db_name, tbl_name, part_name, deleteData, environment_context):
    
    self.send_drop_partition_by_name_with_environment_context(db_name, tbl_name, part_name, deleteData, environment_context)
    return self.recv_drop_partition_by_name_with_environment_context()
529687
def _get_db_names(self, dbs, strict=True):
        
        dbs = utils.coerce_to_list(dbs)
        db_names = [utils.get_name(db) for db in dbs]
        if strict:
            good_dbs = self.instance.list_databases()
            good_names = [utils.get_name(good_db) for good_db in good_dbs]
            bad_names = [db_name for db_name in db_names
                    if db_name not in good_names]
            if bad_names:
                bad = ", ".join(bad_names)
                raise exc.NoSuchDatabase("The following database(s) were not "
                        "found: %s" % bad)
        return db_names
1333920
def getMaxRow(self, login, tableName, auths, startRow, startInclusive, endRow, endInclusive):
    
    self.send_getMaxRow(login, tableName, auths, startRow, startInclusive, endRow, endInclusive)
    return self.recv_getMaxRow()
180728
def alter_partitions_with_environment_context(self, db_name, tbl_name, new_parts, environment_context):
    
    self.send_alter_partitions_with_environment_context(db_name, tbl_name, new_parts, environment_context)
    self.recv_alter_partitions_with_environment_context()
156875
def _get_max_name_len(instances):
    """"""
    # FIXME: ec2.instanceCollection doesn't have __len__
    for i in instances:
        return max([len(get_tag_value(i.tags, 'Name')) for i in instances])
    return 0
595282
def get_part_specs_by_filter(self, db_name, tbl_name, filter, max_parts):
    
    self.send_get_part_specs_by_filter(db_name, tbl_name, filter, max_parts)
    return self.recv_get_part_specs_by_filter()
1096198
def load(dbname):
    
    db = Database(dbname)

    # Get the name of the objects
    tables = get_table_list(db.cur)

    # Create a Trace instance for each object
    chains = 0
    for name in tables:
        db._traces[name] = Trace(name=name, db=db)
        db._traces[name]._shape = get_shape(db.cur, name)
        setattr(db, name, db._traces[name])
        db.cur.execute('SELECT MAX(trace) FROM [%s]' % name)
        chains = max(chains, db.cur.fetchall()[0][0] + 1)

    db.chains = chains
    db.trace_names = chains * [tables, ]
    db._state_ = {}
    return db
174916
def get_partition_names_ps(self, db_name, tbl_name, part_vals, max_parts):
    
    self.send_get_partition_names_ps(db_name, tbl_name, part_vals, max_parts)
    return self.recv_get_partition_names_ps()
736355
def get_limits(self):
        
        if self.limits != {}:
            return self.limits
        limits = {}
        limits['DB instances'] = AwsLimit(
            'DB instances',
            self,
            40,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBInstance'
        )
        limits['Reserved Instances'] = AwsLimit(
            'Reserved Instances',
            self,
            40,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBInstance',
        )
        limits['Storage quota (GB)'] = AwsLimit(
            'Storage quota (GB)',
            self,
            100000,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBInstance',
        )
        limits['DB snapshots per user'] = AwsLimit(
            'DB snapshots per user',
            self,
            100,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBSnapshot',
        )
        limits['DB parameter groups'] = AwsLimit(
            'DB parameter groups',
            self,
            50,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBParameterGroup',
        )
        limits['DB security groups'] = AwsLimit(
            'DB security groups',
            self,
            25,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBSecurityGroup',
        )
        limits['VPC Security Groups'] = AwsLimit(
            'VPC Security Groups',
            self,
            5,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBSecurityGroup',
        )
        limits['Subnet Groups'] = AwsLimit(
            'Subnet Groups',
            self,
            50,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBSubnetGroup',
            ta_limit_name='Subnet groups'
        )
        limits['Subnets per Subnet Group'] = AwsLimit(
            'Subnets per Subnet Group',
            self,
            20,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBSubnetGroup',
            ta_limit_name='Subnets per subnet group'
        )
        limits['Option Groups'] = AwsLimit(
            'Option Groups',
            self,
            20,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBOptionGroup',
        )
        limits['Event Subscriptions'] = AwsLimit(
            'Event Subscriptions',
            self,
            20,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBEventSubscription',
            ta_limit_name='Event subscriptions'
        )
        limits['Read replicas per master'] = AwsLimit(
            'Read replicas per master',
            self,
            5,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBInstance',
        )
        # this is the number of rules per security group
        limits['Max auths per security group'] = AwsLimit(
            'Max auths per security group',
            self,
            20,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBSecurityGroup',
            limit_subtype='AWS::RDS::DBSecurityGroupIngress',
        )
        limits['DB Clusters'] = AwsLimit(
            'DB Clusters',
            self,
            40,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBCluster',
            ta_limit_name='Clusters'
        )
        limits['DB Cluster Parameter Groups'] = AwsLimit(
            'DB Cluster Parameter Groups',
            self,
            50,
            self.warning_threshold,
            self.critical_threshold,
            limit_type='AWS::RDS::DBClusterParameterGroup',
            ta_limit_name='Cluster parameter groups'
        )
        self.limits = limits
        return limits
923567
def drop_index_by_name(self, db_name, tbl_name, index_name, deleteData):
    
    self.send_drop_index_by_name(db_name, tbl_name, index_name, deleteData)
    return self.recv_drop_index_by_name()
707430
def get_index_names(self, db_name, tbl_name, max_indexes):
    
    self.send_get_index_names(db_name, tbl_name, max_indexes)
    return self.recv_get_index_names()
147102
def get_index_by_name(self, db_name, tbl_name, index_name):
    
    self.send_get_index_by_name(db_name, tbl_name, index_name)
    return self.recv_get_index_by_name()