Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

healthcare: duplicate query param key #550

Closed
nhue2310 opened this issue Jun 23, 2020 · 6 comments · Fixed by #1123
Closed

healthcare: duplicate query param key #550

nhue2310 opened this issue Jun 23, 2020 · 6 comments · Fixed by #1123
Assignees
Labels
api: healthcare Issues related to the Cloud Healthcare API API. type: question Request for information or clarification. Not an issue.

Comments

@nhue2310
Copy link

nhue2310 commented Jun 23, 2020

  • I was try to search FHIR resource with _include query param like below
queries := []googleapi.CallOption{}

queryPractitioner := helper.QueryParamOpt{
	Key:   "_include",
	Value: practitionerID,
}
queries = append(queries, queryPractitioner)
queryOrganization := helper.QueryParamOpt{
	Key:   "_include",
	Value: "organizationID",
}
queries = append(queries, queryOrganization)
hs, err := newHealthService()
r, err := hs.Projects.Locations.Datasets.FhirStores.Fhir.Search(parent).Do(queries)

Expect

https://healthcare.googleapis.com/v1/projects/x/locations/x/datasets/x/fhirStores/x/fhir/PractitionerRole?_include=Practitioner&_include=Organization

Real result

https://healthcare.googleapis.com/v1/projects/x/locations/x/datasets/x/fhirStores/x/fhir/PractitionerRole?_include=Organization
=> Search result is incorrect
Seem like this libs didn't support it

As you can see on this line, lib will replace query with same key.

So, How can i add new duplicate key without replace old one ?

@codyoss codyoss added the type: question Request for information or clarification. Not an issue. label Jun 23, 2020
@codyoss
Copy link
Member

codyoss commented Jun 23, 2020

Can you please show how you are using queryPractitioner & queryOrganization in the snippet provided above.

@codyoss codyoss changed the title [HealthCare - v1]duplicate query param key healthcare: duplicate query param key Jun 23, 2020
@codyoss codyoss added the api: healthcare Issues related to the Cloud Healthcare API API. label Jun 23, 2020
@nhue2310
Copy link
Author

@codyoss
Sorry, i updated detail
queryPractitioner & queryOrganization has been appended into queries.

@codyoss codyoss added the status: investigating The issue is under investigation, which is determined to be non-trivial. label Jun 23, 2020
@codyoss
Copy link
Member

codyoss commented Jun 23, 2020

Thanks, I will need to do some digging and then I will get back to you.

@tbpg
Copy link
Contributor

tbpg commented Jun 23, 2020

cc @noerog

@hue-n-gnk
Copy link

@codyoss Hi, how is it going?
It's more than 1 year for the digging. Do you have a plan for fixing it?

@codyoss
Copy link
Member

codyoss commented Jul 20, 2021

@hue-n-gnk Sorry, this slipped off my radar. I have just opened a PR that should unblock this use-case. Thanks for pinging the issue!

@codyoss codyoss removed the status: investigating The issue is under investigation, which is determined to be non-trivial. label Jul 20, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
api: healthcare Issues related to the Cloud Healthcare API API. type: question Request for information or clarification. Not an issue.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

4 participants