Improved Import Magento 2 Extension Manual

- Magento 2, Our extensions
 

Improved Import / Export extension for Magento 2 provides a possibility to import your csv files with products data and product images to Magento 2 from a remote FTP / SFTP server, Dropbox or a direct URL of a source CSV file as well as offers a dedicated categories import from CSV files, on the fly import of product attribute values, cron jobs import, and more!

Complete features list of Improved Import Magento 2 Extension

  1. Import csv files with data for import from remote FTP / SFTP server, Dropbox or direct URL
  2. Import product images from remote FTP / SFTP, Dropbox or direct URL of product image
  3. Dedicated simple categories import from CSV file (by default in M2 categories can be imported only together with assigned products)
  4. Creation of new products attributes on the fly during import process
  5. Creation of new attribute values on the fly – if attribute value don’t exist on Magento 2 data base – it will be created during the products import process
  6. Con jobs for any kind of import (products , categories, customers , stock,  attributes etc.) – flexible and extremely powerful feature of Magento 2 Enterprise Edition available for Community Edition!
  7. Full support of Import configurable products – files can be placed locally or imported by remote URL source
  8. Import fields mapping (in Magento 1.x style!) – you can map Magento 2 product attributes to any custom CSV column in your file! Fully flexible and powerful way to import custom data structures in Magento!

Buy Improved Import Magento 2 Extension

Improved Import Magento 1 Extension

Firebear Import Export Extension FAQ

Cron import Magento 2 , categories import Magento 2

We provide professional installation services for our Magento 2 extensions – get your extension work right after the purchase!

  1. Installation
  2. Standard Magento 2 import
  3. Extension Configuration
  4. Import from FTP / SFTP and Dropbox
  5. Run import process
  6. Import by Cron – Import jobs
  7. Standard Cron configuration in Magento 2
  8. Categories import
  9. Product attribute values on the fly import
  10. Product attributes import – creation of new attributes on the fly during the product import
  11. Import configurable products
  12. Magento CLI Import Commands
  13. CSV File samples
  14. Improved Import for Magento 2 Use Case Example
  15. Import fields mapping (in Magento 1.x style!)  

Installation

1. Backup your web directory and Magento 2 store database;

2. Download Improved Import installation package;

3. Copy files to /app/code/Firebear/ImportExport/ folder (create it if not exist!)

4. Navigate to your store root folder in the SSH console of your server:

cd path_to_the_store_root_folder

run:

Only if you want to use Dropbox features :

then:

and:

5. Flush store cache; log out from the backend and log in again.

Standard Magento 2 import

Before going any further with Improved Import, make sure you have read manuals and understand what to do with the default Magento 2 import procedure!

Extension Configuration

Magento admin -> Stores -> Configuration -> Firebear Studio -> Import / Export

Stores Configuration

Import Export

Here, you can configure Dropbox API details and FTP / SFTP credentials for catching source CSV files and images. Such configured sources as Dropbox and FTP/ SFTP will be available during the import procedure configuration on the Source dropdown:

Source dropdown

Dropbox configuration

 

Create Dropbox API Application

Dropbox API Application

FTP / SFTP Configuration

Define FTP / SFTP host , login, and password.

FTP host

Path to the CSV file on a remote FTP server or Dropbox can be selected before running the import process

Path to the CSV file

Run import process

  • Go to System -> Import and select an entity type – Products, Categories, or Customers
  • Configure import behaviour (add , update , replace , delete) and select CSV file separator
  • Select a source for the csv file – Dropbox, FTP, Custom URL

Run import process

  • A path to the csv file should be specified from the root folder of your source (Dropbox or FTP), for instance “/import/sample.csv” means that you have a root folder on your Dropbox account called Import.
  • Images should be located in the same folder or a subfolder where the csv file is placed. Thus, if you have images in the same with the csv file folder, use only image names (“image.jpg”) without any path to indicate images for import.

For example, if you have a folder named “magento_import” in the root of your Dropbox folder with the “products.csv” file with product data, then the correct File Path is “/magento_import/products.csv”, and if images are located in the same folder, use only their names (“picture.jpg”). If you create a subfolder for images in the “import” folder named “img”, then the path to the image in a csv file should look as follows: “img/picture.jpg”

  • For the URL source, you should provide a direct URL to your csv file: http://site.com/import/products.csv
  • When the configuration is complete, you can check data and run the import process

Import by Cron – Import Jobs

The Import Jobs feature allows you to run any kind of import processes via a scheduled cron job with configured frequency. Go to:

Magento admin -> Configuration -> Import Jobs

Import Jobs

Here you can see and manage all Import Cron jobs:

