Getting PK from JSDataSet

I have a method that uses databaseManager.getDataSetByQuery to get a column (not the PK).
I only feed this method with 1 column name I want to query but I also need to get the Primary Key value for other queries.
Any way to get the PK of the result DataSet without knowing the columnname?
I like to keep my arguments to this method to a minimum.

Is it now available? I have similar requirement. I want to get the primary key of the table which is linked to a form

I think the only way is to get a JSTable object using databaseManager and then go over its columns. The single JSColum object allows you to identify a PK using isRowIdentifier().

But I think a Rowidentifier <> PK…

In most cases the rowidentifier equals the PK, but it doesn’t have to be

Thanks for informing that. Actually I have gone through the JSTable/JSColumn previously but I guess I had over looked it.