You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Bhukailas Reddy (JIRA)" <ji...@apache.org> on 2019/07/27 14:53:00 UTC

[jira] [Created] (ASTERIXDB-2616) Returning meta data from a SQL++ DML statement

Bhukailas Reddy created ASTERIXDB-2616:
------------------------------------------

             Summary: Returning meta data from a SQL++ DML statement
                 Key: ASTERIXDB-2616
                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-2616
             Project: Apache AsterixDB
          Issue Type: New Feature
          Components: SQL - Translator SQL++
            Reporter: Bhukailas Reddy


I am looking for a change to SQL++ DML statements. For example I would like return data which is inserted or update in DB back to client.

*SQL++ Insert Query Expectation*

In the below insert query I am generating chirpid using uuid() function which unknown AstereixDB client. It will be helpful for client if AsterixDB can return the generated uuid value as result back.

 

INSERT INTO ChirpMessages 
 (
 {*"chirpId": uuid(),*
 "user":
 {"screenName": "NathanGiesen@211",
 "lang": "en",
 "friendsCount": 39345,
 "statusesCount": 479,
 "name": "Nathan Giesen",
 "followersCount": 49420
 },
 "senderLocation": point("47.44,80.65"),
 "sendTime": datetime("2008-04-26T10:10:35"),
 "referredTopics": \{{"chirping"}},
 "messageText": "chirpy chirp, my fellow chirpers!"
 }
 )
*RETURNING META().chirpId as chirpId;*

 



--
This message was sent by Atlassian JIRA
(v7.6.14#76016)