Jump to content

How to change Client ID


Jam

Recommended Posts

8 hours ago, Jam said:

Is it possible to change the Client ID in WHMCS? 

no - it's going to be an integer field (number only) and its value will be referenced in multiple database tables - so existing values shouldn't be changed .

if they had no services/domains/invoices etc, then potentially you could change the value to another number, but I wouldn't even bother as there is zero gain in doing so and lots of potential pain if you get it wrong.

8 hours ago, Jam said:

I want to change the Client ID number into LC002. 

if the client ID is ever shown in the client area, invoice etc (can't recall if it is or not by default), then those id values could be cosmetically changed with a hook or template tweak..

you could also change the auto increment value (either via a SQL query of phpmyadmin etc) if you want to give the impression that you have more clients, e.g instead of the next client being given #12, you could update the tblclients table so that they're given #2000 or whatever.

Link to comment
Share on other sites

  • 1 month later...

I have a fresh install of WHMCS. I deleted the first test client and now I am seeing id 2 and id 3.  So my 1 is 2 and 2 is 3 and so forth.  In other words, no way to put in order starting with 1 id.  No problem just checking before I set the affiliate area.  Thanks Stanley

image.thumb.png.db79e43bf2e93e21b5c888b63e37af33.png

Link to comment
Share on other sites

15 hours ago, Stanley said:

I have a fresh install of WHMCS. I deleted the first test client and now I am seeing id 2 and id 3.  So my 1 is 2 and 2 is 3 and so forth.  In other words, no way to put in order starting with 1 id.  No problem just checking before I set the affiliate area. 

as @bear says, that would be expected behaviour.

how to reset the database after your initial testing is outlined in the doc below - it would wipe those two existing clients from the database, so you would have to enter their details again... but their IDs would then be 1 & 2 instead of 2 & 3.

https://docs.whmcs.com/Maintenance#Resetting_your_database

Link to comment
Share on other sites

19 hours ago, bear said:

Most of the time IDs in a database are auto incrementing, and removing one won't remove the ID for a number of reasons. It goes in order, and once it's used, that's that. 

Thank you for your response to my question.  I appreciate the insight. 

Link to comment
Share on other sites

7 hours ago, brian! said:

as @bear says, that would be expected behaviour.

how to reset the database after your initial testing is outlined in the doc below - it would wipe those two existing clients from the database, so you would have to enter their details again... but their IDs would then be 1 & 2 instead of 2 & 3.

https://docs.whmcs.com/Maintenance#Resetting_your_database

Thank you.  I will go ahead and gives this a shot.

Link to comment
Share on other sites

  • 3 years later...

Hello,

I dont know if it is still an issue, but i tried the same and it worked for me like that:

- create a random user (e.g. test...). This user will have the ID #1...

- log in in your database (e.g. MySQL via phpMyAdmin) and search for your first user in "tblclients" and change the value of "id" to a random  number (e.g. 1234).

- apply by "go".

In WHMCS your first USER will have Client ID "1234" and next one will have "1235".

I tested it with a new installation of WHMCS v8.7.3. No User was applied before... fresh install...

Christian

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...

Important Information

By using this site, you agree to our Terms of Use & Guidelines and understand your posts will initially be pre-moderated