The keys[] array in Query.ModifyRowsResults?

LabKey Support Forum (Inactive)
The keys[] array in Query.ModifyRowsResults? slangley  2010-09-30 15:00
Status: Closed
 
When I do a LABKEY.Query.insertRows() command via the JavaScript API on an external schema in PostgreSQL, the object passed to the successCallback function doesn't appear to have a keys[] property as I read in the documentation here:

https://www.labkey.org/download/clientapi_docs/javascript-api/symbols/LABKEY.Query.ModifyRowsResults.html

To find the primary key of the row(s) inserted, I have to inspect the row[] array for what I know to be the primary key field for that particular table.

Is this a known limitation?

Thanks.

Scott Langley
 
 
brittp responded:  2010-09-30 16:37
Hi Scott,

This looks like a bug. I've entered it here:
https://www.labkey.org/issues/home/Developer/issues/details.view?issueId=10842

Are you able to work around the issue for now?

Thanks,
Britt
 
slangley responded:  2010-09-30 16:40
Sure. I'm working around it by adding the extra code to look inside the row array for the known primary key field.

It would simplify my coding if that wasn't necessary.

Scott.
 
brittp responded:  2010-09-30 16:42
Sounds good. Hopefully we can get this fixed in the 10.3 release, due out in late October. Thanks for the report!

-Britt