.
 News & Views
  The online information source for iSeries and mrc-Productivity Series users
.  May 2003  
Volume 3, Issue 5  
.
. . . . . . . . .
 

Hotline Question of the Month

by Margaret Jeronim
 

Question:

“I have a WEB/CGI retrieval that's sorting by "Customer Number". The problem is that "Customer Number" is an alpha field in our Manufacturing Software, and it's 8 positions long. However, we use 5 numbers as our identification for customer numbers.

So, we have a 5 number system that's in an 8 position alpha field. So when I try and search by "Customer Number", I have to put in 3 blank spaces before I type the customer in, to fill the 8 positions.

If I just put the number in and click on "Contains", the report takes way too long, but it works. Is there anything I can do to have it ignore the blanks needed to make it 8 positions, so I don't have to use the contains feature?”



Answer:

You can create a substring on the dictionary level and use that substring in your application.

Here are the steps:
Go to option 32 in the mrc menu and then look for the file that contains the "Customer Number" in 8 alpha field.

Put 5 next to that file to access fields.

Press F6 to create, and give it a description and a name.


You should then be able to select a field from a file (F4 to prompt), and specify the starting position and the length.

Press enter when you're done.

Go back to your retrieval and select option 1 to add this new field to your application. Then, go to option 2 and select that field as a sequence. Recompile your app.



Have a hotline question of your own? Send an e-mail to support@mrc-productivity.com and let our product specialists help you!



.
. Quick Links...

Visit mrc's Web site

See a live demo

Get more information

View Latest Newsletter

Last Month's Newsletter

.
.
.
.
. Contact mrc...

U.S. Offices
mrc@mrc-productivity.com

voice: 630-916-0662

www.mrc-productivity.com



U.K. Offices
michaels, ross & cole (UK) ltd

voice (UK): +44 (0)20 8282 1600

mail@mrcuk.com


.
 mrc publishes this newsletter on a monthly basis. Subscription is free of charge. Please send any questions or comments about this newsletter to news@mrc-productivity.com. This newsletter is edited by Heather Gately.

To unsubscribe, please just reply to this e-mail with Unsubscribe in the subject line.
View our privacy promise.

.