all Import Cron jobs

  • Job ID
  • Title of cron job
  • Status – Enabled or Disabled
  • Cron column showing frequency of jobs running in a cron format
  • Frequency of running in a human format: Day , Hour , Week etc.
  • Entity type of imported data – products, categories, customers
  • Import source – Local file, Dropbox, FTP, Url
  • Action: Delete or Edit import cron job

Click Add New Job to add a new process:

Click Add New Job to add a new process

Configure import parameters:

  • Title of Import Job – use a clean self explanatory title that will be easily understandable in future 😉
  • Select a preset frequency of import:
    • Every minute (*/1 * * * *)
    • Every hour (* */1 * * *)
    • Every day at 3:00am (0 3 * * *)
    • Every Monday at 3:00am (0 3 * * 1)
    • Every 1st day of month at 3:00am (0 3 1 * *)
    • Custom
  • The custom format of a Cron job can be configured with the help of the standard Cron syntax:

Cron syntax

More info and cron config generators :

    1. https://en.wikipedia.org/wiki/Cron
    2. http://crontab-generator.org/
    3. http://www.cronmaker.com/
    4. http://stackoverflow.com/questions/18919151/crontab-day-of-the-week-syntax
  • Select import behaviour : add , update , replace , delete entities
  • Make sure you have configured cron!

Standard Cron configuration for Magento 2:

Double check configuration and save a new Job.

Categories import

Categories can be imported with different behaviour – Add / Edit , Delete, and Replace which allow flexible category manipulations.

To import categories to Magento 2 you need a file with on the following structure: Download sample CSV files for categories import to Magento 2

            Category import offers different opportunities, so you can set a category position and location:

  • Import by name and full path to category  (Default Category/Women/Dresses);
  • Import by category name & path to category
  • Import by parent category id (parent_id)

CSV file columns: 

    • name – Category name
    • Parent_id – existing parent category id
    • url_key – URL keys of category
    • Description – category description
    • Is_active – category Enabled / Disabled
    • Include_in_menu – include category to main menu on frontend
    • Is_anchor –  Is Anchor – required for displaying layered navigation on category
    • Custom_layout_update – custom XML layout update for category

Once extension installed and enabled – you will have categories on entities dropdown for import :

magento 2 categories import

Product attribute values on the fly import

Product attribute values which is do not exist in your Magento 2 database will be automatically created on the basis of info from a product import CSV file. Default Magento 2 requires creating product attributes manually before importing products with them. This feature can save tons of time on large amount of products with different attribute values to Magento 2.

Product attributes import – creation of new attributes on the fly during the product import

The idea behind the import of product attributes to Magento 2 on the fly during the product import is pretty simple and common – instead of having only attribute name on a column with attributes we add all data required for attribute creation there. For instance, attribute set, frontend labels, scopes, etc. You can find a structure sample and a sample CSV file below. Please follow the examples carefully and import CSV file with products first. If it works correctly, you can create a custom attribute column and add new attributes. This will reduce possible problem, debug time, and time necessary to fix issues.

The general format of an attribute creation column can be described as follows:

attribute name | attribute property name : attribute property value | …

On the table below, you will find each property required for attribute creation in Magento 2 during import process as well as appropriate possible values. As you can see, only attribute set and frontend label are required for creating attribute in Magento 2 during the import process. Another quite important attribute property is attribute code which actually define the type of your attribute (text field, dropdown etc). If you do not specify it, attribute will be created with type XXX

Download CSV file sample for import product attributes on the fly

Column name example: 

Code Description Default value Required type Values
attribute_set Attribute Sets
Comma separated attribute sets names
Yes text For example: Default,Accessories
frontend_label_0 Default label Yes text
frontend_label_[n] Default label for specified store
Where [n] is the store id
text
frontend_input Catalog Input Type for Store Owner select text: Text Field
textarea: Text Area
date: Date
boolean: Yes/No
multiselect: Multiple Select
select: Dropdown
price: Price
media_image: Media Image
swatch_visual: Visual Swatch
swatch_text: Text Swatch
weee: Fixed Product Tax
attribute_code Attribute Code
This is used internally. Make sure you don’t use spaces or more than 30 symbols.
text
is_required Values Required 0 yes/no 1, 0
is_global Scope
Declare attribute value saving scope
0 select 0: Store View
1: Global
2: Website
default_value_text Default Value
Used for text attributes
text
default_value_textarea Default Value
Used for textarea attributes
text
default_value_date Default Value
Used for date attributes
text Format: mm/dd/YYYY (04/19/2016)
default_value_yesno Default Value
Used for yes/no attributes
yes/no 1,0
is_unique Unique Value
Not shared with other products
0 yes/no 1,0
frontend_class Input Validation for Store Owner select validate-number
validate-digits
validate-email
validate-url
validate-alpha
validate-alphanum
is_used_in_grid Add to Column Options 1 yes/no 1,0
is_filterable_in_grid Use in Filter Options 1 yes/no 1,0
is_searchable Use in Search 0 yes/no 1,0
search_weight Search Weight integer
is_visible_in_advanced_search Visible in Advanced Search 0 yes/no 1,0
is_filterable Use in Layered Navigation 0 yes/no 1,0
is_filterable_in_search Use in Search Results Layered Navigation 0 yes/no 1,0
position Attribute position in layered navigation integer
is_used_for_promo_rules Use for Promo Rule Conditions 0 yes/no 1,0
is_html_allowed_on_front Allow HTML Tags on Storefront 1 yes/no 1,0
is_visible_on_front Visible on Catalog Pages on Storefront 0 yes/no 1,0
used_in_product_listing Used in Product Listing 0 yes/no 1,0
used_for_sort_by Used for Sorting in Product Listing 0 yes/no 1,0

