You are viewing a plain text version of this content. The canonical link for it is here.
Posted to notifications@asterixdb.apache.org by "Till Westmann (Jira)" <ji...@apache.org> on 2022/02/17 02:29:00 UTC

[jira] [Updated] (ASTERIXDB-2909) SQL++ Primer is missing a little section on UPSERT

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

Till Westmann updated ASTERIXDB-2909:
-------------------------------------
    Fix Version/s: 0.9.8
                       (was: 0.9.7)

> SQL++ Primer is missing a little section on UPSERT
> --------------------------------------------------
>
>                 Key: ASTERIXDB-2909
>                 URL: https://issues.apache.org/jira/browse/ASTERIXDB-2909
>             Project: Apache AsterixDB
>          Issue Type: Bug
>          Components: DOC - Documentation
>    Affects Versions: 0.9.6
>            Reporter: Michael J. Carey
>            Assignee: Ian Maxon
>            Priority: Major
>             Fix For: 0.9.8
>
>
> I thought we had a little UPSERT section - but it seems to be lost if we did (or in my imagination if we didn't).  We need one there.  In one of my AsterixDB PPT decks I have this example, which works:
> To add a new user or modify an existing user in Gleambook.com:
> {{UPSERT INTO GleambookUsers (}}
> {{{"id":666,"alias":”dfrump",}}
> {{ "name":"DonaldFrump",}}
> {{ "nickname":"Frumpus",}}
> {{ "userSince":datetime("2021-02-21T00:00:00"),}}
> {{ "friendIds":\{{ }},}}
> {{ "employment":[{"organizationName":"TBD",}}
> {{ "startDate":date("2021-01-21")}],}}
> {{ "gender":"M"}}}
> {{);}}



--
This message was sent by Atlassian Jira
(v8.20.1#820001)