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

#An alternatively spliced gene graph.
CREATE TABLE altGraph (
    id int unsigned not null,	# Unique ID
    orientation tinyint not null,	# +1 or -1 relative to start bac
    startBac int unsigned not null,	# First bac touched by graph
    startPos int unsigned not null,	# Start position in first bac
    endBac int unsigned not null,	# Last bac touched by graph
    endPos int unsigned not null,	# End position in last bac
    vertexCount int unsigned not null,	# Number of vertices in graph
    vTypes longblob not null,	# Type for each vertex
    vBacs longblob not null,	# Bac for each vertex
    vPositions longblob not null,	# Position in bac for each vertex
    edgeCount int unsigned not null,	# Number of edges in graph
    edgeStarts longblob not null,	# Array with start vertex of edges
    edgeEnds longblob not null,	# Array with end vertex of edges
    mrnaRefCount int not null,	# Number of supporting mRNAs
    mrnaRefs longblob not null,	# IDs of all supporting mRNAs
              #Indices
    PRIMARY KEY(id)
);
