Couchbase Team,
Bucket user-bucket has 30million+ records in it. I need to update the domain of the email id present in the document from xxmail.com to yymail.com.
I have created an index and executed the script in cbq as below:
cbq> CREATE INDEX
USER_BKT-EMAIL-IDX
ONuser-bucket
(emailId) WHERE emailId LIKE “%xxmail.com”;
cbq> SELECT COUNT(*) AS count FROM `user-bucket` WHERE emailId LIKE "%xxmail.com"; { "requestID": "64633c5c-4559-4335-b363-4376d11d4ee6", "signature": { "count": "number" }, "results": [ { "count": 3063621 } ], "status": "success", "metrics": { "elapsedTime": "11.009255457s", "executionTime": "11.009217044s", "resultCount": 1, "resultSize": 40 } }
cbq> UPDATE `user-bucket` SET emailId = REPLACE(emailId, "xxmail.com", "yymail.com") where emailId LIKE "%xxmail.com";
cbq>
This update statement executed for quite long time(15mins+), and it comes out with out any output message.
Then I executed the count query and found out only 100k+ records are updated.
Kindly help me in getting the update query executed for 30million+ records.
Thanks
Ismail