Commission Rate (Crystal Reports)

Abe,

Below are the calculations I use for Rep Rate. I believe I got these
with help from the group, though I can't recall who. You should be able
to convert these to numbers using CDbl () function around the
calculation.
I am sure there is a cleaner way to find this, but this was the way that
I found that worked, so I left it.
I believe you can get the number using this example...
CDbl (Left ({OrderDtl.RepRate}, (InStr ({OrderDtl.RepRate}, ";")-1))) to
get rep rate 1.
Good luck, I hope this helps.

Rep rate 1 = Left ({OrderDtl.RepRate}, (InStr ({OrderDtl.RepRate},
";")-1))

Rep rate 2 = Mid ({OrderDtl.RepRate},(InStr ({OrderDtl.RepRate},
";")+1), (InStr ((InStr ({OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")-(InStr ({OrderDtl.RepRate}, ";")))-1)

Rep rate 3 = Mid ({OrderDtl.RepRate},(InStr ((InStr ({OrderDtl.RepRate},
";")+1), {OrderDtl.RepRate}, ";")+1), (InStr ((InStr ((InStr
({OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")-(InStr ((InStr ({OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")))-1)

Rep rate 4 = Mid ({OrderDtl.RepRate},(InStr ((InStr ((InStr
({OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")+1), (InStr ((InStr ((InStr ((InStr
({OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")-(InStr ((InStr
((InStr ({OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")))-1) & "%"
Mid ({OrderDtl.RepRate},(InStr ((InStr ((InStr ((InStr
({OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1))

Rep rate 5 = Mid ({OrderDtl.RepRate},(InStr ((InStr ((InStr ((InStr
({OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1),
{OrderDtl.RepRate}, ";")+1), {OrderDtl.RepRate}, ";")+1))

Aaron Hoyt
Hittite Microwave


-----Original Message-----
From: Abe Klassen [mailto:ak@...]
Sent: Monday, October 04, 2004 4:41 PM
To: vantage@yahoogroups.com
Subject: [Vantage] Commission Rate (Crystal Reports)




Good afternoon,

I am writing a report in which I need to calculate the order
price minus commission. I have found the reprate in the OrderDtl and
Invcdtl tables but they are in string format and the string is split
into 5 in case there is a rep split, i.e. 10;0;0;0;0. I have tried using
"tonumber" to convert the string but crystal does not allow that. I can
use "replace" to change the ";" to "+" but it still will not allow me to
convert the string to a number.

Can anyone help me with this problem or, should I be looking at
a different field for this data?

Thank you,
Abe

[Non-text portions of this message have been removed]



Useful links for the Yahoo!Groups Vantage Board are: ( Note:
You must have already linked your email address to a yahoo id to enable
access. )
(1) To access the Files Section of our Yahoo!Group for Report
Builder and Crystal Reports and other 'goodies', please goto:
http://groups.yahoo.com/group/vantage/files/.
(2) To search through old msg's goto:
http://groups.yahoo.com/group/vantage/messages
(3) To view links to Vendors that provide Vantage services goto:
http://groups.yahoo.com/group/vantage/links



Yahoo! Groups Sponsor
ADVERTISEMENT
click here
<http://us.ard.yahoo.com/SIG=129em67la/M=295196.4901138.6071305.3001176/
D=groups/S=1705007183:HM/EXP=1097008568/A=2128215/R=0/SIG=10se96mf6/*htt
p://companion.yahoo.com>

<http://us.adserver.yahoo.com/l?M=295196.4901138.6071305.3001176/D=group
s/S=:HM/A=2128215/rand=899269192>


________________________________

Yahoo! Groups Links


* To visit your group on the web, go to:
http://groups.yahoo.com/group/vantage/

* To unsubscribe from this group, send an email to:
vantage-unsubscribe@yahoogroups.com
<mailto:vantage-unsubscribe@yahoogroups.com?subject=Unsubscribe>

* Your use of Yahoo! Groups is subject to the Yahoo! Terms
of Service <http://docs.yahoo.com/info/terms/> .




[Non-text portions of this message have been removed]
Good afternoon,

I am writing a report in which I need to calculate the order price minus commission. I have found the reprate in the OrderDtl and Invcdtl tables but they are in string format and the string is split into 5 in case there is a rep split, i.e. 10;0;0;0;0. I have tried using "tonumber" to convert the string but crystal does not allow that. I can use "replace" to change the ";" to "+" but it still will not allow me to convert the string to a number.

Can anyone help me with this problem or, should I be looking at a different field for this data?

Thank you,
Abe

[Non-text portions of this message have been removed]
Abe,

Reporting on Commissions is a real pain. There may be ways to do it
in Crystal, but when I saw the way the data was presented, I
immediately went to MS Access with it. I created queries to parse
out the data into their own fields. Getting the data into a table
format where everything was in a seperate column made creating the
report a whole lot easier. If you want to go this way and you need
some help, give me a shout.

Brian Stenglein
Clow Stamping Co.


--- In vantage@yahoogroups.com, "Abe Klassen" <ak@m...> wrote:
>
> Good afternoon,
>
> I am writing a report in which I need to calculate the order price
minus commission. I have found the reprate in the OrderDtl and
Invcdtl tables but they are in string format and the string is split
into 5 in case there is a rep split, i.e. 10;0;0;0;0. I have tried
using "tonumber" to convert the string but crystal does not allow
that. I can use "replace" to change the ";" to "+" but it still will
not allow me to convert the string to a number.
>
> Can anyone help me with this problem or, should I be looking at a
different field for this data?
>
> Thank you,
> Abe
>
> [Non-text portions of this message have been removed]