select from unknown file

This Q&A forum allows users to post and respond to "How Do I Do ....." questions. Please do not use to report (suspected) errors - you must use your regional help desk for this. The information contained in this forum has not been validated by LANSA and, as such, LANSA cannot guarantee the accuracy of the information.
Post Reply
noamp
Posts: 15
Joined: Thu Nov 02, 2017 9:29 pm

select from unknown file

Post by noamp » Sun May 24, 2020 10:54 pm

hey,
i use lansa on ibm i,
i need to select records from unknown file.
the user will write the file name into field and the function need to select the record from that file.

Code: Select all

SELECT     FIELDS((*ALL)) FROM_FILE(#FILE)
ADD_ENTRY  TO_LIST(#LIST01) WITH_MODE(*DISPLAY)
ENDSELECT
please if someone know any way to do it.
thatks

soa
Posts: 339
Joined: Mon Dec 07, 2015 3:15 pm

Re: select from unknown file

Post by soa » Mon May 25, 2020 8:45 am

Use the ACCESS_FILE BIF or SELECT_SQL with a USING parameter.

noamp
Posts: 15
Joined: Thu Nov 02, 2017 9:29 pm

Re: select from unknown file

Post by noamp » Mon May 25, 2020 6:46 pm

soa wrote:
Mon May 25, 2020 8:45 am
Use the ACCESS_FILE BIF or SELECT_SQL with a USING parameter.
Thank you!

Post Reply