17feb53db8bb08a60c512a636bc6eb77310b52c4
braney
  Mon Mar 21 16:06:28 2011 -0700
add support for "select fields" in custom bam tracks, output message if the output is being maxed out.   #27
diff --git src/hg/lib/samAlignment.c src/hg/lib/samAlignment.c
index 34ac763..1dd2eb2 100644
--- src/hg/lib/samAlignment.c
+++ src/hg/lib/samAlignment.c
@@ -174,16 +174,32 @@
 if (sep == ',') fputc('"',f);
 fprintf(f, "%s", el->seq);
 if (sep == ',') fputc('"',f);
 fputc(sep,f);
 if (sep == ',') fputc('"',f);
 fprintf(f, "%s", el->qual);
 if (sep == ',') fputc('"',f);
 fputc(sep,f);
 if (sep == ',') fputc('"',f);
 fprintf(f, "%s", el->tagTypeVals);
 if (sep == ',') fputc('"',f);
 fputc(lastSep,f);
 }
 
 /* -------------------------------- End autoSql Generated Code -------------------------------- */
-
+char *samAlignmentAutoSqlString = 
+"table samAlignment\n"
+"\"The fields of a SAM short read alignment, the text version of BAM.\"\n"
+    "(\n"
+    "string qName;	\"Query template name - name of a read\"\n"
+    "ushort flag;	\"Flags.  0x10 set for reverse complement.  See SAM docs for others.\"\n"
+    "string rName;	\"Reference sequence name (often a chromosome)\"\n"
+    "uint pos;		\"1 based position\"\n"
+    "ubyte mapQ;		\"Mapping quality 0-255, 255 is best\"\n"
+    "string cigar;	\"CIGAR encoded alignment string.\"\n"
+    "string rNext;	\"Ref sequence for next (mate) read. '=' if same as rName, '*' if no mate\"\n"
+    "int pNext;		\"Position (1-based) of next (mate) sequence. May be -1 or 0 if no mate\"\n"
+    "int tLen;	        \"Size of DNA template for mated pairs.  -size for one of mate pairs\"\n"
+    "string seq;		\"Query template sequence\"\n"
+    "string qual;	\"ASCII of Phred-scaled base QUALity+33.  Just '*' if no quality scores\"\n"
+    "string tagTypeVals; \"Tab-delimited list of tag:type:value optional extra fields\"\n"
+    ")\n";