[ 
https://issues.apache.org/jira/browse/DRILL-5043?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Arina Ielchiieva updated DRILL-5043:
------------------------------------
    Description: 
Design and implement a function that returns a unique id per session/connection 
similar to MySQL's CONNECTION_ID().

*Implementation details*
function *session_id* will be added. Function returns current session unique id 
represented as string.

Please note, this function will override columns that have the same name. Table 
alias should be used to retrieve column value from table.
Example:
{code:sql}select session_id from <table>  // returns the value of niladic 
function session_id {code} 
{code:sql}select t1.session_id from <table> t1 // returns session_id column 
value from table {code}


  was:Design and implement a function that returns a unique id per 
session/connection similar to MySQL's CONNECTION_ID().


> Function that returns a unique id per session/connection similar to MySQL's 
> CONNECTION_ID()
> -------------------------------------------------------------------------------------------
>
>                 Key: DRILL-5043
>                 URL: https://issues.apache.org/jira/browse/DRILL-5043
>             Project: Apache Drill
>          Issue Type: Improvement
>          Components: Functions - Drill
>    Affects Versions: 1.8.0
>            Reporter: Nagarajan Chinnasamy
>            Priority: Minor
>              Labels: CONNECTION_ID, SESSION, UDF, doc-impacting, 
> ready-to-commit
>             Fix For: Future
>
>         Attachments: 01_session_id_sqlline.png, 
> 02_session_id_webconsole_query.png, 03_session_id_webconsole_result.png
>
>
> Design and implement a function that returns a unique id per 
> session/connection similar to MySQL's CONNECTION_ID().
> *Implementation details*
> function *session_id* will be added. Function returns current session unique 
> id represented as string.
> Please note, this function will override columns that have the same name. 
> Table alias should be used to retrieve column value from table.
> Example:
> {code:sql}select session_id from <table>  // returns the value of niladic 
> function session_id {code} 
> {code:sql}select t1.session_id from <table> t1 // returns session_id column 
> value from table {code}



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

Reply via email to