Golgappa.net | Golgappa.org | BagIndia.net | BodyIndia.Com | CabIndia.net | CarsBikes.net | CarsBikes.org | CashIndia.net | ConsumerIndia.net | CookingIndia.net | DataIndia.net | DealIndia.net | EmailIndia.net | FirstTablet.com | FirstTourist.com | ForsaleIndia.net | IndiaBody.Com | IndiaCab.net | IndiaCash.net | IndiaModel.net | KidForum.net | OfficeIndia.net | PaysIndia.com | RestaurantIndia.net | RestaurantsIndia.net | SaleForum.net | SellForum.net | SoldIndia.com | StarIndia.net | TomatoCab.com | TomatoCabs.com | TownIndia.com
Interested to Buy Any Domain ? << Click Here >> for more details...

CAN WE INSERT FIELD IN PHYSICAL FILE BY USING OPNQRYF?

Answer Posted / manish kumar

MAPFLD is used to change the format of the fields used in
the OPNQRYF statement. When I say changing the format the
format of the field will not be changed but we can format
the data as we wish and store it in a diffrent variable.
For eg. You want check for year to be some value and are not
concerned abt date and month then you can follow as below.
OVRDBF FILE(FILEA) SHARE(*YES)
OPNQRYF FILE(FILEA) QRYSLT('YEAR *EQ "88" ') +
MAPFLD(YEAR '%SST(DATE 5 2)' *CHAR 2)
CALL PGM(PGMC)
CLOF OPNID(FILEA)
DLTOVR FILE(FILEA

Is This Answer Correct ?    9 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

How can we change the uppercase to Lowercase in RPG?

1432


what key word is used when screen is re-display?

1130


how to validate input values in display file ?

1225


how can you detect and handle a record lock situation?

1989


what are the various types of device files?

1686


how do you use exceptional write in c specs?

1903


what is xfoot opcode ?

1833


which type of object is used in db2/400?

1057


How to convert a spool file to PDF file in AS400?

1247


what is the use of jdftval in join logical file?

1806


which are the member types which seu supports?

1343


What is diff between EVAL & MOVE?

1584


Why we have multiple data types in As400 and why we use numeric, packed, decimal, zoned the basic difference between this?

1127


what are the different types of arrays available in rpg ?

1718


how can I control the way a remote browser uses its cache?

1212