Which command we can use to update a physical file using c.l pgm?

Answers were Sorted based on User's Feedback



Which command we can use to update a physical file using c.l pgm?..

Answer / vignesh c

We cant update a database file using cl

Is This Answer Correct ?    56 Yes 12 No

Which command we can use to update a physical file using c.l pgm?..

Answer / bharathi

We can not update files from CL programs. We can read files
from CL.

Is This Answer Correct ?    31 Yes 6 No

Which command we can use to update a physical file using c.l pgm?..

Answer / sidd

We can update physical files from CL program by either
usinf RUNSQLSTM or STRQMQRY

Is This Answer Correct ?    21 Yes 3 No

Which command we can use to update a physical file using c.l pgm?..

Answer / mithun paul

By using RUNSQLSMT or STRQMQRY.

Is This Answer Correct ?    17 Yes 3 No

Which command we can use to update a physical file using c.l pgm?..

Answer / sumit

Everyone is saying we cannot update pf using Cl...But please
try once using RUNSQLSTM before marking 'NO' to any answers.
As we can update a PF using CL.

RUNSQLSTM uses source file where source member is present.
And this source member contain UPDATE SQL, OR DELETE SQL, OR
INSERT SQL.

RUNSQLSTM SRCFILE(LIB/QSRCPF)SRCMBR(SQLPGM)COMMIT(*NONE)

Once this statement run in CL then PF will get updated,
deleted or inserted with the new record.

Is This Answer Correct ?    11 Yes 0 No

Which command we can use to update a physical file using c.l pgm?..

Answer / nagaraju

its not possible to update the physical file by using CL
program.

Is This Answer Correct ?    14 Yes 7 No

Which command we can use to update a physical file using c.l pgm?..

Answer / anupam

Use of RUNSQLSTM helps in updating the physical file within
a CL program.

Syntax:

RUNSQLSTM SRCFILE(LIB/QSRCPF)SRCMBR(SQLPGM)COMMIT(*NONE)

SQLPGM should contain

UPDATE PF set DATA='Value' where DATA'='Value1' and it will
update the PF

Is This Answer Correct ?    8 Yes 2 No

Which command we can use to update a physical file using c.l pgm?..

Answer / rajeev

We can not update a database file throught CL in a normal
way but if we use QSH then we can update or insert. Here I
am showing a exaple of insert.

QSH CMD('db2 "insert into $SCHEMA.$TABLE + VALUES(12,
5,''rajeev'', ''2009-11-24'',.2" ')

Is This Answer Correct ?    6 Yes 1 No

Which command we can use to update a physical file using c.l pgm?..

Answer / gaurav agrawal

In CL program we can not update the database file ,
we can read only.
if any doubt contact at gauravag.innovative@gmail.com

Is This Answer Correct ?    7 Yes 3 No

Which command we can use to update a physical file using c.l pgm?..

Answer / jaishriram

Did anyone tried to test Rajeev's Answer 13, Saying about to
update file using "QSH" ? Not sure....anyone gave a try.
But folks, it works. You know. He really discover a new way
of updating files from CL program.

Thanks Rajeev. Thanks a lot for sharing this tech info.

Is This Answer Correct ?    2 Yes 0 No

Post New Answer

More IBM AS400 AllOther Interview Questions

Good morning my experts.Im kuppi.im working as a software trainee on AS/400 technology.i have also joined with ibmi5 team.im trying to convert date with cl/400 coding.I have taken 2 parameters(like date and date types). A. If suppose date type is j,Now i want to convert date to *MDY format B. if date type is M,now i want to convert date to *JUL format C. sending a Program message with the value of converted date.

1 Answers  


Can you use multi format LF in CL program?

2 Answers  


How can you check the existence of object in a system?

1 Answers  


In which specification Data Structures can be defined?

1 Answers  


What is the exact difference between Service Program and Binding Directory?

1 Answers  






define a shared access path?

1 Answers   IBM,


when would you prefer logical file than opnqryf?

1 Answers   IBM,


how do you turn off indicators 50 through 59 in only one operation

1 Answers  


How can you identify End of file in CLP program?

1 Answers  


What are Triggers?

14 Answers   Ordain Solutions, Seabus Solutions,


why do we use readc? What is sflnxtchg?

0 Answers   IBM,


when are the referential constraints executed?

0 Answers   IBM,


Categories