Skip to content
Advertisement

Why I get: ‘%’, ‘(‘, , , ‘?’, FUNCTION or identifier expected, got ‘(‘?

I get an error in my Repository in Java Springboot.

In my controller I get the chosen categorie from the html page. I want to make a list of opleiding that covers the criteria of that categorie.

To make that list I call a query: GeefEenLijstvanCategorie(categorie):

JavaScript

But I get an error in the Repository. The repository and queries in My Sql is all very new to me.

In the repository I have:

JavaScript

This error occurs, positioned between the LIKE and (String categorie):

%', '(', <expression>, <input parameter>, '?', FUNCTION or identifier expected, got '('

Advertisement

Answer

Use : to use the value of a parameter.

JavaScript
User contributions licensed under: CC BY-SA
1 People found this is helpful
Advertisement