How to Export a Definite Number of WooCommerce Users using Offset and Limit
WooCommerce users can be exported very easily using the WordPress Users & WooCommerce Customers Import Export Plugin. The plugin is equipped with several predefined filters by which you can export user-specific data only. One among them is the ability to export only a definite number of users using the offset and limit functionality.
First of all, you will have to install and activate the plugin. From your dashboard, navigate to the WooCommerce > Customer Import/Export. The user import export window appears, now click on export.
Users can be exported in just two very simple steps. The window to export the users appears as shown below:
In the first step, you have the option to filter the data that you want to export in the CSV file. You can filter the data that are exported based on the following fields:
- Offset: Enter the user row number at which you wish to start the export.
- Limit: Enter the maximum number of users that you wish to export.
For instance, if you want to export users by skipping the first 5 records and including the rest of the 10 users consecutively, then enter 5 in offset and 10 in the limit field.
- Some of the other filters that are available in the plugin are as follows:
- User Roles: Select user roles for which you want to export details from the given list: If no roles are selected, then all users will be exported.
- From Date: Select the date of registration from which you want to export the users by clicking on the calendar icon.
- To Date: Select the date of registration until which you want to export the users by clicking on the calendar icon.
After you have entered the required filter click on the Apply Filter button. You will be able to see a preview of the selected users on the right-hand side of the page. Clicking on the reset button will clear all the filters that you have applied.
After the required filters have been applied, you can proceed to the second step by clicking on Step 2: Map and Transform button. This will take you to the following screen.
- Select a mapping file for export: Similar to import settings, you can select an existing mapping file for export. This option is enabled only when you create your first mapping file on any of the prior user exports.
- Columns: Select the checkbox for required columns if you want to export specific columns. With the Column Name field, you can modify the column header in the CSV file. To do that, simply enter the required column name for the specific column.
- Save the export mapping: Enter a mapping filename for exporting.
- Delimiter: With this field, you can change the comma-separated file to ‘|’ or ‘.” separated file according to your requirement.
- Export Guest Users: Check this option if you want to export the guest users of your website to be exported to the CSV file.
- Include hidden metadata: Check this option to include hidden metadata from the third-party plugins.
- Enable FTP export to export users from an FTP server.
- Click Export Users, the CSV file gets auto-downloaded to your computer. The exported CSV file is as shown below: