Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations strongm on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

Line or a value 1

Status
Not open for further replies.

Senseial

Programmer
Feb 11, 2004
40
CA
Hello All

I have a small problem. I have a field that is a number.
I need to print a value if the value exists directly from a database (not a problem if the value does not exist I have to print a line (_________) ???
What is the best way and most efficient to do this.

Thanks a lot
 
You could use:

if isnull({table.number}) then "______" else
totext({table.number},0,"")

-LB
 
You know that field is a type NUMBER. How can I put a line in a number field?

Thanks
 
LBass means you have to create a formula field!

But if you're in CR9 version you can simply go in the format field >>> general >>> in the bottom there is a 'text' button and enter in it the formula

--------------------------------------------------
[highlight]Django[/highlight] [thumbsup]
bug exterminator
tips'n tricks addict
 
The formula above converts the number field to text. Since the results of a formula have to be of the same datatype, if you want one of the results to be a line created as a string, then the number field must also be converted to a string.

-LB
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top