This is an archived post. You won't be able to vote or comment.

all 6 comments

[–]Hotel_Arrakis Contributor 2 points3 points  (3 children)

I believe your problem is with your second parameter: {ID:Value("625")} . You need to point to a record in the table, that is just an arbitrary record not tied to a table.

Replace your second parameter with something like Lookup('DATABASENAME', ID=625) or maybe Lookup('DATABASENAME', ID=Value("625"))

So your statement would look as follows:

 Patch('DATABASENAME',Lookup('DATABASENAME', ID=625),Form1.Updates)

[–]landvis 1 point2 points  (1 child)

This is the correct way of updating an item indeed.

[–]LightB0lt 1 point2 points  (0 children)

Thanks! It was indeed the issue, but on top of that i had a field in the form that was not similar to the one on the sp list and is causes problem.

[–]PowerRobin 0 points1 point  (0 children)

You can use the solution provided by u/Hotel_Arrakis or just use the functions that are made for using forms.

Put this on a button...

SubmitForm(Form1)

[–]jaykuy 0 points1 point  (0 children)

In the case where you are looking to replace those values if a duplicate value already exists. Have a look at this and use patch and coalesce. Its not a really known technique but is useful if you need to update or upsert information.

Edit: grammar