Deleting the influxdb entries which have some value for particular field and field exist in the entry.
delete from stats_io where _field='read_val'
This query doesn't throw any error and it doesn't delete any entries as well. But the field exist in all entries in influxdb.
delete from stats_io where _field="read_val"
Changing _field value from single to double quote ends up in an error.
ERR: shard 517: fields not supported in WHERE clause during deletion
I refer the documentation for delete predicate and it's possible to delete based on field exist. I am not sure why this error is happening ?
Influxdb-Version: 1.3.1
Any suggestion in figuring out the error is much appreciated. Thanks!
Related
I tried to delete a node with its relations but I get this error
Relationship[332147,used=false,source=-1,target=-1,type=-1,sCount=1,sNext=-1,tCount=1,tNext=-1,prop=-1,secondaryUnitId=-1, sFirst, tFirst] not in use
I tried to Match or Delete this 332147 relation but in every query, I get not found
Node/Relationship[...] not in use means that your database is corrupted. (see related ticket) Probably due to an unexpected shutdown/interrupt.
You need to either restore from backup, or go through a data recovery process.
The solution recommended in that ticket is
You can copy the store using store-utils which will skip over broken
nodes and rels.
I am little bit confuse in solr report terminology can anyone help me.I am using https://localhost:8443/solr4/admin/cores?action=REPORT&wt=xml to generate the report in this report i am confuse in two tags one is name="Index error count" and another is name="Index unindexed count.Can anyone tell both are same or different?
They are different. As the documentation says:
Index error count: Specifies the count of the error documents (ID starts with ERROR-) in the index. It is used to mark nodes that failed
to be indexed. If the value of this parameter is not zero, then there
is an issue with the index.
Index unindexed count:Specifies the count of the unindexed documents (ID starts with UNINDEXED-) in the index. It is created for
nodes that have PROP_IS_INDEXED property set to false in the metadata.
This property is set to control indexing process, so it can be > 0.
For example, hidden and rendition nodes have this property set to
FALSE.
I'm trying to do an insert operation in a table with autoinc fields, and I'm using FireDac TFDCommand for that. So, the record is getting successfully inserted on db, but how to get the generated values for autoinc fields?
Obs: TFDConnection let me get the last auto gen. value, but the table generates two autoinc fields. I could get the primary key and select the record in db, but it's gonna be another call to db and I need to prevent it.
Any idea?
The only way seems to parse TFDConnection.Messages property, after the insert occurs. Some DBMS, like SQL Server, return messages as an additional result set.
To enable messages processing, set ResourceOptions.ServerOutput to True.
If messages coming from your database server you use doesn't returns any last inserted key information, I fear that the only solution would be another query to retrieve the last ID ...
Does anyone know why I keep getting this error when trying to update a product, I keep going round in circles & not getting anywhere.
SQLSTATE[23000]: Integrity constraint violation: 1062 Duplicate entry
'4294967295' for key 'PRIMARY'
We are on an old version 1.4 which is being updated in new year but need to fix this asap!
I had same issue but on catalogrule_product_price.
i changed a value for the auto_increment ID of that table from int(10) to bigint(10) in database.
so 4294967295 is not your last ID and it will work for while more ;)
for your problem it should be the catalog_product_entity field entity_id change type to BIGINT
Really hard to tell you much as we do not know which table this is occurring at. Search the database for that ID (4294967295) and see if you can find where it's trying to create this entry. Since the ID is very big I am assuming that it's an error of some sort (unless you have 4 billion products in your store). It may be as easy as deleting that entry, back your things up before you removes stuff though.
I assume you will find that erroring entry in the catalog_product_entity table.
What I would do is xdebug the saving process on a local environment and trace the saving attempt to see what values it's trying to pass. So if you have that setup going for you, you should start there.
I want to delete my records from the database based on some ID's.
This is the statement written in my STORED PROCEDURE to delete records based on DeletedID.
DELETE FROM tms_activity where activity_id IN (DeletedID);
My DeletedID is a string with records comma seperated like("1,2,3")
Now when I am passing DeletedID in my Statement as a parameter it is taking the input as "1,2,3" and deleting the record with the first DeletedID it is getting(1 in this case).But I want to delete all the records based on the given parameter.
DeletedId must be passed like (1,2,3) rather than ("1,2,3") than only it can delete all the records based on provided ID's...Now how can I do that?
I consulted this question: MySQL wrong output with IN clause and parameter,
but couldn't understand how can I achieve my result.
Did you try this
DELETE FROM tms_activity where activity_id in
( SELECT ACTIVITY_ID FROM SOMETABLE WHERE FIELD = CRITERIA )
Or some more findings, if I were at this problem would select one of these solutions.
I investigated and found some very good links for you.
[http://johnhforrest.com/2010/10/parameterized-sql-queries-in-c/][1]
The Parametrized SQL queries have a benefit if you have to send a large number of parameters and want to run against one sql. It takes the sql in one chunk and all the parameters in other so keep the network traffic low.
You can search more in this topic
Thanks
QF