Skip to content

Column 'X' does not belong to underlying table 'events' #14

Open
@zikato

Description

@zikato

I have a peculiar problem. I'm tracking an event and collecting the sql_text global field/action.
But when the event has column is_system = true then sql_text is not collected at all (the schema shape has changed)

image

Service Broker activation is considered a system process even though it's arguably a user process.

I propose that the XESmartTarget return a NULL when the column is not found instead of the error. The SSMS XE viewer acts the same.

I've also tried to split the collection into two responses - one where is_system = 'False' collects the sql_text and the other one which doesn't. My filter snippet looks like this:

"Filter": "query_hash_signed <> 0 OR is_system = 'True'"

Then I've got an error:

Error - XESmartTarget.Core.Target : servername
Error - XESmartTarget.Core.Target : Cannot find column [is_system].
Error - XESmartTarget.Core.Target : at System.Data.NameNode.Bind(DataTable table, List1 list) at System.Data.BinaryNode.Bind(DataTable table, List1 list)
at System.Data.DataExpression.Bind(DataTable table)
at System.Data.DataView.set_RowFilter(String value)
at XESmartTarget.Core.Utils.XEventDataTableAdapter.ReadEvent(PublishedEvent evt) in C:\github\XESmartTarget\XESmartTarget.Core\Utils\XEventDataTableAdapter.cs:line 242
at XESmartTarget.Core.Responses.TableAppenderResponse.Enqueue(PublishedEvent evt) in C:\github\XESmartTarget\XESmartTarget.Core\Responses\TableAppenderResponse.cs:line 130
at XESmartTarget.Core.Target.TargetWorker.Process() in C:\github\XESmartTarget\XESmartTarget.Core\Target.cs:line 158

This is weird because the column is definitely there.
The column is recognized when I set up a different XE with a different JSON.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions