How do I merge Printers/Users/Databases in PaperCut?

KB Home   |   How do I merge Printers/Users/Databases in PaperCut?

Main.MergingData History

Hide minor edits - Show changes to output

July 01, 2015, at 05:56 PM by TimG - Added side note about amalgamating print queues
Added lines 12-13:

If you genuinely have multiple 'live' print queues for the same printers (e.g. 2 workstations have the Secondary Server agent installed and have queues pointing to the same printer) then you can also [[https://www.papercut.com/kb/Main/AmalgamatePrinterQueues|Amalgamate Print Queues]] by configuring the PaperCut print provider - this is normally only used in specific circumstances, or small office setups.
June 30, 2015, at 10:12 PM by TimG - Created merging data article
Added lines 1-41:
(:title How do I merge Printers/Users/Databases in PaperCut? :)

!!Merging Printers

PaperCut printers are separate records in the database, and merging them is not currently supported. The primary printer identifier is the @@servername\printername@@ combination as explained [[https://www.papercut.com/products/ng/manual/ch-printer-mgmt-renaming.html|here]].

If you've [[https://www.papercut.com/kb/Main/MigratingNGToNewServer|migrated to a new server]] and you're now finding that you have duplicate printers e.g. @@oldservername\printer1@@ and @@newservername\printer1@@ showing up in PaperCut under the 'Printers' tab, then the best way around that is to:
* Delete the newest entry of the printer (which should be the one with the least amount of job history) - e.g. @@newservername\printer1@@
* [[https://www.papercut.com/kb/Main/HowToRenameAPrinter|Rename]] the old printer name to the new printer name - e.g. rename @@oldservername\printer1@@ (which has all the previous printing history) to @@newservername\printer1@@
* Now when you print to printer1 it will continue to log to that same record with all the previous history
''Note - always a good idea to [[https://www.papercut.com/products/ng/manual/ch-sys-mgmt-backups.html|take a database backup]] before deleting anything from PaperCut!''

!!Merging Users

PaperCut users are separate records in the database, and merging them is not currently supported. The primary user identifier is the username in this case - GUIDs do not come into the picture, as explained [[https://www.papercut.com/kb/Main/RenameUserAccounts|here]].

If you've [[https://www.papercut.com/kb/Main/RenameUserAccounts|renamed users in AD/LDAP]] and you're now seeing multiple records for the same user under the 'Users' tab in PaperCut, the best way around that is to:
* Delete the user entry with the new name (hopefully very little printing history at this point)
* [[https://www.papercut.com/kb/Main/RenameUserAccounts|Rename]] the old username to the new username
* Now when that user prints it will continue to log against that new username, and will retain all their previous printing history
''Note - always a good idea to [[https://www.papercut.com/products/ng/manual/ch-sys-mgmt-backups.html|take a database backup]] before deleting anything from PaperCut!''

There may also be cases where you see multiple users with the same username listed on some reports - this is discussed in the 3rd question on the [[https://www.papercut.com/kb/Main/ReportDataFAQ|Report Data FAQs]] page.

!!Merging Databases

Merging two separate databases is a very complex task and not something we currently support. For example, on a technical level there are issues such as clashing primary keys, re-indexing, data normalization, conflicting printer names, etc. Technically merging would be possible, but a very large development effort.

The only workaround would be to export user data / job data from one system, and import it into the other system. For example use one of the CSV/Excel reports e.g. Reports -> User -> User Printing - Logs, and export all of the print job details from one system (that report lists each individual job, who printed it, how many pages, the cost, and other attributes).

You can then use the [[https://www.papercut.com/products/ng/manual/apdx-tools-importing-jobs.html|Import job process]] or the [[https://www.papercut.com/products/ng/manual/ch-user-mgmt-import-update.html|Batch User Import/Update]] process to pull all that old job data / user data into the other database.

The end result is that you've exported all the job information from database 1, and you're re-playing that job data back into database 2.

As there are normally thousands of rows of job data, we'd recommend doing all the data manipulation in Excel to create the server command to import the job information - then you can export the Excel sheet as a text file, rename it as a batch file, and run that to process all the jobs as individual commands.


----
''Categories:'' [[Category.Databases|+]], [[Category.Administration|+]]
----
[-Keywords: merge, merging, combine, combining, renaming -]

Comments

Share your findings and experience with other PaperCut users. Feel free to add comments and suggestions about this Knowledge Base article. Please don't use this for support requests.

Article last modified on July 01, 2015, at 05:56 PM
Printable View   |   Article History   |   Edit Article