Kevin Burton
2014-11-17 21:52:26 UTC
Thereâs still a lot of weirdness in CQL.
For example, you can do an INSERT with an UPDATE .. .which Iâm generally
fine with. Kind of make sense.
However, with INSERT you can do IF NOT EXISTS.
⊠but you canât do the same thing on UPDATE.
So I foolishly wrote all my code assuming that INSERT/UPDATE were
orthogonal, but now theyâre not.
you can still do IF on UPDATE though⊠but itâs not possible to do IF
mycolumn IS NULL
.. so is there a way to mimic IF NOT EXISTS on UPDATE or is this just a bug?
For example, you can do an INSERT with an UPDATE .. .which Iâm generally
fine with. Kind of make sense.
However, with INSERT you can do IF NOT EXISTS.
⊠but you canât do the same thing on UPDATE.
So I foolishly wrote all my code assuming that INSERT/UPDATE were
orthogonal, but now theyâre not.
you can still do IF on UPDATE though⊠but itâs not possible to do IF
mycolumn IS NULL
.. so is there a way to mimic IF NOT EXISTS on UPDATE or is this just a bug?
--
Founder/CEO Spinn3r.com
Location: *San Francisco, CA*
blog: http://burtonator.wordpress.com
⊠or check out my Google+ profile
<https://plus.google.com/102718274791889610666/posts>
<http://spinn3r.com>
Founder/CEO Spinn3r.com
Location: *San Francisco, CA*
blog: http://burtonator.wordpress.com
⊠or check out my Google+ profile
<https://plus.google.com/102718274791889610666/posts>
<http://spinn3r.com>