SingleStore DB

Run Sample Queries

Now that you have connected to your cluster, run the following SingleStore DB database commands to create a table and seed it with sample data:

CREATE DATABASE test;

USE test;

CREATE TABLE test_table (id BIGINT PRIMARY KEY AUTO_INCREMENT, c INT);

INSERT INTO test_table (c) VALUES (1);

INSERT INTO test_table (c) SELECT c*2 FROM test_table;

INSERT INTO test_table (c) SELECT c*2 FROM test_table;

INSERT INTO test_table (c) SELECT c*2 FROM test_table;

INSERT INTO test_table (c) SELECT c*2 FROM test_table;

INSERT INTO test_table (c) SELECT c*2 FROM test_table;

SELECT SUM(c) FROM test_table;