Version 16.1.1

This commit is contained in:
Antonio Cañas Vargas 2016-09-22 02:02:19 +02:00
parent 27a0ea16d4
commit d815c46a50
2 changed files with 4 additions and 3 deletions

View File

@ -139,13 +139,14 @@
/****************************** Public constants *****************************/
/*****************************************************************************/
#define Log_PLATFORM_VERSION "SWAD 16.1 (2016-09-22)"
#define Log_PLATFORM_VERSION "SWAD 16.1.1 (2016-09-22)"
#define CSS_FILE "swad15.229.css"
#define JS_FILE "swad15.238.1.js"
// Number of lines (includes comments but not blank lines) has been got with the following command:
// nl swad*.c swad*.h css/swad*.css py/swad*.py js/swad*.js soap/swad*.h sql/swad*.sql | tail -1
/*
Version 16.1.1: Sep 22, 2016 Index optimization in tables of users' courses. (204829 lines)
Version 16.1: Sep 22, 2016 Temporary table with other user's courses. (204828 lines)
Version 16.0: Sep 22, 2016 Temporary table with my courses.
Added indexes to database. (204811 lines)

View File

@ -922,7 +922,7 @@ bool Usr_CheckIfUsrSharesAnyOfMyCrsWithDifferentRole (long UsrCod)
/***** Create temporary table with all user's courses for a role *****/
sprintf (Query,"CREATE TEMPORARY TABLE IF NOT EXISTS usr_courses_tmp "
"(CrsCod INT NOT NULL,Role TINYINT NOT NULL,"
"UNIQUE INDEX(CrsCod),INDEX(Role)) ENGINE=MEMORY"
"UNIQUE INDEX(CrsCod,Role)) ENGINE=MEMORY"
" SELECT CrsCod,Role FROM crs_usr WHERE UsrCod='%ld'",
UsrCod);
if (mysql_query (&Gbl.mysql,Query))
@ -1111,7 +1111,7 @@ void Usr_GetMyCourses (void)
"(CrsCod INT NOT NULL,"
"Role TINYINT NOT NULL,"
"DegCod INT NOT NULL,"
"UNIQUE INDEX(CrsCod),INDEX(Role)) ENGINE=MEMORY"
"UNIQUE INDEX(CrsCod,Role,DegCod)) ENGINE=MEMORY"
" SELECT crs_usr.CrsCod,crs_usr.Role,courses.DegCod"
" FROM crs_usr,courses,degrees"
" WHERE crs_usr.UsrCod='%ld'"