Home Page for the TeradataForum

Archives of the TeradataForum

Message Posted: Fri, 26 Oct 2012 @ 17:15:05 GMT

  <Prev Next>   <<First <Prev Next> Last>>  

Subj:   Re: Grant Abort Session
From:   Myrna, James

First, you have to be able to tell if the session belongs to his application, if you can't do that, then it will not be possible to do what you want. Let's assume that the application runs under a functional Id of "HisApp". Then you write a stored procedure called AbortHisApp. The stored procedure accepts as input a session number and returns a message.

     CALL AbortHisApp (123456, Message);

The stored procedure would first run a query against dbc.SessionInfo for the input session number. If it doesn't find the session, it returns a message stating this. If it finds the session but the UserName returned from the SELECT is not equal to "HisApp", then you tell them this session does not belong to you (or you use whatever criteria it is that identifies this session belongs to the support person). Otherwise you take the session number and make a call to AbortSessions (SEL AbortSessions (1, 'HisApp', 123456, 'Y','Y');).

You can find more info about the AbortSession API in the Workload Management API manual from Teradata.


  <Prev Next>   <<First <Prev Next> Last>>  
  Top Home Privacy Feedback  
Copyright for the TeradataForum (TDATA-L), Manta BlueSky    
Copyright 2016 - All Rights Reserved    
Last Modified: 28 Jun 2020