org.springframework.jdbc.datasource.init.ScriptStatementFailedException: Failed to execute SQL script statement at line 7 of resource class path resource [sql/test-data-insert.sql]: INSERT INTO [...]

Searched on Google with the first line of a JAVA stack trace?

We can recommend more relevant solutions and speed up debugging when you paste your entire stack trace with the exception message. Try a sample exception.

Recommended solutions based on your search

Solutions on the web

via Stack Overflow by Damo
, 1 year ago
Failed to execute SQL script statement at line 3 of resource class path resource [databaseTesting/inMemory/createInMemoryDatabase.sql]: CREATE PROCEDURE p_recordTaskExecution(IN userTaskId INT, IN isSuccess BOOLEAN, IN statusMessage VARCHAR(2000
via Stack Overflow by user2729389
, 1 year ago
Failed to execute SQL script statement #1 of URL [file:/xxx/schema-hsql.sql]: CREATE SCHEMA XXX IF NOT EXISTS; nested exception is java.sql.SQLSyntaxErrorException: unexpected token: IF
via Stack Overflow by user2880771
, 2 years ago
Failed to execute SQL script statement at line 1 of resource class path resource [org/springframework/security/core/userdetails/jdbc/users.ddl]: create table users(username varchar_ignorecase(50) not null primary key,password varchar_ignorecase(500
via Stack Overflow by sonoerin
, 2 years ago
Failed to execute SQL script statement at line 1 of resource URL [file:/Users/David/projects/cnet/OFAC/out/test/OFAC/data.sql]: INSERT INTO users (username, password, enabled) VALUES ('admin', '$2a$10$GVPAMYRozI08Mcll5too6
org.springframework.jdbc.datasource.init.ScriptStatementFailedException: Failed to execute SQL script statement at line 7 of resource class path resource [sql/test-data-insert.sql]: INSERT INTO [...]
at org.springframework.jdbc.datasource.init.ScriptUtils.executeSqlScript(ScriptUtils.java:474)

Users with the same issue

4 times, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago
Samebug visitor profile picture
Unknown user
Once, 1 year ago

Know the solutions? Share your knowledge to help other developers to debug faster.