d2800e10690b66bf2ab04804e124958459f0ff0d chmalee Thu Nov 7 11:11:15 2024 -0800 Add a parentDir field to the hubSpace table and make an index on it diff --git src/hg/inc/hubSpace.h src/hg/inc/hubSpace.h index 879bc01..8134a5f 100644 --- src/hg/inc/hubSpace.h +++ src/hg/inc/hubSpace.h @@ -8,34 +8,34 @@ #include "jksql.h" #define HUBSPACE_NUM_COLS 10 extern char *hubSpaceCommaSepFieldNames; struct hubSpace /* file storage table for users to store uploaded tracks */ { struct hubSpace *next; /* Next in singly linked list. */ char *userName; /* userName of user uploading file */ char *fileName; /* name of uploaded files. The actual path to this file is different */ long long fileSize; /* size of the uploaded file */ char *fileType; /* track type of file */ char *creationTime; /* first upload time */ char *lastModified; /* last change time */ - char *hubNameList; /* comma separated list of hubs this file is a part of */ char *db; /* genome assembly associated with this file */ char *location; /* file system path or URL to file */ char *md5sum; /* md5sum of file */ + char *parentDir; /* parent directory of file */ }; void hubSpaceStaticLoad(char **row, struct hubSpace *ret); /* Load a row from hubSpace table into ret. The contents of ret will * be replaced at the next call to this function. */ struct hubSpace *hubSpaceLoadByQuery(struct sqlConnection *conn, char *query); /* Load all hubSpace from table that satisfy the query given. * Where query is of the form 'select * from example where something=something' * or 'select example.* from example, anotherTable where example.something = * anotherTable.something'. * Dispose of this with hubSpaceFreeList(). */ void hubSpaceSaveToDb(struct sqlConnection *conn, struct hubSpace *el, char *tableName, int updateSize); /* Save hubSpace as a row to the table specified by tableName.