support: Customer Portal
Focused on delivering choice, investment protection and flexibility to organizations with valuable COBOL assets
 

Veryant Knowledge Base
Home > All Categories > Data Access > Did you know you can use an alias to map a different disk file name to an existing "assign to" clause of the select statement without source code changes?
Question Title Did you know you can use an alias to map a different disk file name to an existing "assign to" clause of the select statement without source code changes?

To do so, you need to add 2 new properties to your configuration file:

iscobol.file.env_naming=true
iscobol.<assign_to_name>=<new-name>

where:

is the physical file name declared in the "assign to" clause of the "select". You need to specify the name with some normalization: you need to replace "-" with "_" and the name must be written in lower case

is the actual file name on the file system

For example, in the file with the following select

       select FILE1 assign to "file-1"
           organization indexed
           access dynamic
           record key f1-key
           status file-status
           .

the following properties must be set to use the new name "new-file-1"

iscobol.file.env_naming=true
iscobol.file_1=new-file-1

If the "assign to" contains a full or a relative path name, the path needs to be specified in the properties.

For example

       select FILE1 assign to "subdir/file-1"
           organization indexed
           access dynamic
           record key f1-key
           status file-status
           .
iscobol.file.env_naming=true
iscobol.subdir/file_1=subdir/new-file-1
Authored by: Veryant Support This question has been viewed 1604 times so far.
Click Here to View all the questions in Data Access category.
File Attachments File Attachments
There are no attachment file(s) related to this question.
How helpful was this article to you?
User Comments User Comments Add Comment
There are no user comments for this question. Be the first to post a comment. Click Here
Related Questions Related Questions
  1. File Types Comparison : isCOBOL - Micro Focus COBOL - ACUCOBOL-GT - RM/COBOL
  2. How do I interpret file status 9? and other EXFS extended file status codes (e.g. 9i,105)?
  3. What format does isCOBOL use for ORGANIZATION RELATIVE files?
  4. What is 9l,10 error and why is it happening?
  5. Does isCOBOL supports Data General file status codes?
  6. Can we use Micro Focus data format and indexed files directly or do they need some type of conversion?
  7. Can I install the UDBC 32 bit on my 64 bit computer in order to have the Veryant * driver for ODBC32 bits Administrator?
  8. Why do I get the error message “java.lang.ClassNotFoundException: ctree2" ?
  9. Can I call from an isCobol program a stored procedure?
  10. Why do I get 'ct_init ERROR 19:133:0' ?
  11. Did you know you can encrypt an indexed file?
Article Information Additional Information
Article Number: 273
Created: 2016-05-30 5:56 AM
Rating: No Rating
 
Article Options Article Options
Print Question Print this Question
Email Question Email Question to Friend
Export to Adobe PDF Export to PDF File
Export to MS Word Export to MS Word
Bookmark Article
Subscribe to Article Subscribe to Article
 
Search Knowledge Base Search Knowledge Base



 
 

© Veryant - All Rights Reserved
Veryant and isCOBOL are trademarks or registered marks of Veryant in the United States and other countries. All other marks are the property of their respective owners.