Update and add customers

Moderator: crythias

Locked
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Update and add customers

Post by kodeoneuankenobi »

Hi to everyone!

I've a question. Is there any way to update through a CSV a bunch of customers and furthermore add new customers? I was searching on the internet but didn't see nothing relevant.

The OTRS version is 3.2.9

Thanks in advance!!
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Update and add customers

Post by crythias »

OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Re: Update and add customers

Post by kodeoneuankenobi »

Thanks, but on that topic I can't see anything about updating the current customers that exists on the database... The question is that I have something like 3000 customers and I have to update some of them, also, I have to introduce a bunch of new customers...

If you can help me I would be very grateful to you
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Update and add customers

Post by crythias »

The best bet is don't do this. Link to the source data. Unless OTRS is an endpoint (but it isn't. you're constantly updating the source, or else you wouldn't have this question.)
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Re: Update and add customers

Post by kodeoneuankenobi »

What are you saying, is that I can add new customers but it's better that I don't update the existents one? :/
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Update and add customers

Post by crythias »

I am saying that it's better to link to and read/query the source data directly than to do the extract-update-add that you're doing now, unless you're only going to do this one time, or it's prohibitive to connect to the source data directly.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Re: Update and add customers

Post by kodeoneuankenobi »

I guess that it's prohibitive to connect to the source data directly because it's a CSV, not something like an AD. The OTRS is running on a CentOs 5. (Sorry if I misunderstand something or write something wrong, I'm from Spain).

I'm going to try to explain better my situation:

-We've this OTRS running on a Centos 5.
-Currently we've a lot of customers on the mysql of the OTRS
-One of our workers said that we've to update a lot of the customers that already exist and, furthermore, add a bunch of new customers

Is there any way that I can do that without crashing the OTRS? :lol:

Thanks a lot in advance!
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Update and add customers

Post by crythias »

kodeoneuankenobi wrote:-Currently we've a lot of customers on the mysql of the OTRS
OK.
kodeoneuankenobi wrote:One of our workers said that we've to update a lot of the customers that already exist and, furthermore, add a bunch of new customers
where is the source of this data? (who populated the .csv? With what data source/database? Was it typed in a big csv by a human or did you extract the data from a database?)
If you could grab the information from the source to make a csv, it's theoretically possible that OTRS could query the same source of information directly, without using csv as sneakernet.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Re: Update and add customers

Post by kodeoneuankenobi »

where is the source of this data? (who populated the .csv? With what data source/database? Was it typed in a big csv by a human or did you extract the data from a database?)
If you could grab the information from the source to make a csv, it's theoretically possible that OTRS could query the same source of information directly, without using csv as sneakernet.
The data comes from a MySQL. The worker connects through a website and downloads an .CSV. If i don't misunderstood you, you are saying that there's a way to synchronize the MySQL with the "customer_user" table of the OTRS MySQL, isn't it?

Where I can find how to do that? And, if the "customer_user" table was synchronized with the table containing the info of the other MySQL, if we add more customers to the MySQL the data will synchronize automatically and add the new info to the "customer_user" table?

Thanks for your patience!
jojo
Znuny guru
Posts: 15020
Joined: 26 Jan 2007, 14:50
Znuny Version: Git Master
Contact:

Re: Update and add customers

Post by jojo »

"Production": OTRS™ 8, OTRS™ 7, STORM powered by OTRS
"Testing": ((OTRS Community Edition)) and git Master

Never change Defaults.pm! :: Blog
Professional Services:: http://www.otrs.com :: enjoy@otrs.com
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Re: Update and add customers

Post by kodeoneuankenobi »

But this works with an external MySQL outside the centOs that hosts the OTRS?
crythias
Moderator
Posts: 10170
Joined: 04 May 2010, 18:38
Znuny Version: 5.0.x
Location: SouthWest Florida, USA
Contact:

Re: Update and add customers

Post by crythias »

It is not a synchronization. It is a direct query of the other MySQL table at the other mysql database location. You can have multiple backends.
OTRS 6.0.x (private/testing/public) on Linux with MySQL database.
Please edit your signature to include your OTRS version, Operating System, and database type.
Click Subscribe Topic below to get notifications. Consider amending your topic title to include [SOLVED] if it is so.
Need help? Before you ask
kodeoneuankenobi
Znuny newbie
Posts: 18
Joined: 05 Dec 2013, 18:17
Znuny Version: OTRS 3.1.6

Re: Update and add customers

Post by kodeoneuankenobi »

Sorry for responding 4 days later. I will try to use that solution and in a few days I'll be back to share what I've done and if it has worked.
Locked