Your data. Anywhere you go.

New Relic for iOS or Android

Download on the App Store    Android App on Google play

New Relic Insights App for iOS

Download on the App Store

Learn more

Close icon

Incorrect tagging of DB queries




I think we might be having some issues with the tagging of the DB queries on transaction traces. It’s associating a query with an event on another table.

If you look on the permalink above, and click on the “View database query” for any “Postgres Event find” event, you will see that the queries showed belong to other tables.

Also, the summary tab isn’t consistent with what it’s on the Database queries tab, seems to be related, where different queries from different tables are being tagged the same incorrectly.

I’d appreciate some help.[end]=1571419980&tw[start]=1571333580#id=5b224f746865725472616e73616374696f6e2f536964656b69714a6f622f576f726b6572733a3a4d656d626572736869703a3a52657365745374617475734f6e652f706572666f726d222c22225d&tab-detail_d2bf8abb-f19b-11e9-8e46-0242ac11000a_0_14852=trace_details&app_trace_id=d2bf8abb-f19b-11e9-8e46-0242ac11000a_0_14852


@RyanVeitch I see that you edited my post but I’m not seeing any change. I haven’t received any response yet. Can you help me with that?


Hey @gabo - My edit to your post was just re-filing it into the right category here in the explorers hub. I’m afraid I’m not an expert in these things so I’m not sure what the solution is, but I’m going to pass this on the the right people here to get a look on this post. :slight_smile:



My apologies for the delay in response!

I was looking at the link provided and I’m confused by what you mean by “the queries being shown belong to other tables”. I clicked on the drilldown icon for the Postgres Event find segments in your transaction trace and I was seeing a query displayed. Are you saying that those queries are being incorrectly associated with your Workers::Membership::ResetStatusOne/performtransaction?

Since I’m not familiar with your environment, can you give me an idea of what you are expecting to see in these segments?


Hey! Thanks for your reply

Are you saying that those queries are being incorrectly associated with your Workers::Membership::ResetStatusOne/perform transaction?

No, I’m saying that the query itself is from another table, not from the Event table but other.
I’m expecting the segment Postgres Event find to be associated with a query on the Events table, for example: select * from events where = XXX



I’m still looking into this further, but we’re thinking that the agent may be falling back to the general table name of “event” over the specific names of the tables themselves. I’m checking with the engineers to see if there is functionality within the agent that causes that behavior.


Hi! How are you? Any news about this?



Hello! So our engineers looked into this and we don’t have anything in our agent that would cause the postgres table names to fall back to a general event table if we can’t find the table name. It’s a really strange issue and I’m leaning towards this being a bug. I’m waiting on the ruby agent engineers to see if there’s any more information regarding this.



We’re thinking at this point it would be best to open a support ticket for this issue. It’s super weird that some tables seem to be getting mislabeled but the majority of them are being labeled correctly. We’ll want to take a look at some environment info as well as some audit logs for the agent. I will reach out to you in a support ticket shortly and we can continue from there.