Importing data from MongoDB
If you have your data stored in MongoDB, you can easily import the data into Analytics Plus for advanced reporting and analysis.
Log in to Analytics Plus, click on the Import Your Data button found at the top right corner of the screen, and select the Local & Cloud Databases option.
Follow the steps below to import data from MongoDB.
Step 1: Local and Cloud Database Connection Settings
Service Name: Choose the service name, this identifies the database service on which the database is runnning.
Database Type: This is the type of database running on the server.
Database Host Name: Enter the hostname or the IP address of the server which is hosting your MongoDB database.
Database Port: This is the port on which the database instance is running
Database Username: This is the username used to access the database. It is recommended to provide read-only user name.
Database Password: Enter the password that is associated with the username.
Click Next to proceed.
Note: You can also import data from MongoDB into Analytics Plus without authenticating your database.
Step 2: Select data to import
Select database: Select the database from which data is to be imported.
Select table: Select the required radio button to import data.
Single table: Select the table from which the data is to be imported.
Multiple tables: Select multiple tables to import data from multiple tables at once.
Custom query: Enter your custom query in the respective database query format from which data is to be imported.
Click Next to proceed.
Note: There should not be any spaces in the table names while importing data from MongoDB databases.
Step 3: ManageEngine Analytics Plus database setup
You can change the title of the columns, choose to exclude some and change their data types. Choose what the application should do when an error occurs during import.
Analytics Plus imports the input data provided, it will bring up a Import Summary dialog as shown below, capturing the status of the Import process just completed.
The details that would be shown include:
Column Details: Total number of columns in the input data and the total number of columns that where actually selected for import.
Row Details: Total number of rows in the input data and the total number of successfully imported rows in it.
Scheduling Options: If you wish to schedule imports, click on the "Schedule This Import" option
How do you want to import?
Select your preference from a drop down list on the available options to add new records into your database.
Add records at the end: This option adds the new columns towards the end of the existing database table
Delete existing records and add: This option deletes the existing records and adds the new records into the database table
Add Records and replace if already exists: This option adds the new columns and overwrites records with same column name.
Add new, replace existing and delete missing records: This option adds the new records, overwrites the existing records with same column name and deletes the missing records.
To add new columns into your Analytics Plus table automatically, select the 'Include new column added in your Local and Cloud Database automatically into ManageEngine Analytics Plus table' option.
When Add records and replace if already exists or Add records, replace existing and delete missing record is selected, it is mandatory to specify matching columns using the Select the column(s) to match existing records option. You can choose one or more columns as matching columns. Analytics Plus will use the values in these columns as the key to match the existing records with the new records being imported. Hence the matching column(s) combination should uniquely identify each record in the table. Once a match is identified, then Analytics Plus will update that existing record in the table with the new record values present in the data being Imported. Incase there is no match found, those records will be appended to the end of the table.
You can specify the schedule interval from the available options such as:
Repeat- Specify the schedule interval from the drop-down list. Available options are.
Every 'N' hours - Choose this option to schedule the import every 'N' hours i.e., every 2 hour or 6 hours. On choosing this option, specify the time interval to import the data.
Every Day - Choose this option to schedule the import at a particular time everyday. On choosing this option, specify the time to import data.
Weekly Once - Choose this option to schedule the import once in a week on a particular day. On choosing this option, specify the day of the week and the time to import the data.
Monthly Once - Choose this option if you want to schedule the import once in a month on a particular day. On choosing this option, specify the day of the month and the time to import data
On closing the Summary dialog, Analytics Plus will display the newly created table with the data loaded in the same.