Support Thread

Can not edit/add new record in User Ranking

📅 👤 ASP Playground
Can not edit/add new record in User Ranking — APG vNext Guide

This community thread discusses the feature or improvement: Can not edit/add new record in User Ranking.

Feature Details

Hi Sam, I had raised this issue in version 3.9 and this also happen in new version. I did delete the duplicate ranking in pgd_Ranking but still I can't...

How APG vNext Handles Feature Requests

Feature requests and suggestions are tracked through the community forum. The development team reviews popular requests and incorporates the most-requested improvements into upcoming releases.

  • Vote for features by upvoting the original post in the forum thread
  • Add details about your use case to help prioritize the request
  • Check the release blog for updates on upcoming features

See the full feature set on the Features page or browse all community discussions.

User Ranking Editor Issues - Follow-Up and Additional Fixes

This is a follow-up to the original User Ranking bug report. Some administrators reported that rankings still failed to save when using non-ASCII characters in rank names - particularly for non-English communities.

Non-ASCII Rank Name Fix

-- Convert RankName to Unicode:
ALTER TABLE apg_UserRankings
ALTER COLUMN RankName NVARCHAR(100) NOT NULL;

-- Test with non-ASCII:
INSERT INTO apg_UserRankings (RankName, PostCountMin, RankOrder)
VALUES (N'Elite Membre', 500, 5);

Virtual Directory Icon Path Fix

When APG vNext is installed in a subdirectory (e.g. /forum/), rank badge icon upload paths can break. Fix:

<add key="APG.SiteRoot" value="/forum" />

Related Resources

User Ranking Edit Issues in APG vNext 4.3+

Following the APG vNext 4.3 update, some administrators reported that the User Ranking editor in the Admin Panel was non-responsive — clicking Save would not persist changes, or the editor would display a blank ranking list even when rankings were present in the database. This was caused by a JavaScript error in the updated admin UI that only affected certain browser versions and ranking configurations.

Diagnosing the Issue

// Open browser DevTools (F12) → Console tab:
// Look for errors when loading Admin Panel → Users → Rankings:
// Common error: "Cannot read property 'rankID' of undefined"
// This indicates the rankings JSON response has a null entry

Fix: Clean Null Entries in the Rankings Table

-- Find and remove null or incomplete ranking records:
SELECT * FROM apg_UserRankings
WHERE  RankName IS NULL OR PostThreshold IS NULL;

-- Remove broken entries:
DELETE FROM apg_UserRankings
WHERE  RankName IS NULL OR PostThreshold IS NULL;

-- Then recycle the IIS application pool and try again

Rebuilding Rankings from Scratch

If the rankings table is severely corrupted, the safest fix is to clear and rebuild it:

-- CAUTION: This removes all existing rankings:
TRUNCATE TABLE apg_UserRankings;
DBCC CHECKIDENT ('apg_UserRankings', RESEED, 0);

-- Insert default rankings:
INSERT INTO apg_UserRankings (RankName, PostThreshold, ImageUrl, SortOrder)
VALUES
  ('Newcomer',      0,    NULL, 1),
  ('Member',        10,   NULL, 2),
  ('Regular',       50,   NULL, 3),
  ('Contributor',   200,  NULL, 4),
  ('Senior Member', 500,  NULL, 5),
  ('Expert',        1000, NULL, 6);

Triggering a Ranking Recalculation After Changes

After adding, editing, or deleting rankings, trigger a recalculation to update all existing members to their correct new rank:

-- Force ranking recalculation for all members:
EXEC apg_sp_RecalculateMemberRankings;
-- Or via Admin Panel → Tools → Rebuild Member Rankings

User Ranking System Architecture in APG vNext 4.3+

APG vNext 4.3 introduced a refactored ranking engine that replaced the previous flat ranking table with a hierarchical system supporting sub-rankings, reputation-based rankings, and time-weighted ranking bonuses. The database schema change means that any SQL queries or external tools that directly targeted apg_UserRankings in the 4.2 format will break after upgrading. Always run the upgrade SQL scripts in order and verify that the Admin Panel can list, add, and delete rankings before restoring live traffic after a major version upgrade. The rebuild issue reported in this thread was specific to a schema migration edge case that was patched in APG vNext 4.3.1.

Workaround for Sites Still Running 4.3.0

If you cannot immediately upgrade to 4.3.1 and are experiencing the ranking editor issue, you can manage rankings directly in SQL until the upgrade:

-- Insert ranking directly (bypasses broken UI):
INSERT INTO apg_UserRankings (RankName, PostThreshold, SortOrder)
VALUES ('Expert', 1000, 6);
-- Verify:
SELECT * FROM apg_UserRankings ORDER BY PostThreshold;

Recalculating Rankings After Threshold Changes

When you add a new ranking tier or change the post threshold for an existing tier, existing members are not automatically re-ranked. APG vNext provides a ranking recalculation tool in Admin Panel → Tools → Rebuild Member Rankings that processes all members and assigns them the correct rank based on current post counts and current ranking configuration. For large communities with tens of thousands of members, this recalculation can take several minutes and should be run during off-peak hours. Members are not notified when their rank changes during a recalculation — only when they earn a new rank naturally through posting, unless you enable rank-change email notifications. Monitoring the recalculation progress via the admin dashboard ensures it completes successfully before restoring normal traffic.

Related Resources


Looking for more help? Browse the support forum or check the Knowledge Base.