[x]
Posted via EE Mobile

Search, ask, and monitor your questions on the go with EE Mobile. Visit Experts Exchange from your mobile device and never be out of touch again.

Question
[x]
Attachment Details
[x]
The Solution Rating System

With so many solutions, how can you tell which solutions are most likely to help you and which ones are not? To provide you with a tool to use, we rate our solutions based on various elements that most accurately determine if a solution is a quality solution. To explain what factors affect the solution rating, here are the elements we take into consideration when formulating our solution rating.

  • The Grade of the Solution
  • The Zone Rank of the Expert Providing the Solution
  • The Number of Author and Expert Comments
  • The Number of Experts Contributing
  • The Feedback of the Community

Your Input Matters
Because of the way the system is set up, the most important variable in this equation is you. As a member of Experts Exchange, you are able to cast your vote on the quality of the solutions in regard to how complete, accurate, helpful and easy to understand each solution is. When you provide your feedback, each rating is adjusted accordingly. So, if you see a solution that has a poor rating that you think is a good solution, let us know by rating it. As you do, the rating will be adjusted and will become more accurate for other members of our site.

If you have any suggestions that you would like to make for our rating system, please ask a question in the Suggestions Zone of Community Support.

Thank you!

7.8

AS400 CL programming

Asked by barrygg in Programming for iSeries / AS400

Tags: as400, cl

Is it possible to write to a database physical file within a CL program, using data created through a variable e.g. current date value. I wish to write the &MSGDTA variable to a file for future processing.
             PGM                                                    
             DCLF       FILE(BGUNDRY/TESTDUMM)                      
             DCL        VAR(&ACTYEAR) TYPE(*CHAR) LEN(2)            
             DCL        VAR(&MSGDTA) TYPE(*CHAR) LEN(9)              
             DCL        VAR(&QDATE) TYPE(*CHAR) LEN(6)              
             DCL        VAR(&DAY) TYPE(*CHAR) LEN(2)                
             DCL        VAR(&MONTH) TYPE(*CHAR) LEN(2)              
             DCL        VAR(&YEAR2003) TYPE(*CHAR) LEN(4) +          
                          VALUE('2003')                              
             DCL        VAR(&YEAR2004) TYPE(*CHAR) LEN(4) +          
                          VALUE('2004')                              
             RTVSYSVAL SYSVAL(QDATE) RTNVAR(&QDATE)   /* DDMMYY */  
             CHGVAR VAR(&ACTYEAR) VALUE(%SST(&QDATE 5 2))            
             IF ((&ACTYEAR) *EQ '03') THEN(GOTO CALC1)              
             ELSE (GOTO CALC2)                                      
  CALC1: CHGVAR VAR(&DAY) VALUE(%SST(&QDATE 1 2))                    
            CHGVAR VAR(&MONTH) VALUE(%SST(&QDATE 3 2))                
CHGVAR VAR(&MSGDTA) VALUE('D' *CAT &YEAR2003 *CAT &MONTH *CAT &DAY)    
            GOTO SNDMSG                                                
 CALC2: CHGVAR VAR(&DAY) VALUE(%SST(&QDATE 1 2))                      
            CHGVAR VAR(&MONTH) VALUE(%SST(&QDATE 3 2))                
CHGVAR VAR(&MSGDTA) VALUE('D' *CAT &YEAR2004 *CAT &MONTH *CAT &DAY)    
 SNDMSG:    SNDPGMMSG  MSGID(CPF9898) MSGF(QCPFMSG) MSGDTA(&MSGDTA)    
            ENDPGM                                                    
***************** End of data ****************************************
[+][-]04/24/03 09:14 AM, ID: 8389688Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04/24/03 05:19 PM, ID: 8392027Accepted Solution

View this solution now by starting your 30-day free trial. Setting up your free trial is quick, easy, and secure. We will return you to this solution, unlocked, when you're done.

About this solution

Zone: Programming for iSeries / AS400
Tags: as400, cl
Sign Up Now!
Solution Provided By: shalomc
Participating Experts: 6
Solution Grade: A
 
[+][-]04/25/03 12:41 AM, ID: 8393398Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04/25/03 12:41 AM, ID: 8393401Author Comment

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 30-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]04/25/03 12:09 PM, ID: 8397533Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04/28/03 07:55 AM, ID: 8413316Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04/29/03 06:39 PM, ID: 8424835Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]04/30/03 03:08 PM, ID: 8431947Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]05/08/03 08:20 AM, ID: 8489357Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07/24/03 05:48 AM, ID: 8994548Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/01/04 05:08 PM, ID: 12469054Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/04 12:24 AM, ID: 12470706Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/04 12:37 PM, ID: 12477118Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/04 02:20 PM, ID: 12478305Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/02/04 05:07 PM, ID: 12479344Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/03/04 07:57 AM, ID: 12484276Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]11/05/04 07:06 PM, ID: 12511088Expert Comment

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 30-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20091021-EE-VQP-81