At the db level you can add one more field to wp_users and create trigger that fills this field on row create. That said, this can cause issues with wp updates in the future.
Another option would be to create view that shows rows from wp_users and calculates that special Id for you. Afterwards, you can run queries against the view and do not interfere directly with the user table.
Related Posts:
- User registration add user ID?
- How to pass external variables to the wp_new_user_notification_email filter?
- Creating user relationships
- Function to allow “Anyone can register”?
- How to display all post from the same current usermeta
- Get id from database
- How to change the default registration email ? (plugin and/or non-plugin)
- get post author id outside loop
- Custom Walker: how to get ID in function start_lvl
- Backup the Database and Restore from the Backup?
- Integrating WordPress to my website, while keeping my own authentication system
- Modify custom Users Manage page
- How to Save Different Usermeta Fields According to User Role?
- generate unique number when registering a user
- Can I use $wpdb for my custom tables in the WordPress database?
- Adding extra info via GET while registeration in wordpress
- What Is The Difference Between suppress_errors() And hide_errors() in $wpdb?
- Prevent WordPress from loading comments
- Authenticating to WordPress, using my own authentication two-factor system
- Suggestions for WPMU Migration (advanced)
- Retrieve and display data from custom db table in admin area?
- How to find if a post with custom_field == X exists?
- Many users with strange names register, but don’t leave comments. Should I be afraid?
- Set user loggin status?
- How can I add data to a custom column in the Users section of the wordpress backend?
- Unique User Account Number + Displayed Via Shortcode
- What’s the proper way to use a custom table? [closed]
- How to retrieve the value stored in a multi-dimensional array and SUM the entries?
- How can I get the page url slug when ‘post_name’ returns an id?
- Last time a user logged in
- Remove the deleted users avatar from list
- Adding a Table to the wordpress database
- Updating Custom WordPress User Meta Field via REST API
- How can I allow access to multiple users, using the same login, at the same time?
- WP Northwind for Theme Development?
- Add custom user profile field to default WordPress MultiSite registration form
- What’s wrong with Customizing new user notification email by add_filter?
- Make custom user table column filterable
- Add ‘Creator’ User Meta when adding user
- Follow me for WordPress blogs (multi-authors)
- Fastest way to get the comment and ping total count for a post
- I want to submit multiple users if checkbox is checked
- Change the Labels of Users to Customers in Admin
- user_profile_update_errors hook not executing
- $wpdb->replace: WHERE?
- How Can I Move Data From Form 1 To Form 2
- Auto login from custom registration form
- Diffrent User registration form for doctor and patient
- User can not login
- Allow guests to use WP Customizer but disable save button
- Users can only view their content from the front end
- List top 5 authors with most posts
- Multi-site User Sessions
- Your thoughts on the interaction with one custom database table from WP?
- Add Field to WordPress Register Form
- How do I have now a duplicated user entry if this is not allowed (and I cannot replicate it)?
- Customizing Users in Admin Area
- Applying WP-cli Search & Replace to Static SQL Dump File
- Setup database structure with books, authors, languages etc. for publishing house [closed]
- Add table to WordPress database
- Custom login and registration forms
- How to display page ids as page slug names?
- Create Unique ID for user
- Custom Database Table and foreach
- Custom Register Link on Backend Form
- Personalized Gallery what are my options?
- how or where wordress collect unlogged user session
- Hook before user is created and make some custom validation
- How to change the login page without a plugin and not only customizing logo and text around the form?
- How to get Previous Visited Page Information
- optimal taxonomy or custom post types
- No plugin populate user information in to form
- How to block specific user id in custom login form?
- What is my error trying to create a new table in the database?
- Invitation link to a site in multisite network does not work?
- New Page/Post Screen Opens an Existing Post
- Safely changing UserID’s, re-using deleted UserID’s and automatically using deleted userID’s instead of an increment
- WP_User_Query Search Multiple Keywords from a Multi-Select Field?
- Advice on how to structure a custom plugin
- How to have differents sites share the same tables of DB?
- Custom Form Input not saving to Database
- Accountless password generation
- Highlight specific user with custom field value
- Associating special meaning with user id 0
- Add several fields from different tables to post, fields per post are in same row of table
- Where should I put this custom data?
- Show WP content on different PHP Sites
- Change the functionality of wordpress users module in admin
- Custom user fields validation on registration
- Custom options – register, defaults and delete empty fields (Settings API)
- add unique code required to register
- Custom search by several options send on form not works
- Accessing + retrieving custom database in WordPress
- How to create functions that affect only a specific user
- Create users via PHP
- Use wp_login_form function to login with a custom user table?
- Advice how to connect custom database with WordPress, change data in WordPress and finaly use this data
- Is it possible assign a secondary existing role to already existing one?
- Changes to code not displaying
- User Query Multiple Orderby Clause