How obtain the uid of the logged user as a related field in a view? I have a view showing the nodes of a content type, and I want to show the user ID of the currently logged-in user as a field in view, but I can't find how to add the user ID of the currently logged-in user. I know that I can achieve this with the Views PHP module but I want to know if there is another way.

I have Views 3.11.

There is no relation between the content being shown, and the currently logged-in user; I just want to show the user ID of the user who is currently seeing the view.
You can't without some custom module providing such a data field (such as views php as you've seen).

Unless the uid has some relations to the content type you're displaying (e.g. a user reference field, the node uid, etc.), there's no way to retrieve the current UID. Views is designed to pull in data from a base table (e.g. nodes, users, taxonomy, etc.) and display the fields directly attached to it or related to it through a relationship.