Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Share your agentic AI experience, learn from others, and earn a new badge: Put Agentic AI to Work
cancel
Showing results for 
Search instead for 
Did you mean: 
gopikrishnan06
Creator
Creator

INVALID_STATE: Invalid SessionHandle: SessionHandle [01f18796-eb22-1cc1-97b2-2e12e5eb4036

hi All,

Am getting frequent disconnection from the Qlik replicate using target as Databricks delta lakehouse.

Error as 115 invalid_state: invalid session Handle: session handle.

Target: (Databricks Lakehouse (Delta)) Error Code: 1022502 Error details: Failed to start bulk apply transaction Failed to execute merge table statement

RetCode: SQL_ERROR  SqlState: 08S01 NativeError: 115 Message: [Simba][Hardy] (115) Connection failed with error: HTTP Response code: 400 ,  INVALID_STATE: Invalid SessionHandle: SessionHandle [01f18796-eb22-1cc1-97b2-2e12e5eb4036].

Failed (retcode -1) to execute statement: MERGE INTO `sap_p01`.`mch1

Labels (1)
1 Solution

Accepted Solutions
gopikrishnan06
Creator
Creator
Author

Got Solution from Qlik and Databricks Vendor.

Installed the new Databricks ODBC Driver 2.12.1 to resolve the Invalid session timeout error.

 

View solution in original post

6 Replies
john_wang
Support
Support

Hello @gopikrishnan06 ,

I'm not certain whether the error occurs after a fixed period of inactivity or randomly during periods of heavy replication. However, there are several possible causes that can lead to the same error:

  1. SQL Warehouse terminating idle sessions (most common)

    If you're connecting to a Databricks SQL Warehouse, please check:

    • Auto Stop timeout settings

    • Auto Scaling events

    • SQL Warehouse restart events

  2. Network interruption

    Even a brief network interruption between Qlik Replicate and Databricks can invalidate the session, resulting in an Invalid SessionHandle error.

    As part of the investigation, I recommend enabling Databricks ODBC tracing. The trace logs can help determine whether the issue is caused by network connectivity, session timeouts, or an ODBC driver-related problem.

Hope this helps.

John.

Help users find answers! Do not forget to mark a solution that worked for you! If already marked, give it a thumbs up!
gopikrishnan06
Creator
Creator
Author

Hi John,

I already checked with the Databricks compute.

1) there are no auto stop timeout at that time. Monday we got error, Compute restarted on last saturday

2) no auto scalling events

3) Sql warehouse restart on last saturday.

4) ODBC Trace already shared with the Qlik Vendor # 00464651 - Need help on Qlik Replicate#

@John kindly check if any IP need to add to fix the network glitch. Daily we are getting network disconnection it wont stop the tasks but we are getting multiple ticket.

 

john_wang
Support
Support

Hello @gopikrishnan06 ,

Thanks for the update. Our support team will be more than happy to assist you with this case and work with you to investigate and resolve the issue.

thanks,

John.

Help users find answers! Do not forget to mark a solution that worked for you! If already marked, give it a thumbs up!
gopikrishnan06
Creator
Creator
Author

Hi All,

In Support team the ticket moved to R&D team, It will take some time too. Anyone faced this type of issues Kindly share the suggestions.

Thank you,

gopikrishnan06
Creator
Creator
Author

Got Solution from Qlik and Databricks Vendor.

Installed the new Databricks ODBC Driver 2.12.1 to resolve the Invalid session timeout error.

 

john_wang
Support
Support

Thank you so much for your outstanding support! @gopikrishnan06 

Help users find answers! Do not forget to mark a solution that worked for you! If already marked, give it a thumbs up!