Salesforce and other SMB Solutions are coming soon. ×

# Text in place of number

## Recommended Posts

I have a calc field formatted as currency, however Iâ€™d like to have it display â€œQuoteâ€ instead of an actual dollar amount for some cases. Eg,

Volume_Price = Case(Qty>= 250; Single_Price*0.8; Qty>=500; Single_Price *0.6;Qty>500;â€Quoteâ€)

So when:

Qty = 100

Single_Price = \$25.00

Volume_Price = \$20.00

Any suggestions?

##### Share on other sites

Well, "Quote" is not a number, so you would need to set the result to Text. But then you would also need to format the result as currency in the calculation itself, which can get pretty complex.

You could take the easy way out by returning an empty result when Qty > 500, and use another calculation field =

Case ( Qty > 500 ; "Quote" )

to produce the label.

BTW, your calculation seems wrong. I don't know your business logic, but there is no result specified for Qty

##### Share on other sites

I'd like to ask what the reason for this is. What's a quote in this context?

kjoe

##### Share on other sites

BTW, your calculation seems wrong. I don't know your business logic, but there is no result specified for Qty

You're right, it should have been

##### Share on other sites

So as suggested, create a text calculation with:

Case(

Qty

Qty

”Quote”

)

... or produce a separate text calc to hold the Quote word.

##### Share on other sites

Would this work?

Case(

Qty

Qty

GetAsText (â€Quote")

)

##### Share on other sites

Would this work?

Case(

Qty

Qty

GetAsText (â€Quote")

)

Not in a calculaton field of type "number".

You can do it in a calculation field of type "text" (and don't need GetAsText for that). But then you can't do finds and sorts and sum-ups on the calc field assuming it to be a number. It wont behave like a number field even when it contains numbers, once it's designated as a text calc field.

##### Share on other sites

Not in a calculaton field of type "number".

You can do it in a calculation field of type "text" (and don't need GetAsText for that). But then you can't do finds and sorts and sum-ups on the calc field assuming it to be a number. It wont behave like a number field even when it contains numbers, once it's designated as a text calc field.

First Never say Never... Attached is a zip with pdf of field defs and a screen shot of results. Yes when mouse is not in the field... nothing.... But click in the field and see what's in it.

I am not saying I am right or this is the answer..... I am saying Never say Never.

Second..... Wow 52 Posts in since you joined on 8-20-2006 (4 days) ........Got a lot of time on your hands?

##### Share on other sites

First Never say Never... Attached is a zip with pdf of field defs and a screen shot of results. Yes when mouse is not in the field... nothing.... But click in the field and see what's in it.

I am not saying I am right or this is the answer..... I am saying Never say Never.

Yes, In my original works, this is how it worked, when clicking in the field it showed the quote, but once out it was gone, and is what lead me to the question...

I could always do it with two fields, the first one being the calc, number field with Case(Qty

##### Share on other sites

Second..... Wow 52 Posts in since you joined on 8-20-2006 (4 days) ........Got a lot of time on your hands?

Yes, I'm bored out of my skull. I'm overpaid to babysit a tertiary database for which no one has any design responsibilities. Change requests are rare and most often consist of 11-second stuff like "Could you add a checkbox field over here?" and "Can you make this field wider when it prints out?"

## Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

×   Pasted as rich text.   Paste as plain text instead

Only 75 emoji are allowed.

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×

• ### Images

• 0
By Soliant Consulting,
• 0
By Soliant Consulting,
• 0
By Soliant Consulting,
• ### Forum Statistics

• Total Topics
33.6k
• Total Posts
141.4k
×
×
• Create New...