question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[QUERY] Why is there no AsDecimal/AsDouble for FieldValue?

See original GitHub issue

Query/Question Looking at https://docs.microsoft.com/en-us/dotnet/api/azure.ai.formrecognizer.models.fieldvalue.ascountrycode?view=azure-dotnet-preview&viewFallbackFrom=azure-dotnet

If you have high precision numbers, and many forms require more than Single provides, why are there no methods for AsDouble or AsDecimal? I suppose the workaround is to leave as string type and do the conversion in userland.

Environment: -Azure.AI.FormRecognizer v3.1.0-beta.4

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Comments:7 (4 by maintainers)

github_iconTop GitHub Comments

1reaction
Rodrick45commented, Oct 4, 2021

I was directing my comment at whoever will be fixing this issue in the toolkit. Your workaround seems fine and is similar to what we had to do. Sorry for the confusion.

0reactions
kinelskicommented, Feb 10, 2022

Update: the new DocumentField class introduced in SDK version 4.0.0-beta.1 contains an AsDouble method, as suggested. Here’s a complete migration guide if there’s any help needed in migrating to the new version: https://github.com/Azure/azure-sdk-for-net/blob/main/sdk/formrecognizer/Azure.AI.FormRecognizer/MigrationGuide.md

Closing this issue since it’s been solved long ago. Feel free to open a new one if there are any other concerns.

Read more comments on GitHub >

github_iconTop Results From Across the Web

Can we query (and use) field value from package without ...
A slightly more direct answer than Phil's is to say that using dynamic SOQL avoids locking in a dependency so is the way...
Read more >
How to change field value to null for certain conditions in a ...
I have a query where I select data from a table using TSQL. When one of the fields (field1) has a certain value,...
Read more >
Running a query based on a field value (set ...
Greetings! In simple terms, I'm trying to take a field value from one dataset (in this case, a field called "Activity" (Fields!Activity.
Read more >
Solved: Automation Query - Error: No fields or field value...
I have this automation with the function: Clone a change and the trigger is through a field...That is there is a button where...
Read more >
Query by field values in Azure Boards and Azure DevOps
You can create queries based on how one field's value compares to another using the comparison field operators. This query is useful to ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found