mirror of
https://github.com/Azure/cosmos-explorer.git
synced 2024-11-26 07:26:58 +00:00
Properly construct the query to delete Cassandra row (#388)
This commit is contained in:
parent
9a1e8b2d87
commit
9afa29cdb6
@ -312,9 +312,10 @@ export class CassandraAPIDataClient extends TableDataClient {
|
|||||||
const clearMessage = NotificationConsoleUtils.logConsoleProgress(`Deleting row ${currEntityToDelete.RowKey._}`);
|
const clearMessage = NotificationConsoleUtils.logConsoleProgress(`Deleting row ${currEntityToDelete.RowKey._}`);
|
||||||
const partitionKeyValue = currEntityToDelete[partitionKeyProperty];
|
const partitionKeyValue = currEntityToDelete[partitionKeyProperty];
|
||||||
const currQuery =
|
const currQuery =
|
||||||
query + this.isStringType(partitionKeyValue.$)
|
query +
|
||||||
|
(this.isStringType(partitionKeyValue.$)
|
||||||
? `${partitionKeyProperty} = '${partitionKeyValue._}'`
|
? `${partitionKeyProperty} = '${partitionKeyValue._}'`
|
||||||
: `${partitionKeyProperty} = ${partitionKeyValue._}`;
|
: `${partitionKeyProperty} = ${partitionKeyValue._}`);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
await this.queryDocuments(collection, currQuery);
|
await this.queryDocuments(collection, currQuery);
|
||||||
|
Loading…
Reference in New Issue
Block a user