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

[Azure Cognitive Search] Need sample showing explicit Field construction #9472

Closed
chadbr opened this issue Jan 14, 2020 · 5 comments · Fixed by #11751
Closed

[Azure Cognitive Search] Need sample showing explicit Field construction #9472

chadbr opened this issue Jan 14, 2020 · 5 comments · Fixed by #11751
Assignees
Labels
Client This issue points to a problem in the data-plane of the library. Search
Milestone

Comments

@chadbr
Copy link

chadbr commented Jan 14, 2020

A couple of years back - the index definitions changed to use attributes:
#2427

Is there a sample of doing it 'the old way'?

I have models from source code I don't control... I need to build indexes on them.
Is there a sample of how to do this without having to rebuild the models with search / index attributes?

@triage-new-issues triage-new-issues bot added the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Jan 14, 2020
@chadbr
Copy link
Author

chadbr commented Jan 14, 2020

I found a sample by digging through the sdk sample git history...

https://github.com/Azure-Samples/search-dotnet-getting-started/blob/153049a996fa88a0f0e5b17ff342088043d944fd/DotNetSample/DataIndexer/Program.cs

I think it would be valuable to have a sample like this in current sdk? Or am I swimming upstream on this one?

Thanks, Chad

@brjohnstmsft brjohnstmsft self-assigned this Jan 14, 2020
@triage-new-issues triage-new-issues bot removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Jan 14, 2020
@brjohnstmsft
Copy link
Member

Hi Chad,

There's no sample of building fields explicitly, but there is test code that you can look at: https://github.com/Azure/azure-sdk-for-net/blob/master/sdk/search/Microsoft.Azure.Search/tests/Utilities/IndexFixture.cs

Let me know if that helps.

@chadbr
Copy link
Author

chadbr commented Jan 15, 2020

That does help. But I still feel like it needs to be in the samples?

@brjohnstmsft brjohnstmsft changed the title [QUERY] Search Index declaration without attributes? [Azure Cognitive Search] Need sample showing explicit Field construction Jan 15, 2020
@brjohnstmsft
Copy link
Member

@chadbr We'll be revisiting samples this year while we update our .NET SDK to meet the new Azure API Guidelines. I'll leave this issue open to track the explicit Field construction case for the new samples.

@chadbr
Copy link
Author

chadbr commented Jan 15, 2020

Thank you -- Regards, Chad

@AlexGhiondea AlexGhiondea added the Client This issue points to a problem in the data-plane of the library. label Feb 11, 2020
@AlexGhiondea AlexGhiondea assigned tg-msft and unassigned AlexGhiondea Feb 11, 2020
@AlexGhiondea AlexGhiondea added this to the [2020] April milestone Mar 3, 2020
@tg-msft tg-msft modified the milestones: [2020] April, [2020] May Apr 6, 2020
@tg-msft tg-msft assigned heaths and unassigned tg-msft Apr 6, 2020
heaths added a commit to heaths/azure-sdk-for-net that referenced this issue May 2, 2020
heaths added a commit that referenced this issue May 3, 2020
* Internalize SearchFieldTemplate.Save

* Add example to create an index

Fixes #9472
@github-actions github-actions bot locked and limited conversation to collaborators Mar 28, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Client This issue points to a problem in the data-plane of the library. Search
Projects
None yet
Development

Successfully merging a pull request may close this issue.

5 participants