Aggregation Pipeline is a framework that is based on the concepts of data processing pipelines. Documents enter a multi-stage pipeline that transforms the documents into an aggregated result. Data flows from one stage to another stage and at the end of the pipeline, we get the transformed data which can be used directly. The MongoDB aggregation pipeline consists of stages that we can use as per our requirements.

Import the sample data in your local MongoDB.

  1. Download the sample data from https://github.com/ozlerhakan/mongodb-json-files/blob/master/datasets/grades.json
  2. Run following commands in terminal

(Run mongod command to start the local MongoDB in another terminal tab)

$…


The reason for this error is because the mysql is using default unix or auth_socket plugin.

So we have change this to mysql_native_password

Step 1:

sudo mysql -u root -p

Enter password for sudo and root user

Step 2:

Use mysql;

Change to mysql database

Step 3:

Select User, Host, plugin from mysql.user;

This will show

users table
users table

Step 4:

Update user set plugin=’mysql_native_password’ where User=’root’;

Step 5:

systemctl restart mysql

Now try connecting from Mysql Workbench or Laravel and keep password empty.

Sumit Bopche

Senior Software Developer

Get the Medium app

A button that says 'Download on the App Store', and if clicked it will lead you to the iOS App store
A button that says 'Get it on, Google Play', and if clicked it will lead you to the Google Play store