|
I wrote an excel formula to convert from AS/400 negative numbers to PC negative numbers. I don't see why the whole thing couldn't be done in reverse. What I do is make the last character a separate column (either by importing it that way, or by inserting a new column and then doing a =RIGHT(E2, 1). I then have a look up table that includes 0 though 9 and the other characters for -0 though -9. I then do a lookup on the previous column and get the number (0 though 9, -1 though -9, -0 I bring in as *). Then yet a third column that does something like: =E2 * 10 + ABS(E3) * if(E3 < 0, 1, -1) and finally my last column =if(e3 = *, E2 * 10, e5). It is done this way because there is no distinguishing between -0 and 0 (they are both 0) If you need the formulas let me know. After I open the file and set up all my columns, I copy this formula and insert it to the right of the numbers. I then copy the last column, and paste special, values, and delete all the stuff I used to calculate it. If I took the time I'm sure I could figure out how to do this in a VB Script, but I haven't yet *shrug*. It should be very easy to do the same thing in reverse. If e2 > 0 just export the number, otherwise change the last character to the value in the lookup table. "Aleti, Anil" wrote: > Adding to this I was wondering what happens if the input data contains > signed numeric fields with decimals(the value could be -ve). One of the > cases I had to get the sign into a different field and then write an RPG > program to manupulate the field and then get what I wanted. > > Is there any good way to get signed numeric data with decimals on to 400 > files. Does Access database exports help. > > Thanks, > Anil > > -----Original Message----- > From: Peter Dow [mailto:pcdow@yahoo.com] > Sent: Friday, November 05, 1999 12:57 AM > To: MIDRANGE-L@midrange.com > Subject: Re: Microsoft Access 'TO' AS400 > > How about: > > Open the MS Access database. > Select a table. > Use the File menu Save As/Export option. > Export it to an external file. > Choose type Text (.txt, .csv, etc.) > Click the Export button. > > You'll get an Export Text Wizard where you can choose fixed or delimited > etc. Then you have your choice of FTP, some file transfer utility (e.g. > Client Access), or just copy it to the AS/400's IFS and use the CPYFRMIMPF > command. > > HTH > > Peter Dow > Dow Software Services, Inc. > 909 425-0194 voice > 909 425-0196 fax > > ----- Original Message ----- > From: Eric Sundell PMI <ESundell@delta.org> > To: <MIDRANGE-L@midrange.com> > Sent: Thursday, November 04, 1999 12:20 PM > Subject: Microsoft Access 'TO' AS400 > > > Hey Everyone! > > I seem to remember a while ago in an article or something that explains > how > > to > > use Access for format a database to send to a AS400 and I just can't seem > to > > remember where. I know I can use ODBC, but don't wanna, scares me. Anyone > > heard > > of this or know how to do it? > > > > Thanx > > Eric Sundell > > AS400/PC Specialist > > > > "Of course it makes sense that every facet of our daily lives > > should depend upon the position of celestial bodies hundreds > > of millions of miles away." - Calvin and Hobbes > > +--- > > | This is the Midrange System Mailing List! > > | To submit a new message, send your mail to MIDRANGE-L@midrange.com. > > | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com. > > | To unsubscribe from this list send email to > MIDRANGE-L-UNSUB@midrange.com. > > | Questions should be directed to the list owner/operator: > david@midrange.com > > +--- > > __________________________________________________ > Do You Yahoo!? > Bid and sell for free at http://auctions.yahoo.com > > +--- > | This is the Midrange System Mailing List! > | To submit a new message, send your mail to MIDRANGE-L@midrange.com. > | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com. > | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. > | Questions should be directed to the list owner/operator: > david@midrange.com > +--- > +--- > | This is the Midrange System Mailing List! > | To submit a new message, send your mail to MIDRANGE-L@midrange.com. > | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com. > | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. > | Questions should be directed to the list owner/operator: david@midrange.com > +--- +--- | This is the Midrange System Mailing List! | To submit a new message, send your mail to MIDRANGE-L@midrange.com. | To subscribe to this list send email to MIDRANGE-L-SUB@midrange.com. | To unsubscribe from this list send email to MIDRANGE-L-UNSUB@midrange.com. | Questions should be directed to the list owner/operator: david@midrange.com +---
As an Amazon Associate we earn from qualifying purchases.
This mailing list archive is Copyright 1997-2024 by midrange.com and David Gibbs as a compilation work. Use of the archive is restricted to research of a business or technical nature. Any other uses are prohibited. Full details are available on our policy page. If you have questions about this, please contact [javascript protected email address].
Operating expenses for this site are earned using the Amazon Associate program and Google Adsense.