# pgSnp.sql was originally generated by the autoSql program, which also 
# generated pgSnp.c and pgSnp.h.  This creates the database representation of
# an object which can be loaded and saved from RAM in a fairly 
# automatic way.

#personal genome SNP
CREATE TABLE pgSnp (
    bin smallint unsigned not null,	# A field to speed indexing
    chrom varchar(255) not null,	# Chromosome
    chromStart int unsigned not null,	# Start position in chrom
    chromEnd int unsigned not null,	# End position in chrom
    name varchar(255) not null,	# alleles
    alleleCount int not null,	# number of alleles
    alleleFreq varchar(255) not null,	# comma separated list of frequency of each allele
    alleleScores varchar(255) not null,	# comma separated list of quality scores
              #Indices
    INDEX(chrom,bin)
);
