Cannot resolve method 'getSession' in 'SessionFactoryUtils'

Cannot resolve method ‘getSession’ in ‘SessionFactoryUtils’
is Hibernate5.2.9

There is no SessionFactoryUtils class in Hibernate. With this little context, nobody will help you.

Thank you.There’s no getSession().What method should I use instead?

I have no idea what SessionFactoryUtils is. It’s a class you wrote or copied from somewhere or was provided to you through one of your dependencies. There is nothing the Hibernate community can do to help you.