• tacl routine

    From Akshaya Krishnan@21:1/5 to All on Wed Dec 1 21:59:53 2021
    Hi I need to write a tacl routine to get sytem month and date and generate a file (SBCmmdd).Can you please help

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Keith Dick@21:1/5 to Akshaya Krishnan on Wed Dec 1 23:31:18 2021
    On Wednesday, December 1, 2021 at 9:59:54 PM UTC-8, Akshaya Krishnan wrote:
    Hi I need to write a tacl routine to get sytem month and date and generate a file (SBCmmdd).Can you please help

    What part of that do you need help with?

    If you don't know how to get the TACL manual, go to www.hpe.com/info/nonstop-docs , click on the line for your type of NonStop system (L-series or J-series), enter "tacl ref" (without the quotes) into the search box, and the TACL Reference manual should
    be the top result. Click on the manual title and the document will open and you can read it online, or you can click the icon in the top right of the document display that is a downward-pointing arrow to download the PDF of the document to your computer.

    If you don't know which TACL functions to use, look up #timestamp, #contime, and #setmany. The #contime entry has some example code that will show you how to get the month and day from the [#contime [#timestamp]] result, but don't follow the rest of the
    example, because it is wrong (it does not take into account when the month or day is a single digit. To take care of when month or day are single digits, use two #if statements to test whether each of the month and day are less than 10, and if so,
    append a 0 to the beginning of the value. Then create the filename by the expression SBC[month][day] as the filename in whatever command you want to use to create the file.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Randall@21:1/5 to rkd...@gmail.com on Thu Dec 2 11:17:47 2021
    On Thursday, December 2, 2021 at 2:31:19 a.m. UTC-5, rkd...@gmail.com wrote:
    On Wednesday, December 1, 2021 at 9:59:54 PM UTC-8, Akshaya Krishnan wrote:
    Hi I need to write a tacl routine to get sytem month and date and generate a file (SBCmmdd).Can you please help
    What part of that do you need help with?

    If you don't know how to get the TACL manual, go to www.hpe.com/info/nonstop-docs , click on the line for your type of NonStop system (L-series or J-series), enter "tacl ref" (without the quotes) into the search box, and the TACL Reference manual
    should be the top result. Click on the manual title and the document will open and you can read it online, or you can click the icon in the top right of the document display that is a downward-pointing arrow to download the PDF of the document to your
    computer.

    If you don't know which TACL functions to use, look up #timestamp, #contime, and #setmany. The #contime entry has some example code that will show you how to get the month and day from the [#contime [#timestamp]] result, but don't follow the rest of
    the example, because it is wrong (it does not take into account when the month or day is a single digit. To take care of when month or day are single digits, use two #if statements to test whether each of the month and day are less than 10, and if so,
    append a 0 to the beginning of the value. Then create the filename by the expression SBC[month][day] as the filename in whatever command you want to use to create the file.

    There are also #INTERPRETTIMESTAMP #JULIANTIMESTAMP and #CONVERTTIMESTAMP to deal in 64-bit quantities so that you won't have to go back after the year 3000 ;)

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Bill Honaker@21:1/5 to Keith Dick on Thu Dec 2 17:00:49 2021
    On Wed, 1 Dec 2021 23:31:18 -0800 (PST), Keith Dick <rkdick@gmail.com> wrote:

    On Wednesday, December 1, 2021 at 9:59:54 PM UTC-8, Akshaya Krishnan wrote:
    Hi I need to write a tacl routine to get sytem month and date and generate a file (SBCmmdd).Can you please help

    What part of that do you need help with?

    If you don't know how to get the TACL manual, go to www.hpe.com/info/nonstop-docs , click on the line for your type of NonStop system (L-series or J-series), enter "tacl ref" (without the quotes) into the search box, and the TACL Reference manual should
    be the top result. Click on the manual title and the document will open and you can read it online, or you can click the icon in the top right of the document display that is a downward-pointing arrow to download the PDF of the document to your computer.

    If you don't know which TACL functions to use, look up #timestamp, #contime, and #setmany. The #contime entry has some example code that will show you how to get the month and day from the [#contime [#timestamp]] result, but don't follow the rest of
    the example, because it is wrong (it does not take into account when the month or day is a single digit. To take care of when month or day are single digits, use two #if statements to test whether each of the month and day are less than 10, and if so,
    append a 0 to the beginning of the value. Then create the filename by the expression SBC[month][day] as the filename in whatever command you want to use to create the file.


    You may also get some good knowledge by using the TACL Programmers Guid (Searhc for 'tacl prog'). It has some time conversion examples.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From j-marcus@pacbell.net@21:1/5 to All on Thu Dec 2 15:47:48 2021
    ?tacl macro
    #frame
    #push Year Month Day theFile
    #setmany Year Month Day, [#contime [#timestamp]]
    [#if ([#charcount Month] < 2) |THEN| #set Month 0[Month]]
    [#if ([#charcount Day] < 2) |THEN| #set Day 0[Day]]
    #set theFile SBC[Month][Day]
    fup create [theFile]
    #unframe

    Jon Marcus

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)
  • From Keith Dick@21:1/5 to Bill Honaker on Thu Dec 2 15:37:19 2021
    On Thursday, December 2, 2021 at 3:00:51 PM UTC-8, Bill Honaker wrote:
    On Wed, 1 Dec 2021 23:31:18 -0800 (PST), Keith Dick <rkd...@gmail.com> wrote:

    On Wednesday, December 1, 2021 at 9:59:54 PM UTC-8, Akshaya Krishnan wrote: >> Hi I need to write a tacl routine to get sytem month and date and generate a file (SBCmmdd).Can you please help

    What part of that do you need help with?

    If you don't know how to get the TACL manual, go to www.hpe.com/info/nonstop-docs , click on the line for your type of NonStop system (L-series or J-series), enter "tacl ref" (without the quotes) into the search box, and the TACL Reference manual
    should be the top result. Click on the manual title and the document will open and you can read it online, or you can click the icon in the top right of the document display that is a downward-pointing arrow to download the PDF of the document to your
    computer.

    If you don't know which TACL functions to use, look up #timestamp, #contime, and #setmany. The #contime entry has some example code that will show you how to get the month and day from the [#contime [#timestamp]] result, but don't follow the rest of
    the example, because it is wrong (it does not take into account when the month or day is a single digit. To take care of when month or day are single digits, use two #if statements to test whether each of the month and day are less than 10, and if so,
    append a 0 to the beginning of the value. Then create the filename by the expression SBC[month][day] as the filename in whatever command you want to use to create the file.

    You may also get some good knowledge by using the TACL Programmers Guid (Searhc for 'tacl prog'). It has some time conversion examples.

    I'd say to avoid #juliantimestamp and its related functions unless you want to work in GMT or in the time zone of another Guardian system in your network. The extra complication of dealing with time zone conversion usually would not be worth it if all
    you are interested in is working in the time zone of the local system.

    The TACL Programmer's Guide could be useful. I have not looked at it much. Just be careful with any example in any manual. Too many of them contain errors, as that example in the #contime manual entry does.

    --- SoupGate-Win32 v1.05
    * Origin: fsxNet Usenet Gateway (21:1/5)