idea爆出org.hibernate.tool.schema.spi.CommandAcceptanceException不知道怎么解决
org.hibernate.tool.schema.spi.CommandAcceptanceException: Error executing DDL "create table hibernate_sequence (next_val bigint) engine=InnoDB" via JDBC Statement

    at org.hibernate.tool.schema.internal.exec.GenerationTargetToDatabase.accept(GenerationTargetToDatabase.java:67)

    at org.hibernate.tool.schema.internal.AbstractSchemaMigrator.applySqlString(AbstractSchemaMigrator.java:559)

    at org.hibernate.tool.schema.internal.AbstractSchemaMigrator.applySqlStrings(AbstractSchemaMigrator.java:504)

    at org.hibernate.tool.schema.internal.AbstractSchemaMigrator.createTable(AbstractSchemaMigrator.java:277)

    at org.hibernate.tool.schema.internal.GroupedSchemaMigratorImpl.performTablesMigration(GroupedSchemaMigratorImpl.java:71)

    at org.hibernate.tool.schema.internal.AbstractSchemaMigrator.performMigration(AbstractSchemaMigrator.java:207)

    at org.hibernate.tool.schema.internal.AbstractSchemaMigrator.doMigration(AbstractSchemaMigrator.java:114)

    at org.hibernate.tool.schema.spi.SchemaManagementToolCoordinator.performDatabaseAction(SchemaManagementToolCoordinator.java:184)

    at org.hibernate.tool.schema.spi.SchemaManagementToolCoordinator.process(SchemaManagementToolCoordinator.java:73)

    at org.hibernate.internal.SessionFactoryImpl.<init>(SessionFactoryImpl.java:320)

    at org.hibernate.boot.internal.SessionFactoryBuilderImpl.build(SessionFactoryBuilderImpl.java:462)

    at org.hibernate.jpa.boot.internal.EntityManagerFactoryBuilderImpl.build(EntityManagerFactoryBuilderImpl.java:1237)                                                                                     

    at org.springframework.orm.jpa.vendor.SpringHibernateJpaPersistenceProvider.createContainerEntityManagerFactory(SpringHibernateJpaPersistenceProvider.java:58)

    at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.createNativeEntityManagerFactory(LocalContainerEntityManagerFactoryBean.java:365)

    at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.buildNativeEntityManagerFactory(AbstractEntityManagerFactoryBean.java:391)

    at org.springframework.orm.jpa.AbstractEntityManagerFactoryBean.afterPropertiesSet(AbstractEntityManagerFactoryBean.java:378)

    at org.springframework.orm.jpa.LocalContainerEntityManagerFactoryBean.afterPropertiesSet(LocalContainerEntityManagerFactoryBean.java:341)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.invokeInitMethods(AbstractAutowireCapableBeanFactory.java:1855)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.initializeBean(AbstractAutowireCapableBeanFactory.java:1                         792)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.doCreateBean(AbstractAutowireCapableBeanFactory.java:595)

    at org.springframework.beans.factory.support.AbstractAutowireCapableBeanFactory.createBean(AbstractAutowireCapableBeanFactory.java:517)

    at org.springframework.beans.factory.support.AbstractBeanFactory.lambda$doGetBean$0(AbstractBeanFactory.java:323)

    at org.springframework.beans.factory.support.DefaultSingletonBeanRegistry.getSingleton(DefaultSingletonBeanRegistry.java:222)

    at org.springframework.beans.factory.support.AbstractBeanFactory.doGetBean(AbstractBeanFactory.java:321)

    at org.springframework.beans.factory.support.AbstractBeanFactory.getBean(AbstractBeanFactory.java:202)

    at org.springframework.context.support.AbstractApplicationContext.getBean(AbstractApplicationContext.java:1108)

    at org.springframework.context.support.AbstractApplicationContext.finishBeanFactoryInitialization(AbstractApplicationContext.java:868)

    at org.springframework.context.support.AbstractApplicationContext.refresh(AbstractApplicationContext.java:550)

    at org.springframework.boot.web.servlet.context.ServletWebServerApplicationContext.refresh(ServletWebServerApplicationContext.java:141)

    at org.springframework.boot.SpringApplication.refresh(SpringApplication.java:747)

    at org.springframework.boot.SpringApplication.refreshContext(SpringApplication.java:397)

    at org.springframework.boot.SpringApplication.run(SpringApplication.java:315)

    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1226)

    at org.springframework.boot.SpringApplication.run(SpringApplication.java:1215)

    at com.liuzeyu.BlogApplication.main(BlogApplication.java:12)

    at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)

    at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)

    at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)

    at java.lang.reflect.Method.invoke(Method.java:498)

    at org.springframework.boot.devtools.restart.RestartLauncher.run(RestartLauncher.java:49)

Caused by: java.sql.SQLSyntaxErrorException: Table 'blog.hibernate_sequence' doesn't exist



我是数据库挂了之后重新安装的MySQL 安装后连接正常,但是一启动spring boot就抛出这个异常

网上很多地方说修改hibernate.cfg.xml文件  但idea找不到这个文件,我的项目是SpringBoot+JPA+Thymeleaf
Csdn user default icon
上传中...
上传图片
插入图片
抄袭、复制答案,以达到刷声望分或其他目的的行为,在CSDN问答是严格禁止的,一经发现立刻封号。是时候展现真正的技术了!
立即提问

相似问题

1
java.sql.SQLTransientConnectionException: HikariPool-1 - Connection is not available
2
IDEA整合ssh测试hibernate时报Field 'password' doesn't have a default value错误
0
在运行一个SSH项目时提示一下错误,怎么办?
1
org.springframework.beans.factory.BeanCreationException 异常
2
org.apache.ibatis.exceptions.PersistenceException怎么解决?
2
SSM整合运行Tomcat报错org.springframework.beans.factory.BeanCreationException
2
eclipse启动项目的时候报错,然后重启好多次中会有几次是好着的,闹不懂什么意思,配置文件都是对的
2
Hibernate未报error但是运行不成功
3
关于sping-security的Access is denied问题
1
Tomcat配置成功后,第一次启动startup.bat失败,报错内容如下,这是怎么回事儿?
2
SSh整合SessionFactory出错,求解决,改不出来,一天了,下面是错误提示
2
ssm 报错:org.springframework.context.annotation.internalAsyncAnnotationProcessor
1
使用kafka connect ,mysql作为输入,输出也是mysql 报错record value schema is missing
1
idea配置mybits generate时报错,请问是哪配错了吗?
1
java.lang.IllegalStateException: Failed to load ApplicationContext
1
javac编译测试类,提示org.springframework.context 不存在,但实际已经导入
0
ssm整合单元测试时候报错Failed to load ApplicationContext
1
dubbo消费方调用不到服务方问题
2
使用@Compoent 装配 Bean报错 No bean named 'student' is defined。
3
eclipce创建maven的xml配置文件,progress一直显示loading http://www.springframework.org....