Valid value but valid if Claims The entry is Invalid

Greetings

I have a Table with a Column that contains a reference.

I put a valid if statement to filter that allow a select list of reference values from the "Names Table

Let say

“Names Table”

Name ID Name
11 Bob
12 Sue
13 Jim

When I add an entry it works and I can only select from those three names.

However, I added an action on another table where the same reference is telling it to Place the Name ID into the proper column
and it works

If it is suppose to put Jim in the row when you look at the Raw table is has the value “13”
and the View displays “Jim”
But The Entry also says “The entry is invalid”

If Click the drop down to assign different name it gives me these option

Bob
Sue
Jim
Jim

Listing Jim twice (I guess the Correct Jim and my Jim)

I can remove the error by just removing the Valid if statement, But I still want that. If I add the entry without the action I still only want to get three options

And it is not just Jim. My action actually creates three new rows with these names in them and all three do the same thing.

Any Ideas on What I may be doing wrong here?

Thanks

Sounds like your action is setting the value of the Ref column to the Name instead of the Name ID.

I don’t understand what you’re trying to say here. Can you restate?

You cannot under any circumstances have two rows in a single table that have the same value in the table’s key column. It appears the key column for Names Table is the Name ID column. This limitation means, or instance, that you cannot have two rows in the Names Table that both have a Name ID column value of 13.

To better help you, it would help us to know what you’re trying to accomplish with the Names Table and the action that seems to be trying to re-add what’s already in the table.

Read more:

To keep with the Example,

The first Table “Names Table” has this information.

Name ID Name
11 Bob
12 Sue
13 Jim

“Name ID” is the Key and Name is the Label

There is a second table , lets call it “Friends Table”

Friend ID Order Name Address
54 Second 12 123 Main Str.

Friend ID is Key and Order is Label

The Detail view of Friends would show

Friend ID:54
Order: Second
Name: Sue
Address: 123 Main St.

The “Name” column of “Friends Table” References the “Names Table”.

Let’s delete all the records in Friends.

The “Name” Column of of Friends has a Valid if statement
Valid If = List(11,12,13)

When you open it in a Friends in a form and select the Drop Down for Name you get to select from
Bob
Sue
Jim
and when you look at the raw data
you see an 11, 12, or 13 in that Row.

Empty all rows again

My action adds all three rows automatically.

and the data in Friends ends up

Friend ID Order Name Address
53 First 11 123 Main St.
54 Second 12 123 Main St.
55 Third 13 124 Main St.

open Sue of those in a form and you will see

Friend ID:54
Order:Second
Name: Sue
This entry is invalid
Address: 123 Main St.

Select the Dropdown for Name and you will see
O Bob
O Sue
O Jim
X Sue

With the Bottom Sue Currently selected
If you select the the “Other Sue” Listed then the error goes away

Is that the actual Valid If expression? Or are you generating the list?

1 Like

Problem Fixed!!

That is just the shorthand I used for post for the valid if. It is actual a Select() statement.

Going Back get data for this response I noticed that my Valid if Select Statement was actually
Select(Names[Name]…) Which would return all the labels.

I changed that to
Select(Names[Name ID]…) and now the problem is fixed.

Guess I just needed a good nights sleep.

Thanks

1 Like