Package com.foundationdb.qp.rowtype

Examples of com.foundationdb.qp.rowtype.Schema


            "schema", "t",
            "id int not null key",
            "rand int",
            "filler varchar(20)");
        group = group(t);
        schema = new Schema(ais());
        tRowType = schema.tableRowType(table(t));
        adapter = newStoreAdapter(schema);
        queryContext = queryContext(adapter);
        queryBindings = queryContext.createBindings();
    }
View Full Code Here


            "schema", "t",
            "id int not null",
            "x int",
            "primary key(id)");
        createIndex("schema", "t", "idx_x", "x");
        schema = new Schema(ais());
        tRowType = schema.tableRowType(table(t));
        idxRowType = indexType(t, "x");
        adapter = persistitAdapter(schema);
        queryContext = queryContext(adapter);
        queryBindings = queryContext.createBindings();
View Full Code Here

            "cid2 int not null",
            "cid2_copy int",
            "primary key(gid, pid, cid2)",
            "grouping foreign key(gid, pid) references parent(gid, pid)");
        createIndex("schema", "child2", "idx_cid2_copy", "cid2_copy");
        schema = new Schema(ais());
        grandparentRowType = schema.tableRowType(table(grandparent));
        parentRowType = schema.tableRowType(table(parent));
        child1RowType = schema.tableRowType(table(child1));
        child2RowType = schema.tableRowType(table(child2));
        group = group(grandparent);
View Full Code Here

            "primary key(aid)",
            "grouping foreign key (cid) references customer(cid)");
        createIndex("schema", "customer", "idx_cname", "name");
        createIndex("schema", "orders", "idx_osalesman", "salesman");
        createIndex("schema", "address", "idx_aaddress", "address");
        schema = new Schema(ais());
        customerRowType = schema.tableRowType(table(customer));
        orderRowType = schema.tableRowType(table(order));
        itemRowType = schema.tableRowType(table(item));
        addressRowType = schema.tableRowType(table(address));
        customerNameIndexRowType = indexType(customer, "name");
View Full Code Here

        getServiceHolder().getTransactionService().getTransactionStartTimestamp(session);
        to(Stage.POST_BEGIN);
        try {
            while(!success) {
                to(Stage.PRE_SCAN);
                Schema schema = SchemaCache.globalSchema(getServiceHolder().getSchemaManager().getAis(session));
                Operator plan = operatorCreator.create(schema);
                StoreAdapter adapter = getServiceHolder().getStore().createAdapter(session, schema);
                QueryContext context = new SimpleQueryContext(adapter);
                QueryBindings bindings = context.createBindings();
                Cursor cursor = API.cursor(plan, context, bindings);
View Full Code Here

            "c3 int not null",
            "c4 int not null",
            "c5 int not null",
            "primary key(c1, c2, c3, c4, c5)");
        Index index = createIndex(schemaName(), tableName, "idx", "index_key");
        schema = new Schema(ais());
        tRowType = schema.tableRowType(table(t));
        indexRowType = schema.indexRowType(index);
        adapter = newStoreAdapter(schema);
        queryContext = queryContext(adapter);
        queryBindings = queryContext.createBindings();
View Full Code Here

            /* 5 */ "filler200 varchar(200)",
            /* 6 */ "filler300 varchar(300)",
            /* 7 */ "filler400 varchar(400)",
            "primary key(id)");
        group = group(t);
        schema = new Schema(ais());
        tRowType = schema.tableRowType(table(t));
        adapter = newStoreAdapter(schema);
        queryContext = queryContext(adapter);
        queryBindings = queryContext.createBindings();
    }
View Full Code Here

                           "rid int",
                           "root_instance int",
                           "primary key(mid)",
                           String.format("grouping foreign key(rid, root_instance) references %s(rid, root_instance)",
                                         rootTableName));
        schema = new Schema(ais());
        rootRowType = schema.tableRowType(table(root));
        oneRowType = schema.tableRowType(table(one));
        manyRowType = schema.tableRowType(table(many));
        rootPKIndexType = indexType(root, "rid", "root_instance");
        group = group(root);
View Full Code Here

        t = createTable(schemaName, tableName,
                        "id int not null",
                        indexedColumn.declaration(),
                        "primary key(id)");
        createIndex(schemaName, tableName, "idx", indexedColumn.name());
        schema = new Schema(ais());
        idxRowType = indexType(t, indexedColumn.name());
        adapter = newStoreAdapter(schema);
        queryContext = queryContext(adapter);
        queryBindings = queryContext.createBindings();
    }
View Full Code Here

    private List<BindableRow> bindRows;
    private final Random random = new Random (100);
   
    @Before
    public void createFileBuffers() {
        schema = new Schema(ais());
        os = new ByteArrayOutputStream();
        startKey = new SortKey();
        writer = new KeyWriter(os);
        bindRows = new ArrayList<>();
View Full Code Here

TOP

Related Classes of com.foundationdb.qp.rowtype.Schema

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.