Sunday, January 29, 2017

Using SQL to build a simple test database

I need a database for my newest python app.

So to test my app, I need to create a test database, and fill it with test data.

As a start, here's the SQL to create a client table, with one field (for now), and insert 3 records into it:

use tempdb;
drop table clients;
create table clients
(
client_name varchar(80)
);
insert into clients values ('client1');
insert into clients values ('client2');
insert into clients values ('client3');

No comments:

Post a Comment