Cannot load driver class: com.mysql.cj.jdbc.Driver
snippet in sql

Cannot load driver class: com.mysql.cj.jdbc.Driver

user3544

<dependency>
    <groupId>mysql</groupId>
    <artifactId>mysql-connector-java</artifactId>
    <version>8.0.18</version>
</dependency>