Getting error while selecting Query in BC onprem Web Services

Hi All,

I have created a query-50000 - Sales Inv Hdr using table - Sales Invoice Header. I tried with different query ID but same error.

But when trying to select it in web service page its giving error.

One more query i created Sales Inv Line - 50001 using table Sales Invoice Line, able to select it.

What and where I am missing?

Thanks in advance.