Solucionado (ver solução)
Solucionado
(ver solução)
1
resposta

Erro ao subir a aplicação

Erro ao subir a aplicação não acontece, mas também a tabela no banco não é criada.

Caused by: java.sql.SQLSyntaxErrorException: Table 'db_produto.pedido' doesn't exist`
at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:120)
    at com.mysql.cj.jdbc.exceptions.SQLError.createSQLException(SQLError.java:97)
    at com.mysql.cj.jdbc.exceptions.SQLExceptionsMapping.translateException(SQLExceptionsMapping.java:122)
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeInternal(ClientPreparedStatement.java:953)
    at com.mysql.cj.jdbc.ClientPreparedStatement.executeQuery(ClientPreparedStatement.java:1003)
    at com.zaxxer.hikari.pool.ProxyPreparedStatement.executeQuery(ProxyPreparedStatement.java:52)
    at com.zaxxer.hikari.pool.HikariProxyPreparedStatement.executeQuery(HikariProxyPreparedStatement.java)
    at org.hibernate.engine.jdbc.internal.ResultSetReturnImpl.extract(ResultSetReturnImpl.java:57)
    ... 78 more

Vix.e

1 resposta
solução!

Acho que achei. Adicionei uma configuração no application properties:

spring.jpa.generate-ddl=true 

Vi por aqui: https://stackoverflow.com/questions/26881739/unable-to-get-spring-boot-to-automatically-create-database-schema