Help between Notion users

It's free & easy

Receive points, vote and give the solution

1vote

# Need help with a Notion formula that autofills

I want to type in a "name" of something and it autofills with the "number" that it's set to. Example. Sofa = \$145

So when I am in a database, and I type sofa, I want the box to autofill to \$145 instead of sofa.

1vote

polle Points78500

That is not how Notion formulas work, you need 2 properties.

1- Name
2- Formula

In 1 you write the name: Sofa
In 2 you have something like this:

``if(prop("Name") == "Sofa", "\$145", "")``

If the name is equal to Sofa, show \$145, otherwise show nothing.

So if you have 20 variables, you will need to create a complete formula checking everything and displaying what you need.

Hope that helps.

1vote

### elysep commented Feb 29

That does work, thank you! How do I write it if I have 50 "names" to add in. I tried coping the formula and changing the item, but it didn't work. Is there a generic one?
As of now I have a column that is name and a column that is price. Can I do anything with that on the formula or do I have to create formula and type them all out?

1vote

### polle commented Feb 29

You will have to add all the ifs in the formula, using if or ifs.

Here is a simple example with if.

``if(prop("Name") == "Sofa", "\$145", if(prop("Name") == "Chair", "\$33", ""))``

If name is sofa show \$145, if name is chair show \$33, otherwise show nothing.

So following this example, you have to add as many conditions as you need.

Just use your properties names, where capital letters, spaces and everything matters.

The example using "Name" is not the same as "name", so you can use whatever you want.

1vote

### elysep commented Feb 29

That makes sense, thank you! I appreciate it!

0vote

0vote

### elysep commented Mar 5

Hi! I tried to do a formula with all of them and it isn't working, any tips?

``````if(prop("Item")== "2 Drawer Laterial File Cabinet", "75", if(prop("Item")== "4-5 Draw Laterial File Cabinet", "115",
if(prop("Item")== "Armoire", "150", if(prop("Item")== "Armoire Large", "195", if(prop("Item")== "Bar Stools", "45",
if(prop("Item")== "Bar Unit", "125",if(prop("Item")=="Buffet", "135",
if(prop("Item")=="Chair", "95",
if(prop("Item")=="Chaise", "110",
if(prop("Item")=="Chest", "110",
if(prop("Item")=="China (2 pierce), "145", if(prop("Item")=="China Cabinet (1 piece)", "115", if(prop("Item")=="Cocktail - Glass", "110", if(prop("Item")=="Cocktail - Stone", "125", if(prop("Item")=="Cocktail - Wood", "95", if(prop("Item")=="Computer Desk", "90", if(prop("Item")== "Conference Table", "145", if(prop("Item")== "Corner Desk", "75",
if(prop("Item")== "Credenza", "115",
if(prop("Item")== "Desk", "115", if(prop("Item")== "Dining Chairs", "35", if(prop("Item")== "Double Dresser", "95", if(prop("Item")== "End Table - Glass", "95",
if(prop("Item")== "End Table - Stone", "115",
if(prop("Item")== "End Table - Wood", "85",if(prop("Item")== "Entertainment Ctr", "140",
if(prop("Item")== "Entertainment Ctr Large", "185",if(prop("Item")== "Etegere", "105",if(prop("Item")== "Executive Chair", "55", if(prop("Item")== "Executive Desk", "145",if(prop("Item")== "Full Mattress or Box Spring", "45",
if(prop("Item")== "Hutch Top", "60",
if(prop("Item")== "King Complete Bed", "160',
if(prop("Item")== "King Mattress", "65",
if(prop("Item")== "Loveseat", "125",
if(prop("Item")== "Marble Tops", "35",if(prop("Item")== "Metal Bed Frame", "10",
if(prop("Item")== "Mirror", "75"
if(prop("Item")== "Nightstand", "85",
if(prop("Item")== "Ottoman", "55",
if(prop("Item")== "Pier Bed Wall", "225",
if(prop("Item")== "Queen Complete Bed", "135",if(prop("Item")== "Queen Mattress or Box Spring", "55",
if(prop("Item")== "Recliner", "95",if(prop("Item")== "Return", "70",
if(prop("Item")== "Rug w/ w Pad 8x10 & Smaller", "110",
if(prop("Item")== "Rug w/Pad 9x12 & Larger", "130",
if(prop("Item")== "Secretary Chair", "50",
if(prop("Item")== "Server", "115",
if(prop("Item")== "Single Dresser", "85",if(prop("Item")== "Sleeper Sofa", "165",
if(prop("Item")== "Sofa", "155",if(prop("Item")== "Sofa Table", "95"
if(prop("Item")= "Table - Glass", "145",
if(prop("Item")== "Table - Stone", "175",
if(prop("Item")== "Table - Wood", "125",
if(prop("Item")== "Triple Dresser", "115",if(prop("Item")== "TV Console", "125",
if(prop("Item")== "Twin Mattress Or Box Spring", "40",if(prop("Item")== "Vanity", "95",
if(prop("Item")== "Wall Units ea", "115",
if(prop("Item")== "Writing Desk", "105",
if(prop("Item")== "Decor", "20", ""))``````

...