Thank you Adam,
I sort of realized that at some point and then thought it is funny, laughing at myself and the way they wrote the documentation. The documentation explicitly states you have to download that specification and supply it, not that you have to create a specification based on that, I quote:
1. Obtain the OpenAPI 2.0 specification for the REST service, in JSON format.
3. In the testing tool, create an HTTP request message as follows:
- For the request body, paste the OpenAPI 2.0 specification, in JSON format.
The above does state you downlaod the OpenAPI 2.0 specification in JSON format and supply that as the body in Postman, I then thought they will from that create a framework for your REST of some sort that you then fill out with your routes and calls, it is really obscure documentation, for somebody new to InterSystems and to swagger this is very ambiguous.
My apologies, after typing all the above I realized what is happening (helps to explain to yourself), the SQLCOMPUTE increases the value in that field that is in the current record being saved and not what is in the last record that was saved. So you have to lock the record rather to not allow updates until you are done saving the record.
Thank you Nigel,
In the meantime I was able to locate an example in the FHIR code itself where they implemented the search on the repository.