0

I am running a proc from java using hibernate (code below) when I get the below error:

Query query = sessionFactory.getCurrentSession().getNamedQuery("<query_name>");
    query.setParameter(0, businessDate);

    return query.list();

Error: SQL Error: 2762, SQLState: ZZZZZ The 'CREATE INDEX' command is not allowed within a multi-statement transaction in the 'tempdb' database.

The proc runs fine when I run it from db(sybase). Can someone please let me know how to resolve this?

Thanks!

2
  • did you look at this post Commented Aug 17, 2016 at 21:10
  • You probably called your SP inside a transaction created by hibernate/spring? Commented Aug 22, 2016 at 7:06

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.