NCONVERT Output
Robert Edis
robeconsult at sbcglobal.net
Fri Dec 2 23:19:31 CST 2005
Sorry, I was getting confused by the requirement to
output the value with a decimal point. What I mean is
output the value to a file as a string value rather
than numeric. Instruct the program reading the file,
e.g. Excel, to treat the column as numeric.
Otherwise:
DEF numberitem FLOAT = NCONVERT(textitem * 100)/100
Blue
--- Robert Edis <robeconsult at sbcglobal.net> wrote:
> Try multipling the value for the number of decimal
> places and then use NCONVERT. After converting to a
> string split the integer and decimal parts and
> insert
> a decimal point. E.g. if it is dollars and cents
> multiple by 100 before NCONVERT then output the
> string
> as LEFT(item,n) + '.' + RIGHT(item,2).
>
> Blue
>
> --- Al Karman <alk at liasophia.com> wrote:
>
> > Not sure how much traction you'll get, but...try
> > messing with the picture
> > clause where you're defining your fields.
> >
> >
> >
> > Al
> >
> > Al Karman
> > Manager, Internet Systems
> > lia sophia
> > <mailto:alk at liasophia.com> alk at liasophia.com
> >
> > _____
> >
> > From:
> >
> powerh-l-bounces+alk=liasophia.com at lists.sowder.com
> >
>
[mailto:powerh-l-bounces+alk=liasophia.com at lists.sowder.com]
> > On Behalf Of
> > John Stires
> > Sent: Friday, December 02, 2005 9:08 AM
> > To: powerh-l at lists.sowder.com
> > Subject: NCONVERT Output
> >
> >
> >
> > One of my coworkers has been rather perplexed with
> > NCONVERT. He is
> > attempting to convert a number with a decimal
> > component. Instead of getting
> > a numeric with the decimal component still intact,
> > he is getting in integer
> > number. He has tried using NUM and FLOAT for the
> > receiving defined field.
> > Both with the same results.
> >
> >
> >
> > The ultimate goal is to produce a value with the
> > decimal component to save
> > in a file.
> >
> >
> >
> > It would seem that we are missing something
> obvious,
> > but what???
> >
> >
> >
> > We are running on a VAX with VMS 6.2 and
> PowerHouse
> > version 7.10.E6.
> >
> >
> >
> > I do not believe the fact that we are using this
> out
> > of an RDB database
> > would have any bearing on this.
> >
> >
> >
> > Any good ideas?
> >
> >
> >
> > Thanks,
> >
> > John
> >
> > > --
> > = = = = = = = = = = = = = = = = = = = = = = = = =
> =
> > = =
> > Mailing list: powerh-l at lists.sowder.com
> > Subscribe: "subscribe" in message body to
> > powerh-l-request at lists.sowder.com
> > Unsubscribe: "unsubscribe <password>" in
> > message body to powerh-l-request at lists.sowder.com
> > http://lists.sowder.com/mailman/listinfo/powerh-l
> > This list is closed, thus to post to the list you
> > must be a subscriber.
> >
>
>
> Robert JM Edis
> Principal Consultant
> Robert Edis Consulting
> P.O. Box 676
> Deerfield IL 60015
> USA
> 1-847-612-3863
> RobEConsult at sbcglobal.net
>
>
>
> --
> = = = = = = = = = = = = = = = = = = = = = = = = = =
> = =
> Mailing list: powerh-l at lists.sowder.com
> Subscribe: "subscribe" in message body to
> powerh-l-request at lists.sowder.com
> Unsubscribe: "unsubscribe <password>" in
> message body to powerh-l-request at lists.sowder.com
> http://lists.sowder.com/mailman/listinfo/powerh-l
> This list is closed, thus to post to the list you
> must be a subscriber.
>
More information about the powerh-l
mailing list