Lines of code in c-spec

5 pts.
Tags:
D-Spec
F Spec
RPGLE
How can I count the number of lines of code in c-spec with eliminating d and f-spec?

Answer Wiki

Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Discuss This Question: 4  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • Finkpad
    you could use SEU, then enter this in the SEU command :

    SEU==> f c 6 a     

    which means FIND 'C' in position 6 ALL

    it returns the total number of 'c' specs it finds as an information message at the bottom of the screen.

    115 pointsBadges:
    report
  • Finkpad
    of course this only works for old style RPGLE Column based code...
    115 pointsBadges:
    report
  • CharlieBrowne

    You can use SQL or other tools. To give you the "best" answer, we need more information.

    What is the purpose of this task?

    Is it for a single source member or all members in a soiurce file?

    Do you want comments and/or blank lines in the C spec area to be counted?

    Are there any members that use /FREE?

    41,430 pointsBadges:
    report
  • TomLiotta

    Are there ever any /free specs? Do you need to count C-spec comment lines? (Comments can be more time-consuming than they code they cover.) What about C-specs that are blank? If a C-spec statement covers ten lines, does it count as one or ten?

    SQL is pretty easy.

    select COUNT(*) from mylib/QRPGLESRC
    where upper(substr(SRCDTA, 6, 1)) = 'C' and
          substr(SRCDTA, 7, 1) <> '*' and
          substr(SRCDTA, 7, 70) <> ' '

    Use OVRDBF to choose a member, or use CREATE ALIAS to alias a member. Adjust the WHERE clause as needed.

    I haven't seen anyone care about counts of lines of code in more than ten years.

    Tom

    125,585 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following