Re: Update/where statement Adds Row

2019-09-13 Thread A
Thank you. Sent from Yahoo Mail for iPhone On Thursday, September 12, 2019, 1:09 AM, Hossein Ghiyasi Mehr wrote: Update in Cassandra is upsert (update or insert). So when you update a row which isn't exist, it will create it."IF EXIST" can be used in some queries. On Thu, Sep 12, 2019 at 8:

Re: Update/where statement Adds Row

2019-09-12 Thread Hossein Ghiyasi Mehr
Update in Cassandra is upsert (update or insert). So when you update a row which isn't exist, it will create it. "IF EXIST" can be used in some queries. On Thu, Sep 12, 2019 at 8:35 AM A wrote: > I have an update statement that has a where clause with the primary key > (email,companyid). > > Whe

Re: Update/where statement Adds Row

2019-09-11 Thread Jon Haddad
' > > WHERE key = ‘value’ IF EXISTS; > > > > > > > > > > > > *From:* A > *Sent:* Wednesday, September 11, 2019 11:05 PM > *To:* User cassandra.apache.org > *Subject:* Update/where statement Adds Row > > > > I have an update statem

Re: Update/where statement Adds Row

2019-09-11 Thread A
M To: User cassandra.apache.org Subject: Update/where statement Adds Row   I have an update statement that has a where clause with the primary key (email,companyid).   When executed it always creates a new row. It’s like it’s not finding the existing row with the primary key.   I’m using

Re: Update/where statement Adds Row

2019-09-11 Thread A
1:05 PM To: User cassandra.apache.org Subject: Update/where statement Adds Row   I have an update statement that has a where clause with the primary key (email,companyid).   When executed it always creates a new row. It’s like it’s not finding the existing row with the primary key.

RE: Update/where statement Adds Row

2019-09-11 Thread JOHN, BIBIN
Use if exists clause. UPDATE table SET column ='something' WHERE key = ‘value’ IF EXISTS; From: A Sent: Wednesday, September 11, 2019 11:05 PM To: User cassandra.apache.org Subject: Update/where statement Adds Row I have an update statement that has a where clause with the p

Update/where statement Adds Row

2019-09-11 Thread A
I have an update statement that has a where clause with the primary key (email,companyid). When executed it always creates a new row. It’s like it’s not finding the existing row with the primary key. I’m using Cassandra-driver. What am I doing wrong? I don’t want a new row. Why doesn’t it seem to