# Displaying QGIS attribute table on the right

Is it possible to dock QGIS attribute table on the right? I know it is possible to display it on top and bottom, but for my project it would be better to dock it on right (or left) side.

Agree with @JochenSchwarze that it makes sense to have it (and thanks for making it a feature request).

Saying that, it is possible to do it with a bit of Python.

1. Make sure the Open attribute table in a dock window setting is enabled from the menubar:

Settings > Options > Data Sources > Feature attributes and table > Open attribute...

2. Restart QGIS and then open both the Python Console (Plugins > Python Console or press Ctrl+Alt+P) and the Attribute Table of your selected layer.

3. Then type the following into the Python Console:

from PyQt4.QtCore import Qt
from PyQt4.QtGui import QApplication

attrTables = [d for d in QApplication.instance().allWidgets() if d.objectName() == u'AttributeTable']


Your attribute table should now be docked to the right:

And if you want to dock it to the left, replace

iface.addDockWidget(Qt.RightDockWidgetArea, attrTables[0])


with

iface.addDockWidget(Qt.LeftDockWidgetArea, attrTables[0])

• Can we agree on that it IS impossible to a 'normal' user expecting it to work via drag and drop and for shure it IS possible if one knows about python, wich in most cases cannot be taken for granted (Saying this is, I daresay, like saying "It is possible to order a meal in Shanghai with a bit of chinese") ;-) – Jochen Schwarze Jun 2 '16 at 12:38
• @JochenSchwarze - Haha! Yes completely agree that this is not a 'normal method' at all! Would be a nice feature to implement as drag-and-drop ;) – Joseph Jun 2 '16 at 12:43

Seems impossible at the moment. But I strongly agree that it makes sense. I have just started a feature request in the QGIS issue tracker https://hub.qgis.org/issues/14941