web
You’re offline. This is a read only version of the page.
close
Skip to main content

Announcements

News and Announcements icon
Community site session details

Community site session details

Session Id :
Power Platform Community / Forums / Power Apps / Patching combobox numb...
Power Apps
Answered

Patching combobox number value into ssms

(0) ShareShare
ReportReport
Posted on by Microsoft Employee

Hello friends,

 

I have a combobox which refers to a database in SQL Server Management Studio, which I am having a hard time patching.

 

It seems I have tried everything, but I am either getting, "Expected number, received text", "Expected number, received record", "arithmetic overflow error converting float to data type numeric" error, or something similarly problematic.

 

In my ssms DB, the field is "Project_ID (int, null)"

 

I have tried all combinations of Value(field.Text) and Value(field.Selected.text) field.Selected.Val. I am at a loss! any ideas?

 

(This is an excerpt of my patch, there are no errors in this patch when Project_ID is not included)

 

 

If(savingProjectRelated_1,
 If(
 savingType_2.SelectedText.Val = "RE",
 Set(
 varRecord,
 Patch(
 'mib.mib_tbl_std_Savings',
 Defaults('mib.mib_tbl_std_Savings'),
 {
 'Project_ID': Value(savingProjectID_1.SelectedText)
 }

 

 

 

Categories:
  • v-xiaochen-msft Profile Picture
    Microsoft Employee on at

    Hi @JosephineL ,

     

    I found this post with same issue.

    https://powerusers.microsoft.com/t5/Microsoft-Dataverse/Microsoft-SQL-Arithmetic-overflow-error/td-p/306033

    Could you try this:

    If(savingProjectRelated_1,
     If(
     savingType_2.SelectedText.Val = "RE",
     Set(
     varRecord,
     Patch(
     'mib.mib_tbl_std_Savings',
     Defaults('mib.mib_tbl_std_Savings'),
     {
     'Project_ID': Value(Text(savingProjectID_1.SelectedText, "[$-en-US]##.######"))
     }
    ))))

     

    Best Regards,

    Wearsky

  • Community Power Platform Member Profile Picture
    Microsoft Employee on at

    Hi, thanks for your response!

     

    It still did not work, but I think the problem may be that 'savingProjectID_1' is not a number, nor a text, it is a control. Do you know how this vhanges the way it needs to be patched?

  • Verified answer
    Community Power Platform Member Profile Picture
    Microsoft Employee on at

    I found the problem. The correct patch for my "Project_ID"-colllumn was : 

    Project_ID: savingProjectID_1.Selected.ProjectID

Under review

Thank you for your reply! To ensure a great experience for everyone, your content is awaiting approval by our Community Managers. Please check back later.

Helpful resources

Quick Links

Season of Sharing Community Challenge Winners!

Congratulations to our community stars!

Kudos to our 2025 Community Spotlight Honorees

Expanding mentorship, skilling, and AI innovation

Leaderboard > Power Apps

#1
11manish Profile Picture

11manish 243 Super User 2026 Season 2

#2
WarrenBelz Profile Picture

WarrenBelz 204 Most Valuable Professional

#3
Mohsin Ali Profile Picture

Mohsin Ali 122

Last 30 days Overall leaderboard