cancel
Showing results for 
Search instead for 
Did you mean: 

odata/v4/BooksService/Books returns no books

0 Kudos
324

Tutorials: https://developers.sap.com/tutorials/cp-cap-java-service-reuse.html
--------------------------


Running through the tutorial Reuse a CAP JAVA Service

Step 9: Run and test the bookstore application

<myurl>/odata/v4/BooksService/Books returns only

{"@context":"$metadata#Books","@metadataEtag":"W/\"02b7523ab79be9cc866b6c0969d6dfbd7d0afcc59d1dc69029c4f7cf02034ffd\"","value":[]}

Although the SQL Tools show that the data had been successfully loaded to the sqlite DB.

/odata/v4/BooksService/$metadata gives a long output.

It looks as if the service does not connect to the database.

Any idea how I can find out what is going wrong?

Accepted Solutions (0)

Answers (1)

Answers (1)

0 Kudos

Hi Marc,

Yes, I rechecked it

the file application.yaml looks as in the screenshot of the tutorial:

---spring: config.activate.on-profile: default datasource: url: "jdbc:sqlite:/home/user/projects/bookstore/sqlite.db" driver-class-name: org.sqlite.JDBC initialization-mode: never hikari: maximum-pool-size: 1