Remove unused tables
This commit is contained in:
@@ -66,10 +66,6 @@ function hasDataAssociated($iUserId)
|
|||||||
$hResult = query_appdb($sQuery);
|
$hResult = query_appdb($sQuery);
|
||||||
if(mysql_num_rows($hResult)) return true;
|
if(mysql_num_rows($hResult)) return true;
|
||||||
|
|
||||||
$sQuery = "SELECT * FROM appOwners WHERE ownerId = $iUserId";
|
|
||||||
$hResult = query_appdb($sQuery);
|
|
||||||
if(mysql_num_rows($hResult)) return true;
|
|
||||||
|
|
||||||
$sQuery = "SELECT * FROM appVotes WHERE userId = $iUserId";
|
$sQuery = "SELECT * FROM appVotes WHERE userId = $iUserId";
|
||||||
$hResult = query_appdb($sQuery);
|
$hResult = query_appdb($sQuery);
|
||||||
if(mysql_num_rows($hResult)) return true;
|
if(mysql_num_rows($hResult)) return true;
|
||||||
|
|||||||
@@ -6,7 +6,6 @@ drop table if exists vendor;
|
|||||||
drop table if exists appFamily;
|
drop table if exists appFamily;
|
||||||
drop table if exists appVersion;
|
drop table if exists appVersion;
|
||||||
drop table if exists userExperience;
|
drop table if exists userExperience;
|
||||||
drop table if exists apiUsage;
|
|
||||||
drop table if exists appCategory;
|
drop table if exists appCategory;
|
||||||
drop table if exists appHitStats;
|
drop table if exists appHitStats;
|
||||||
drop table if exists catHitStats;
|
drop table if exists catHitStats;
|
||||||
@@ -14,10 +13,8 @@ drop table if exists appComments;
|
|||||||
drop table if exists appData;
|
drop table if exists appData;
|
||||||
drop table if exists appDataQueue;
|
drop table if exists appDataQueue;
|
||||||
drop table if exists appQueue;
|
drop table if exists appQueue;
|
||||||
drop table if exists appCrosslink;
|
|
||||||
drop table if exists appBundle;
|
drop table if exists appBundle;
|
||||||
drop table if exists appVotes;
|
drop table if exists appVotes;
|
||||||
drop table if exists appRating;
|
|
||||||
drop table if exists appNotes;
|
drop table if exists appNotes;
|
||||||
drop table if exists sessionMessages;
|
drop table if exists sessionMessages;
|
||||||
|
|
||||||
@@ -90,13 +87,6 @@ create table userExperience (
|
|||||||
wineCfgFile text,
|
wineCfgFile text,
|
||||||
key(uExpId)
|
key(uExpId)
|
||||||
);
|
);
|
||||||
|
|
||||||
create table apiUsage (
|
|
||||||
apiUsageId int not null auto_increment,
|
|
||||||
versionId int not null,
|
|
||||||
apiid int(11) not null,
|
|
||||||
key(apiUsageId)
|
|
||||||
);
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
@@ -111,17 +101,6 @@ create table appCategory (
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* not used yet
|
|
||||||
*/
|
|
||||||
create table appCrosslink (
|
|
||||||
appId int not null,
|
|
||||||
catId int not null,
|
|
||||||
key(appId),
|
|
||||||
index(catId)
|
|
||||||
);
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* bundleId is the appId of the 'owner app'
|
* bundleId is the appId of the 'owner app'
|
||||||
*/
|
*/
|
||||||
@@ -226,22 +205,6 @@ create table appVotes (
|
|||||||
);
|
);
|
||||||
|
|
||||||
|
|
||||||
/*
|
|
||||||
* app ratings
|
|
||||||
*/
|
|
||||||
create table appRating (
|
|
||||||
id int not null auto_increment,
|
|
||||||
time timestamp, /* we might wanna expire old ratings */
|
|
||||||
versionId int not null,
|
|
||||||
userId int not null,
|
|
||||||
system enum('windows', 'fake'),
|
|
||||||
score int not null,
|
|
||||||
key(id),
|
|
||||||
index(versionId),
|
|
||||||
index(userId)
|
|
||||||
);
|
|
||||||
|
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* application notes
|
* application notes
|
||||||
*/
|
*/
|
||||||
|
|||||||
@@ -1,7 +0,0 @@
|
|||||||
SELECT appVersion.appId, appVersion.versionId, appName, versionName, avg(score) as rating, count(appVersion.versionId) as hits
|
|
||||||
FROM appRating, appFamily, appVersion
|
|
||||||
WHERE (appVersion.versionId = appRating.versionId
|
|
||||||
AND appFamily.appId = appVersion.appId)
|
|
||||||
AND system = 'fake' AND rating = 5
|
|
||||||
GROUP BY appVersion.versionId
|
|
||||||
ORDER BY appName ASC
|
|
||||||
Reference in New Issue
Block a user