Skip to content

Commit

Permalink
Add index for each score. Move to 2.0.1
Browse files Browse the repository at this point in the history
  • Loading branch information
tmcgowan committed Mar 28, 2018
1 parent d4262bc commit 16d49e1
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 1 deletion.
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
apply plugin: 'java'

group = 'edu.umn.msi.gx'
version = '2.0.0'
version = '2.0.1'

description = """
New mzToSQLite removing DOM reading/building and using SAX reading only.
Expand Down
11 changes: 11 additions & 0 deletions src/main/java/edu/umn/msi/gx/database/MetaTableManager.java
Original file line number Diff line number Diff line change
Expand Up @@ -238,6 +238,17 @@ public static void createPSMTable() {
//CREATE INDEX PSMBySeq ON psm_entries(sequence)
stmt.executeUpdate("CREATE INDEX PSMBySeq ON psm_entries(sequence)");
stmt.executeUpdate("CREATE INDEX PSMByPepRef ON psm_entries(id)");

//CREATE an INDEX for each score.
int sIDX = 0;
for (String sn : scoreTypes.keySet()) {
if (scoreTypes.get(sn).matches("REAL")) {
String idxSql = "CREATE INDEX PSMByScore_" + sIDX + " ON psm_entries(\"" + sn + "\")";
logger.info("Creating >> %s", idxSql);
stmt.execute(idxSql);
sIDX++;
}
}
stmt.close();
MetaTableManager.dbMgr.conn.commit();

Expand Down

0 comments on commit 16d49e1

Please sign in to comment.