products_2_add_with_new_attributes – import of product attributes – CSV file structure sample: 

 

Import downloadable products in Magento 2

Files for downloadable products can be imported in two ways:

1. Import files from remote URL for downloadable products – you need to specify full URL to file on CSV file and make sure following directory is exist and writable  /pub/media/downloadable/links/files/
2. To import local files – you need to upload your files to directory you choose on import page (input – Images File Directory).

Download CSV file example for import downloadable product

Magento CLI Import Commands

Cron jobs Import can be enabled, disabled, or started from the Magento 2 CLI interface. In the Magento 2 root folder, run the following command:

Magento CLI Import Commands

CSV File samples

Download samples CSV files for import to Magento 2 

You can also export existing products and customers from your store to get a correct CSV file structure of your store, products, attributes, columns, etc. The feature is available under:

Magento admin -> System -> Export

Import fields mapping (in Magento 1.x style!)

The powerful mapping feature allows you to map Magento attributes to custom columns in your CSV file. 

After specifying the source of your CSV file for import on the General tab of Import Job (System -> Import Jobs) and clicking Save Job – column names from your CSV file will be available for mapping to Magento system attributes on the Map Attributes tab.

Unbenannt-1

In the left column there is a dropdown with all Magento attributes to select:

magento2_products_import_mapping_customer_attributes_csv

In the right column – a dropdown with column names from your CSV file (a source file should be specified on the General tab and Import Job should be saved!) 

magento2_products_import_mapping_default_attributes

Once you have finished with mapping – Save Job and run it from the command line to test and then schedule cron import.

With the import fields mapping feature you can import custom CSV files from various e-commerce systems, PIM, ERP, SAP.

We are working now on import profile pre-sets for Magento CE & EE 1.x, WooCommerce, Shopify, Prestashop etc. But now, you can already map any custom data structure to Magento product attributes for import.

Improved Import for Magento 2 upcoming features roadmap

Since we are continuously working on Improved Import features following community and merchant needs, here are upcoming features which we are working on now.

After purchasing the extension, you will receive free upgrades during one year and also will get 50% discount for the second year upgrades! This mean you can purchase extension now to use current features and get free updates with powerful new features!

  • CSV mapping presets for Magento 1.x CE & EE , Shopify , BigCommerce , WooCommerce , Prestashop, and other major ecommerce systems – to make migration to Magento 2 and sync with the platform extremely easy!
  • API connection between Magento 2 and Shopify , BigCommerce, and other cloud-based SAAS ecommerce platforms – effortlessly import and export products, customers, and other data on the fly – without creating CSV files! Setup synchronization between your Magento 2 store and other ecommerce platforms in a few clicks;
  • Improved Import auto-upgrade – built-in system to keep your Improved Import copy up to date and get new import features, bug fix, and patches in Magento 2 instantly!
  • Unzip / untar archive with a CSV file before import – flexible import of large compressed data;
  • Export mapping – all import mapping flexibility during data export from Magento 2 – create any kind of CSV, XML, and TXT files to export product, categories, orders, and customers from Magento 2!
  • Custom data structure mapping for categories, customers, discount codes, catalog price rules, import! Full flexibility of data import to Magento 2!
  • Product data auto translation during import by Google or Bing – great for import to different store views;
  • Integration with API of data crawling services, such as https://www.import.io/. Crawl product data from any source and import it directly to Magento 2 – this oppens nearly endless possibilities!

For further information, consultation, or to request individual features use our contact form!

Buy Improved Import Magento 2 Extension