brillant or not

View: New views
20 Messages — Rating Filter:   Alert me  
< Prev | 1 - 2 - 3 | Next >

brillant or not

by jay rappaport :: Rate this Message:

| View Threaded | Show Only this Message

this discussion brings back memories from long long time ago, far far away


when the shortest working program we could come up with as a challenge in school was


input = output : f(end)




one line of code that actually did something


now if only i could remember what language this was in!


jay
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: brillant or not

by Charlie Noah :: Rate this Message:

| View Threaded | Show Only this Message

I can name that tune in...

On 01-17-2012 6:49 PM, jay rappaport wrote:

> this discussion brings back memories from long long time ago, far far away
>
>
> when the shortest working program we could come up with as a challenge in school was
>
>
> input = output : f(end)
>
>
>
>
> one line of code that actually did something
>
>
> now if only i could remember what language this was in!
>
>
> jay
> _______________________________________________
> U2-Users mailing list
> U2-Users@...
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: brillant or not

by Dave Laansma :: Rate this Message:

| View Threaded | Show Only this Message

"One difference between a smart programmer and a professional programmer
is that the professional understands that clarity is king. Professionals
use their powers for good and write code that others can understand."

Robert C. Martin - "Clean Code - A Handbook of Agile Software
Craftsmanship"

Sincerely,
David Laansma
IT Manager
Hubbard Supply Co.
Direct: 810-342-7143
Office: 810-234-8681
Fax: 810-234-6142
www.hubbardsupply.com
"Delivering Products, Services and Innovative Solutions"

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of jay rappaport
Sent: Tuesday, January 17, 2012 7:50 PM
To: u2-users@...
Subject: [U2] brillant or not

this discussion brings back memories from long long time ago, far far
away


when the shortest working program we could come up with as a challenge
in school was


input = output : f(end)




one line of code that actually did something


now if only i could remember what language this was in!


jay
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch of assigning of variables so that I can use them as needed.  One of these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066 (which is 12/26/11).  This program is initiated via a Redback call but so are many many others.

In the pgm that is failing, immediately after my INCLUDE, I just added code to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.  The same program is working correctly in other accounts, and the value of TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I should recompile EVERY program that uses the INCLUDE (and that is NOT going to happen).


John





John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of the intended recipient(s) and may contain information that is privileged, confidential or proprietary. If you are not an intended recipient, please notify the sender, and then please delete and destroy all copies and attachments, and be advised that any review or dissemination of, or the taking of any action in reliance on, the information contained in or attached to this message is prohibited.




_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by John Thompson-15 :: Rate this Message:

| View Threaded | Show Only this Message

It might be a global config item messing you up somewhere.
I had a look at uvconfig on my system... I found this, but,  it does not
"seem" to apply to your situation.  This is on Universe.  Not sure which
one you are on...

# OCVDATE - Specifies whether UniVerse accepts partially 'bad' internal date
#   data.  A zero value is the default and means that any value which
#   is not wholly numeric and which is supplied as an internal date
#   value to the command OCONV(<data>,'D') will be rejected as bad
#   and not converted.  A non-zero value for this parameter will allow
#   data which is a number followed by other data, e.g. 9199-f, to be
#   partially converted; the numbers up to the non-numeric character
#   will be interpreted as the internal date, and the STATUS() function
#   will be set to 3, indicating successful conversion of a possibly
#   invalid date.
OCVDATE 0

On Fri, Jan 20, 2012 at 12:36 PM, Israel, John R. <
JohnIsrael@...> wrote:

> I have an INCLUDE that I use in ALL programs I touch.  It simply does a
> bunch of assigning of variables so that I can use them as needed.  One of
> these assignments is:
> TODAY = @DATE
>
> I have 1 program in 1 account that is consistently returning: 16066 (which
> is 12/26/11).  This program is initiated via a Redback call but so are many
> many others.
>
> In the pgm that is failing, immediately after my INCLUDE, I just added
> code to write the following to disk:
> TODAY
> DATE()
> @DATE
>
> Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no
> others.  The same program is working correctly in other accounts, and the
> value of TODAY is correct in EVERY other program I have ever used.
>
> Does anyone have a clue?
>
> I could replace @DATE with DATE() in my INCLUDE, but to do my due
> diligence, I should recompile EVERY program that uses the INCLUDE (and that
> is NOT going to happen).
>
>
> John
>
>
>
>
>
> John Israel
> Senior ERP Developer
>
> Dayton Superior Corporation
> 1125 Byers Rd  Miamisburg, OH 45342
> Office: 937-866-0711 x44380
> Fax: 937-865-9182
>
> JohnIsrael@...
>
> This message w/attachments (message) is intended solely for the use of the
> intended recipient(s) and may contain information that is privileged,
> confidential or proprietary. If you are not an intended recipient, please
> notify the sender, and then please delete and destroy all copies and
> attachments, and be advised that any review or dissemination of, or the
> taking of any action in reliance on, the information contained in or
> attached to this message is prohibited.
>
>
>
>
> _______________________________________________
> U2-Users mailing list
> U2-Users@...
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>



--
John Thompson
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

I am on UniData.

I don't think the below applies in my case because I am not entering any data.  I am simply forcing a variable to @DATE.

John

-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of John Thompson
Sent: Friday, January 20, 2012 12:59 PM
To: U2 Users List
Subject: Re: [U2] Date Problem

It might be a global config item messing you up somewhere.
I had a look at uvconfig on my system... I found this, but,  it does not
"seem" to apply to your situation.  This is on Universe.  Not sure which
one you are on...

# OCVDATE - Specifies whether UniVerse accepts partially 'bad' internal date
#   data.  A zero value is the default and means that any value which
#   is not wholly numeric and which is supplied as an internal date
#   value to the command OCONV(<data>,'D') will be rejected as bad
#   and not converted.  A non-zero value for this parameter will allow
#   data which is a number followed by other data, e.g. 9199-f, to be
#   partially converted; the numbers up to the non-numeric character
#   will be interpreted as the internal date, and the STATUS() function
#   will be set to 3, indicating successful conversion of a possibly
#   invalid date.
OCVDATE 0

On Fri, Jan 20, 2012 at 12:36 PM, Israel, John R. <
JohnIsrael@...> wrote:

> I have an INCLUDE that I use in ALL programs I touch.  It simply does a
> bunch of assigning of variables so that I can use them as needed.  One of
> these assignments is:
> TODAY = @DATE
>
> I have 1 program in 1 account that is consistently returning: 16066 (which
> is 12/26/11).  This program is initiated via a Redback call but so are many
> many others.
>
> In the pgm that is failing, immediately after my INCLUDE, I just added
> code to write the following to disk:
> TODAY
> DATE()
> @DATE
>
> Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no
> others.  The same program is working correctly in other accounts, and the
> value of TODAY is correct in EVERY other program I have ever used.
>
> Does anyone have a clue?
>
> I could replace @DATE with DATE() in my INCLUDE, but to do my due
> diligence, I should recompile EVERY program that uses the INCLUDE (and that
> is NOT going to happen).
>
>
> John
>
>
>
>
>
> John Israel
> Senior ERP Developer
>
> Dayton Superior Corporation
> 1125 Byers Rd  Miamisburg, OH 45342
> Office: 937-866-0711 x44380
> Fax: 937-865-9182
>
> JohnIsrael@...
>
> This message w/attachments (message) is intended solely for the use of the
> intended recipient(s) and may contain information that is privileged,
> confidential or proprietary. If you are not an intended recipient, please
> notify the sender, and then please delete and destroy all copies and
> attachments, and be advised that any review or dissemination of, or the
> taking of any action in reliance on, the information contained in or
> attached to this message is prohibited.
>
>
>
>
> _______________________________________________
> U2-Users mailing list
> U2-Users@...
> http://listserver.u2ug.org/mailman/listinfo/u2-users
>



--
John Thompson
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Allen Egerton-2 :: Rate this Message:

| View Threaded | Show Only this Message

On 1/20/2012 12:36 PM, Israel, John R. wrote:

> I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch of assigning of variables so that I can use them as needed.  One of these assignments is:
> TODAY = @DATE
>
> I have 1 program in 1 account that is consistently returning: 16066 (which is 12/26/11).  This program is initiated via a Redback call but so are many many others.
>
> In the pgm that is failing, immediately after my INCLUDE, I just added code to write the following to disk:
> TODAY
> DATE()
> @DATE
>
> Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.  The same program is working correctly in other accounts, and the value of TODAY is correct in EVERY other program I have ever used.
>
> Does anyone have a clue?
>
> I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I should recompile EVERY program that uses the INCLUDE (and that is NOT going to happen).


@DATE is writable, check to see if you're inadvertently over-writing it
in that one program.

Example code:
0001:       CRT "DATE():  ": DATE()
0002:       CRT "@DATE :  ": @DATE
0003:       @DATE = "XY"
0004:       CRT "@DATE :  ": @DATE
0005:       STOP

Example results:
>RUN ADE.BP TT
DATE():  16091
@DATE :  16091
@DATE :  XY


--
allen egerton; aegerton@...
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

I thought of that, but the same programs are working in other accounts.  I have compared all source code between accounts and they are the same.

John






John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of the intended recipient(s) and may contain information that is privileged, confidential or proprietary. If you are not an intended recipient, please notify the sender, and then please delete and destroy all copies and attachments, and be advised that any review or dissemination of, or the taking of any action in reliance on, the information contained in or attached to this message is prohibited.




-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of Allen Egerton
Sent: Friday, January 20, 2012 1:07 PM
To: U2 Users List
Subject: Re: [U2] Date Problem

On 1/20/2012 12:36 PM, Israel, John R. wrote:

> I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch of assigning of variables so that I can use them as needed.  One of these assignments is:
> TODAY = @DATE
>
> I have 1 program in 1 account that is consistently returning: 16066 (which is 12/26/11).  This program is initiated via a Redback call but so are many many others.
>
> In the pgm that is failing, immediately after my INCLUDE, I just added code to write the following to disk:
> TODAY
> DATE()
> @DATE
>
> Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.  The same program is working correctly in other accounts, and the value of TODAY is correct in EVERY other program I have ever used.
>
> Does anyone have a clue?
>
> I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I should recompile EVERY program that uses the INCLUDE (and that is NOT going to happen).


@DATE is writable, check to see if you're inadvertently over-writing it
in that one program.

Example code:
0001:       CRT "DATE():  ": DATE()
0002:       CRT "@DATE :  ": @DATE
0003:       @DATE = "XY"
0004:       CRT "@DATE :  ": @DATE
0005:       STOP

Example results:
>RUN ADE.BP TT
DATE():  16091
@DATE :  16091
@DATE :  XY


--
allen egerton; aegerton@...
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by John Hester :: Rate this Message:

| View Threaded | Show Only this Message

I ran into an issue with @DATE many years ago, but this was on UV and
probably around version 8.3 or 9.5.1.  The problem I ran into was @DATE
failed in programs run as phantoms but worked fine if the program was
run via a terminal.  DATE() always worked correctly.  We had migrated
from Ultimate not too many years before, and all of our legacy code used
DATE(), so it wasn't a big deal for me to replace the few instances of
@DATE with DATE().  I haven't used @DATE since.

-John

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of Israel, John
R.
Sent: Friday, January 20, 2012 9:36 AM
To: 'U2 Users List'
Cc: Conway, Bruce; Majors,Larry
Subject: [U2] Date Problem

I have an INCLUDE that I use in ALL programs I touch.  It simply does a
bunch of assigning of variables so that I can use them as needed.  One
of these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066
(which is 12/26/11).  This program is initiated via a Redback call but
so are many many others.

In the pgm that is failing, immediately after my INCLUDE, I just added
code to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no
others.  The same program is working correctly in other accounts, and
the value of TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due
diligence, I should recompile EVERY program that uses the INCLUDE (and
that is NOT going to happen).


John





John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of
the intended recipient(s) and may contain information that is
privileged, confidential or proprietary. If you are not an intended
recipient, please notify the sender, and then please delete and destroy
all copies and attachments, and be advised that any review or
dissemination of, or the taking of any action in reliance on, the
information contained in or attached to this message is prohibited.




_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by WJhonson :: Rate this Message:

| View Threaded | Show Only this Message

How about the idea that this program has been running since that time, or otherwise, that this port/process/connection has never been LOGGED off since that time, and the Date is set based on that.  That is, you are never resetting it.



-----Original Message-----
From: Israel, John R. <JohnIsrael@...>
To: 'U2 Users List' <u2-users@...>
Sent: Fri, Jan 20, 2012 10:08 am
Subject: Re: [U2] Date Problem


I thought of that, but the same programs are working in other accounts.  I have
ompared all source code between accounts and they are the same.
John



ohn Israel
enior ERP Developer
Dayton Superior Corporation
125 Byers Rd  Miamisburg, OH 45342
ffice: 937-866-0711 x44380
ax: 937-865-9182
JohnIsrael@...
This message w/attachments (message) is intended solely for the use of the
ntended recipient(s) and may contain information that is privileged,
onfidential or proprietary. If you are not an intended recipient, please notify
he sender, and then please delete and destroy all copies and attachments, and
e advised that any review or dissemination of, or the taking of any action in
eliance on, the information contained in or attached to this message is
rohibited.


----Original Message-----
rom: u2-users-bounces@... [mailto:u2-users-bounces@...]
n Behalf Of Allen Egerton
ent: Friday, January 20, 2012 1:07 PM
o: U2 Users List
ubject: Re: [U2] Date Problem
On 1/20/2012 12:36 PM, Israel, John R. wrote:
 I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch
f assigning of variables so that I can use them as needed.  One of these
ssignments is:
 TODAY = @DATE

 I have 1 program in 1 account that is consistently returning: 16066 (which is
2/26/11).  This program is initiated via a Redback call but so are many many
thers.

 In the pgm that is failing, immediately after my INCLUDE, I just added code to
rite the following to disk:
 TODAY
 DATE()
 @DATE

 Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.  
he same program is working correctly in other accounts, and the value of TODAY
s correct in EVERY other program I have ever used.

 Does anyone have a clue?

 I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I
hould recompile EVERY program that uses the INCLUDE (and that is NOT going to
appen).

DATE is writable, check to see if you're inadvertently over-writing it
n that one program.
Example code:
001:       CRT "DATE():  ": DATE()
002:       CRT "@DATE :  ": @DATE
003:       @DATE = "XY"
004:       CRT "@DATE :  ": @DATE
005:       STOP
Example results:
RUN ADE.BP TT
ATE():  16091
DATE :  16091
DATE :  XY

-
llen egerton; aegerton@...
______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

If it were just a few programs, I would not be too concerned.  However, it is an INCLUDE that is included in hundreds of programs, so the impact could be huge (even if the impact is to be correct).

However, I have "pulled the trigger" and replaced the @DATE to DATE() in the INCLUDE.  Some programs will need to be re-compiled, others will take the effect when next re-compiled.  This is NOT the solution I wanted, but appears to be the solution I must take...

Bummer


John

-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of John Hester
Sent: Friday, January 20, 2012 1:14 PM
To: U2 Users List
Subject: Re: [U2] Date Problem

I ran into an issue with @DATE many years ago, but this was on UV and
probably around version 8.3 or 9.5.1.  The problem I ran into was @DATE
failed in programs run as phantoms but worked fine if the program was
run via a terminal.  DATE() always worked correctly.  We had migrated
from Ultimate not too many years before, and all of our legacy code used
DATE(), so it wasn't a big deal for me to replace the few instances of
@DATE with DATE().  I haven't used @DATE since.

-John

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of Israel, John
R.
Sent: Friday, January 20, 2012 9:36 AM
To: 'U2 Users List'
Cc: Conway, Bruce; Majors,Larry
Subject: [U2] Date Problem

I have an INCLUDE that I use in ALL programs I touch.  It simply does a
bunch of assigning of variables so that I can use them as needed.  One
of these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066
(which is 12/26/11).  This program is initiated via a Redback call but
so are many many others.

In the pgm that is failing, immediately after my INCLUDE, I just added
code to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no
others.  The same program is working correctly in other accounts, and
the value of TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due
diligence, I should recompile EVERY program that uses the INCLUDE (and
that is NOT going to happen).


John





John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of
the intended recipient(s) and may contain information that is
privileged, confidential or proprietary. If you are not an intended
recipient, please notify the sender, and then please delete and destroy
all copies and attachments, and be advised that any review or
dissemination of, or the taking of any action in reliance on, the
information contained in or attached to this message is prohibited.




_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Allen Egerton-2 :: Rate this Message:

| View Threaded | Show Only this Message

On 1/20/2012 1:08 PM, Israel, John R. wrote:
> I thought of that, but the same programs are working in other accounts.  I have compared all source code between accounts and they are the same.
>
> John

Perhaps do a SEARCH of VOC and VOCLIB in the affected account, looking
for @DATE.  It's a session variable.  If you've ruled out source code
and are reasonably certain that it's only in a specific account, perhaps
there's a paragraph with a typo in it.

Oh yeah, if you've got a file with remote procedures in it, (like
VOCLIB), search that too...


--
allen egerton; aegerton@...
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Nancy Fisher :: Rate this Message:

| View Threaded | Show Only this Message

I also quit using @DATE and changed to DATE() as @DATE was not 100%
reliable.

Nancy Fisher
Peninsula Truck Lines, Inc
Federal Way, Washington
253/929-2040
Visit our Website www.peninsulatruck.com
nancyf@...


-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of Israel, John R.
Sent: Friday, January 20, 2012 10:20 AM
To: 'U2 Users List'
Subject: Re: [U2] Date Problem

If it were just a few programs, I would not be too concerned.  However, it
is an INCLUDE that is included in hundreds of programs, so the impact could
be huge (even if the impact is to be correct).

However, I have "pulled the trigger" and replaced the @DATE to DATE() in the
INCLUDE.  Some programs will need to be re-compiled, others will take the
effect when next re-compiled.  This is NOT the solution I wanted, but
appears to be the solution I must take...

Bummer


John

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of John Hester
Sent: Friday, January 20, 2012 1:14 PM
To: U2 Users List
Subject: Re: [U2] Date Problem

I ran into an issue with @DATE many years ago, but this was on UV and
probably around version 8.3 or 9.5.1.  The problem I ran into was @DATE
failed in programs run as phantoms but worked fine if the program was
run via a terminal.  DATE() always worked correctly.  We had migrated
from Ultimate not too many years before, and all of our legacy code used
DATE(), so it wasn't a big deal for me to replace the few instances of
@DATE with DATE().  I haven't used @DATE since.

-John

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of Israel, John
R.
Sent: Friday, January 20, 2012 9:36 AM
To: 'U2 Users List'
Cc: Conway, Bruce; Majors,Larry
Subject: [U2] Date Problem

I have an INCLUDE that I use in ALL programs I touch.  It simply does a
bunch of assigning of variables so that I can use them as needed.  One
of these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066
(which is 12/26/11).  This program is initiated via a Redback call but
so are many many others.

In the pgm that is failing, immediately after my INCLUDE, I just added
code to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no
others.  The same program is working correctly in other accounts, and
the value of TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due
diligence, I should recompile EVERY program that uses the INCLUDE (and
that is NOT going to happen).


John





John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of
the intended recipient(s) and may contain information that is
privileged, confidential or proprietary. If you are not an intended
recipient, please notify the sender, and then please delete and destroy
all copies and attachments, and be advised that any review or
dissemination of, or the taking of any action in reliance on, the
information contained in or attached to this message is prohibited.




_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users


_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

I thought of that, but this is going through Redback.  In my development and testing accounts, Redback is set to login, run the needed code, then log out.  This is slow, but avoids the cashing issue w/o bouncing Redback for every change I make.  Thus, the process should be new.

I could see it being set based on the last time Redback was bounced, but then why would it work in my development account but not my test account?

John






John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of the intended recipient(s) and may contain information that is privileged, confidential or proprietary. If you are not an intended recipient, please notify the sender, and then please delete and destroy all copies and attachments, and be advised that any review or dissemination of, or the taking of any action in reliance on, the information contained in or attached to this message is prohibited.




-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of Wjhonson
Sent: Friday, January 20, 2012 1:15 PM
To: u2-users@...
Subject: Re: [U2] Date Problem

How about the idea that this program has been running since that time, or otherwise, that this port/process/connection has never been LOGGED off since that time, and the Date is set based on that.  That is, you are never resetting it.



-----Original Message-----
From: Israel, John R. <JohnIsrael@...>
To: 'U2 Users List' <u2-users@...>
Sent: Fri, Jan 20, 2012 10:08 am
Subject: Re: [U2] Date Problem


I thought of that, but the same programs are working in other accounts.  I have
ompared all source code between accounts and they are the same.
John



ohn Israel
enior ERP Developer
Dayton Superior Corporation
125 Byers Rd  Miamisburg, OH 45342
ffice: 937-866-0711 x44380
ax: 937-865-9182
JohnIsrael@...
This message w/attachments (message) is intended solely for the use of the
ntended recipient(s) and may contain information that is privileged,
onfidential or proprietary. If you are not an intended recipient, please notify
he sender, and then please delete and destroy all copies and attachments, and
e advised that any review or dissemination of, or the taking of any action in
eliance on, the information contained in or attached to this message is
rohibited.


----Original Message-----
rom: u2-users-bounces@... [mailto:u2-users-bounces@...]
n Behalf Of Allen Egerton
ent: Friday, January 20, 2012 1:07 PM
o: U2 Users List
ubject: Re: [U2] Date Problem
On 1/20/2012 12:36 PM, Israel, John R. wrote:
 I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch
f assigning of variables so that I can use them as needed.  One of these
ssignments is:
 TODAY = @DATE

 I have 1 program in 1 account that is consistently returning: 16066 (which is
2/26/11).  This program is initiated via a Redback call but so are many many
thers.

 In the pgm that is failing, immediately after my INCLUDE, I just added code to
rite the following to disk:
 TODAY
 DATE()
 @DATE

 Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.
he same program is working correctly in other accounts, and the value of TODAY
s correct in EVERY other program I have ever used.

 Does anyone have a clue?

 I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I
hould recompile EVERY program that uses the INCLUDE (and that is NOT going to
appen).

DATE is writable, check to see if you're inadvertently over-writing it
n that one program.
Example code:
001:       CRT "DATE():  ": DATE()
002:       CRT "@DATE :  ": @DATE
003:       @DATE = "XY"
004:       CRT "@DATE :  ": @DATE
005:       STOP
Example results:
RUN ADE.BP TT
ATE():  16091
DATE :  16091
DATE :  XY

-
llen egerton; aegerton@...
______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

Sounds like a number of folks have been burned along these lines.  At least it isn't just me.

Thanks for the input.  Everyone have a great weekend!

John

-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of Nancy Fisher
Sent: Friday, January 20, 2012 1:22 PM
To: 'U2 Users List'
Subject: Re: [U2] Date Problem

I also quit using @DATE and changed to DATE() as @DATE was not 100%
reliable.

Nancy Fisher
Peninsula Truck Lines, Inc
Federal Way, Washington
253/929-2040
Visit our Website www.peninsulatruck.com
nancyf@...


-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of Israel, John R.
Sent: Friday, January 20, 2012 10:20 AM
To: 'U2 Users List'
Subject: Re: [U2] Date Problem

If it were just a few programs, I would not be too concerned.  However, it
is an INCLUDE that is included in hundreds of programs, so the impact could
be huge (even if the impact is to be correct).

However, I have "pulled the trigger" and replaced the @DATE to DATE() in the
INCLUDE.  Some programs will need to be re-compiled, others will take the
effect when next re-compiled.  This is NOT the solution I wanted, but
appears to be the solution I must take...

Bummer


John

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of John Hester
Sent: Friday, January 20, 2012 1:14 PM
To: U2 Users List
Subject: Re: [U2] Date Problem

I ran into an issue with @DATE many years ago, but this was on UV and
probably around version 8.3 or 9.5.1.  The problem I ran into was @DATE
failed in programs run as phantoms but worked fine if the program was
run via a terminal.  DATE() always worked correctly.  We had migrated
from Ultimate not too many years before, and all of our legacy code used
DATE(), so it wasn't a big deal for me to replace the few instances of
@DATE with DATE().  I haven't used @DATE since.

-John

-----Original Message-----
From: u2-users-bounces@...
[mailto:u2-users-bounces@...] On Behalf Of Israel, John
R.
Sent: Friday, January 20, 2012 9:36 AM
To: 'U2 Users List'
Cc: Conway, Bruce; Majors,Larry
Subject: [U2] Date Problem

I have an INCLUDE that I use in ALL programs I touch.  It simply does a
bunch of assigning of variables so that I can use them as needed.  One
of these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066
(which is 12/26/11).  This program is initiated via a Redback call but
so are many many others.

In the pgm that is failing, immediately after my INCLUDE, I just added
code to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no
others.  The same program is working correctly in other accounts, and
the value of TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due
diligence, I should recompile EVERY program that uses the INCLUDE (and
that is NOT going to happen).


John





John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of
the intended recipient(s) and may contain information that is
privileged, confidential or proprietary. If you are not an intended
recipient, please notify the sender, and then please delete and destroy
all copies and attachments, and be advised that any review or
dissemination of, or the taking of any action in reliance on, the
information contained in or attached to this message is prohibited.




_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users


_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by WJhonson :: Rate this Message:

| View Threaded | Show Only this Message


That the @DATE parameter is being stored, not in the login session per se, but in the environment which is wrapping around it.
Reboot your servers, then try it again.  I think it will change to today.



-----Original Message-----
From: Israel, John R. <JohnIsrael@...>
To: 'U2 Users List' <u2-users@...>
Sent: Fri, Jan 20, 2012 10:23 am
Subject: Re: [U2] Date Problem


I thought of that, but this is going through Redback.  In my development and
esting accounts, Redback is set to login, run the needed code, then log out.  
his is slow, but avoids the cashing issue w/o bouncing Redback for every change
 make.  Thus, the process should be new.
I could see it being set based on the last time Redback was bounced, but then
hy would it work in my development account but not my test account?
John



ohn Israel
enior ERP Developer
Dayton Superior Corporation
125 Byers Rd  Miamisburg, OH 45342
ffice: 937-866-0711 x44380
ax: 937-865-9182
JohnIsrael@...
This message w/attachments (message) is intended solely for the use of the
ntended recipient(s) and may contain information that is privileged,
onfidential or proprietary. If you are not an intended recipient, please notify
he sender, and then please delete and destroy all copies and attachments, and
e advised that any review or dissemination of, or the taking of any action in
eliance on, the information contained in or attached to this message is
rohibited.


----Original Message-----
rom: u2-users-bounces@... [mailto:u2-users-bounces@...]
n Behalf Of Wjhonson
ent: Friday, January 20, 2012 1:15 PM
o: u2-users@...
ubject: Re: [U2] Date Problem
How about the idea that this program has been running since that time, or
therwise, that this port/process/connection has never been LOGGED off since
hat time, and the Date is set based on that.  That is, you are never resetting
t.

-----Original Message-----
rom: Israel, John R. <JohnIsrael@...>
o: 'U2 Users List' <u2-users@...>
ent: Fri, Jan 20, 2012 10:08 am
ubject: Re: [U2] Date Problem

 thought of that, but the same programs are working in other accounts.  I have
mpared all source code between accounts and they are the same.
ohn

ohn Israel
nior ERP Developer
ayton Superior Corporation
25 Byers Rd  Miamisburg, OH 45342
fice: 937-866-0711 x44380
x: 937-865-9182
ohnIsrael@...
his message w/attachments (message) is intended solely for the use of the
tended recipient(s) and may contain information that is privileged,
nfidential or proprietary. If you are not an intended recipient, please notify
e sender, and then please delete and destroy all copies and attachments, and
 advised that any review or dissemination of, or the taking of any action in
liance on, the information contained in or attached to this message is
ohibited.

---Original Message-----
om: u2-users-bounces@... [mailto:u2-users-bounces@...]
 Behalf Of Allen Egerton
nt: Friday, January 20, 2012 1:07 PM
: U2 Users List
bject: Re: [U2] Date Problem
n 1/20/2012 12:36 PM, Israel, John R. wrote:
I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch
 assigning of variables so that I can use them as needed.  One of these
signments is:
TODAY = @DATE
 I have 1 program in 1 account that is consistently returning: 16066 (which is
/26/11).  This program is initiated via a Redback call but so are many many
hers.
 In the pgm that is failing, immediately after my INCLUDE, I just added code to
ite the following to disk:
TODAY
DATE()
@DATE
 Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.
e same program is working correctly in other accounts, and the value of TODAY
 correct in EVERY other program I have ever used.
 Does anyone have a clue?
 I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I
ould recompile EVERY program that uses the INCLUDE (and that is NOT going to
ppen).
DATE is writable, check to see if you're inadvertently over-writing it
 that one program.
xample code:
01:       CRT "DATE():  ": DATE()
02:       CRT "@DATE :  ": @DATE
03:       @DATE = "XY"
04:       CRT "@DATE :  ": @DATE
05:       STOP
xample results:
UN ADE.BP TT
TE():  16091
ATE :  16091
ATE :  XY
-
len egerton; aegerton@...
_____________________________________________
-Users mailing list
-Users@...
tp://listserver.u2ug.org/mailman/listinfo/u2-users
______________________________________________
-Users mailing list
-Users@...
tp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Israel, John R. :: Rate this Message:

| View Threaded | Show Only this Message

If so, that would explain why my test account was not working, but still leaves open the question of why does my development account work perfectly running the same code?

One of life's little mysteries...

John






John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of the intended recipient(s) and may contain information that is privileged, confidential or proprietary. If you are not an intended recipient, please notify the sender, and then please delete and destroy all copies and attachments, and be advised that any review or dissemination of, or the taking of any action in reliance on, the information contained in or attached to this message is prohibited.




-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of Wjhonson
Sent: Friday, January 20, 2012 1:29 PM
To: u2-users@...
Subject: Re: [U2] Date Problem


That the @DATE parameter is being stored, not in the login session per se, but in the environment which is wrapping around it.
Reboot your servers, then try it again.  I think it will change to today.



-----Original Message-----
From: Israel, John R. <JohnIsrael@...>
To: 'U2 Users List' <u2-users@...>
Sent: Fri, Jan 20, 2012 10:23 am
Subject: Re: [U2] Date Problem


I thought of that, but this is going through Redback.  In my development and
esting accounts, Redback is set to login, run the needed code, then log out.
his is slow, but avoids the cashing issue w/o bouncing Redback for every change
 make.  Thus, the process should be new.
I could see it being set based on the last time Redback was bounced, but then
hy would it work in my development account but not my test account?
John



ohn Israel
enior ERP Developer
Dayton Superior Corporation
125 Byers Rd  Miamisburg, OH 45342
ffice: 937-866-0711 x44380
ax: 937-865-9182
JohnIsrael@...
This message w/attachments (message) is intended solely for the use of the
ntended recipient(s) and may contain information that is privileged,
onfidential or proprietary. If you are not an intended recipient, please notify
he sender, and then please delete and destroy all copies and attachments, and
e advised that any review or dissemination of, or the taking of any action in
eliance on, the information contained in or attached to this message is
rohibited.


----Original Message-----
rom: u2-users-bounces@... [mailto:u2-users-bounces@...]
n Behalf Of Wjhonson
ent: Friday, January 20, 2012 1:15 PM
o: u2-users@...
ubject: Re: [U2] Date Problem
How about the idea that this program has been running since that time, or
therwise, that this port/process/connection has never been LOGGED off since
hat time, and the Date is set based on that.  That is, you are never resetting
t.

-----Original Message-----
rom: Israel, John R. <JohnIsrael@...>
o: 'U2 Users List' <u2-users@...>
ent: Fri, Jan 20, 2012 10:08 am
ubject: Re: [U2] Date Problem

 thought of that, but the same programs are working in other accounts.  I have
mpared all source code between accounts and they are the same.
ohn

ohn Israel
nior ERP Developer
ayton Superior Corporation
25 Byers Rd  Miamisburg, OH 45342
fice: 937-866-0711 x44380
x: 937-865-9182
ohnIsrael@...
his message w/attachments (message) is intended solely for the use of the
tended recipient(s) and may contain information that is privileged,
nfidential or proprietary. If you are not an intended recipient, please notify
e sender, and then please delete and destroy all copies and attachments, and
 advised that any review or dissemination of, or the taking of any action in
liance on, the information contained in or attached to this message is
ohibited.

---Original Message-----
om: u2-users-bounces@... [mailto:u2-users-bounces@...]
 Behalf Of Allen Egerton
nt: Friday, January 20, 2012 1:07 PM
: U2 Users List
bject: Re: [U2] Date Problem
n 1/20/2012 12:36 PM, Israel, John R. wrote:
I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch
 assigning of variables so that I can use them as needed.  One of these
signments is:
TODAY = @DATE
 I have 1 program in 1 account that is consistently returning: 16066 (which is
/26/11).  This program is initiated via a Redback call but so are many many
hers.
 In the pgm that is failing, immediately after my INCLUDE, I just added code to
ite the following to disk:
TODAY
DATE()
@DATE
 Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.
e same program is working correctly in other accounts, and the value of TODAY
 correct in EVERY other program I have ever used.
 Does anyone have a clue?
 I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I
ould recompile EVERY program that uses the INCLUDE (and that is NOT going to
ppen).
DATE is writable, check to see if you're inadvertently over-writing it
 that one program.
xample code:
01:       CRT "DATE():  ": DATE()
02:       CRT "@DATE :  ": @DATE
03:       @DATE = "XY"
04:       CRT "@DATE :  ": @DATE
05:       STOP
xample results:
UN ADE.BP TT
TE():  16091
ATE :  16091
ATE :  XY
-
len egerton; aegerton@...
_____________________________________________
-Users mailing list
-Users@...
tp://listserver.u2ug.org/mailman/listinfo/u2-users
______________________________________________
-Users mailing list
-Users@...
tp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by WJhonson :: Rate this Message:

| View Threaded | Show Only this Message


That you hadn't actually run this code in dev before.  So it's set the first time it's run and stays set.
Or that you bounced the environment.  Or someone else did and didn't tell you.
Or that you're pooling on one, and not the other, leaving sessions open *not actually connect-ing-, but staying connect-ed-*
Computers are a mystery!!  Cosmic rays!

That's what we always used to say in the days when we thought disk drives were getting so small they would be subject to the random interference of cosmic rays.... hey.  They're smaller today.  When do we get quantum fluctuations?  Information is limited by physics.



-----Original Message-----
From: Israel, John R. <JohnIsrael@...>
To: 'U2 Users List' <u2-users@...>
Sent: Fri, Jan 20, 2012 10:37 am
Subject: Re: [U2] Date Problem


If so, that would explain why my test account was not working, but still leaves
pen the question of why does my development account work perfectly running the
ame code?
One of life's little mysteries...
John



ohn Israel
enior ERP Developer
Dayton Superior Corporation
125 Byers Rd  Miamisburg, OH 45342
ffice: 937-866-0711 x44380
ax: 937-865-9182
JohnIsrael@...
This message w/attachments (message) is intended solely for the use of the
ntended recipient(s) and may contain information that is privileged,
onfidential or proprietary. If you are not an intended recipient, please notify
he sender, and then please delete and destroy all copies and attachments, and
e advised that any review or dissemination of, or the taking of any action in
eliance on, the information contained in or attached to this message is
rohibited.


----Original Message-----
rom: u2-users-bounces@... [mailto:u2-users-bounces@...]
n Behalf Of Wjhonson
ent: Friday, January 20, 2012 1:29 PM
o: u2-users@...
ubject: Re: [U2] Date Problem

hat the @DATE parameter is being stored, not in the login session per se, but
n the environment which is wrapping around it.
eboot your servers, then try it again.  I think it will change to today.

-----Original Message-----
rom: Israel, John R. <JohnIsrael@...>
o: 'U2 Users List' <u2-users@...>
ent: Fri, Jan 20, 2012 10:23 am
ubject: Re: [U2] Date Problem

 thought of that, but this is going through Redback.  In my development and
sting accounts, Redback is set to login, run the needed code, then log out.
is is slow, but avoids the cashing issue w/o bouncing Redback for every change
make.  Thus, the process should be new.
 could see it being set based on the last time Redback was bounced, but then
y would it work in my development account but not my test account?
ohn

ohn Israel
nior ERP Developer
ayton Superior Corporation
25 Byers Rd  Miamisburg, OH 45342
fice: 937-866-0711 x44380
x: 937-865-9182
ohnIsrael@...
his message w/attachments (message) is intended solely for the use of the
tended recipient(s) and may contain information that is privileged,
nfidential or proprietary. If you are not an intended recipient, please notify
e sender, and then please delete and destroy all copies and attachments, and
 advised that any review or dissemination of, or the taking of any action in
liance on, the information contained in or attached to this message is
ohibited.

---Original Message-----
om: u2-users-bounces@... [mailto:u2-users-bounces@...]
 Behalf Of Wjhonson
nt: Friday, January 20, 2012 1:15 PM
: u2-users@...
bject: Re: [U2] Date Problem
ow about the idea that this program has been running since that time, or
herwise, that this port/process/connection has never been LOGGED off since
at time, and the Date is set based on that.  That is, you are never resetting
.
-----Original Message-----
om: Israel, John R. <JohnIsrael@...>
: 'U2 Users List' <u2-users@...>
nt: Fri, Jan 20, 2012 10:08 am
bject: Re: [U2] Date Problem
 thought of that, but the same programs are working in other accounts.  I have
pared all source code between accounts and they are the same.
hn
ohn Israel
ior ERP Developer
yton Superior Corporation
5 Byers Rd  Miamisburg, OH 45342
ice: 937-866-0711 x44380
: 937-865-9182
hnIsrael@...
is message w/attachments (message) is intended solely for the use of the
ended recipient(s) and may contain information that is privileged,
fidential or proprietary. If you are not an intended recipient, please notify
 sender, and then please delete and destroy all copies and attachments, and
advised that any review or dissemination of, or the taking of any action in
iance on, the information contained in or attached to this message is
hibited.
---Original Message-----
m: u2-users-bounces@... [mailto:u2-users-bounces@...]
Behalf Of Allen Egerton
t: Friday, January 20, 2012 1:07 PM
 U2 Users List
ject: Re: [U2] Date Problem
 1/20/2012 12:36 PM, Israel, John R. wrote:
 have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch
assigning of variables so that I can use them as needed.  One of these
ignments is:
ODAY = @DATE
I have 1 program in 1 account that is consistently returning: 16066 (which is
26/11).  This program is initiated via a Redback call but so are many many
ers.
In the pgm that is failing, immediately after my INCLUDE, I just added code to
te the following to disk:
ODAY
ATE()
DATE
Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.
 same program is working correctly in other accounts, and the value of TODAY
correct in EVERY other program I have ever used.
Does anyone have a clue?
I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I
uld recompile EVERY program that uses the INCLUDE (and that is NOT going to
pen).
ATE is writable, check to see if you're inadvertently over-writing it
that one program.
ample code:
1:       CRT "DATE():  ": DATE()
2:       CRT "@DATE :  ": @DATE
3:       @DATE = "XY"
4:       CRT "@DATE :  ": @DATE
5:       STOP
ample results:
N ADE.BP TT
E():  16091
TE :  16091
TE :  XY

en egerton; aegerton@...
____________________________________________
Users mailing list
Users@...
p://listserver.u2ug.org/mailman/listinfo/u2-users
_____________________________________________
Users mailing list
Users@...
p://listserver.u2ug.org/mailman/listinfo/u2-users
______________________________________________
-Users mailing list
-Users@...
tp://listserver.u2ug.org/mailman/listinfo/u2-users
______________________________________________
-Users mailing list
-Users@...
tp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
2-Users mailing list
2-Users@...
ttp://listserver.u2ug.org/mailman/listinfo/u2-users

_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Bill Brutzman-2 :: Rate this Message:

| View Threaded | Show Only this Message

Revision control would say to create a new include file with its own revision ID... and then include the new include file in the program that needs it... perhaps in subsequent programs.

--Bill

-----Original Message-----
From: u2-users-bounces@... [mailto:u2-users-bounces@...] On Behalf Of Israel, John R.
Sent: Friday, January 20, 2012 12:36 PM
To: 'U2 Users List'
Cc: Conway, Bruce; Majors, Larry
Subject: [U2] Date Problem

I have an INCLUDE that I use in ALL programs I touch.  It simply does a bunch of assigning of variables so that I can use them as needed.  One of these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066 (which is 12/26/11).  This program is initiated via a Redback call but so are many many others.

In the pgm that is failing, immediately after my INCLUDE, I just added code to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.  The same program is working correctly in other accounts, and the value of TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence, I should recompile EVERY program that uses the INCLUDE (and that is NOT going to happen).


John





John Israel
Senior ERP Developer

Dayton Superior Corporation
1125 Byers Rd  Miamisburg, OH 45342
Office: 937-866-0711 x44380
Fax: 937-865-9182

JohnIsrael@...

This message w/attachments (message) is intended solely for the use of the intended recipient(s) and may contain information that is privileged, confidential or proprietary. If you are not an intended recipient, please notify the sender, and then please delete and destroy all copies and attachments, and be advised that any review or dissemination of, or the taking of any action in reliance on, the information contained in or attached to this message is prohibited.




_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: Date Problem

by Colin Alfke :: Rate this Message:

| View Threaded | Show Only this Message

Will's on the right track. @DATE (and @TIME) are set when the "original"
program is executed. In most use cases @DATE is interchangeable with DATE()
so most don't notice the difference. Although @DATE is available in
dictionaries. It's likely that that one program can be traced back to a
program running since then.

Here is a really quick test:
TEST.CALL.TIME
CRT 'orig program'
CRT '@TIME  ':OCONV(@TIME,'MTS')
CRT 'TIME() ':OCONV(TIME(),'MTS')
CALL TEST.TIME
CRT 'SLEEP 20 in orig program'
SLEEP 20
CALL TEST.TIME
CRT 'orig program'
CRT '@TIME  ':OCONV(@TIME,'MTS')
CRT 'TIME() ':OCONV(TIME(),'MTS')

TEST.TIME
CRT '@TIME       ':@TIME :"  ":OCONV(@TIME,'MTS')
CRT 'TIME()      ':TIME():"  ":OCONV(TIME(),'MTS')
CRT 'SLEEPING 10 SECONDS'
SLEEP 10
CRT '@TIME       ':@TIME :"  ":OCONV(@TIME,'MTS')
CRT 'TIME()      ':TIME():"  ":OCONV(TIME(),'MTS')
RETURN                                                    

Output:
:TEST.CALL.TIME            
orig program
@TIME  13:25:23
TIME() 13:25:23
@TIME       48323  13:25:23
TIME()      48323  13:25:23
SLEEPING 10 SECONDS
@TIME       48323  13:25:23
TIME()      48333  13:25:33
SLEEP 20 in orig program
@TIME       48323  13:25:23
TIME()      48353  13:25:53
SLEEPING 10 SECONDS
@TIME       48323  13:25:23
TIME()      48363  13:26:03
orig program
@TIME  13:25:23
TIME() 13:26:03

You can see how the @TIME variable carries the same value throughout. @DATE
works the same way.

hth
Colin
Calgary, Canada

-----Original Message-----
From: Israel, John R.

I have an INCLUDE that I use in ALL programs I touch.  It simply does a
bunch of assigning of variables so that I can use them as needed.  One of
these assignments is:
TODAY = @DATE

I have 1 program in 1 account that is consistently returning: 16066 (which
is 12/26/11).  This program is initiated via a Redback call but so are many
many others.

In the pgm that is failing, immediately after my INCLUDE, I just added code
to write the following to disk:
TODAY
DATE()
@DATE

Both TODAY and @DATE ALWAYS return 16066 for this 1 program, but no others.
The same program is working correctly in other accounts, and the value of
TODAY is correct in EVERY other program I have ever used.

Does anyone have a clue?

I could replace @DATE with DATE() in my INCLUDE, but to do my due diligence,
I should recompile EVERY program that uses the INCLUDE (and that is NOT
going to happen).


John


_______________________________________________
U2-Users mailing list
U2-Users@...
http://listserver.u2ug.org/mailman/listinfo/u2-users
< Prev | 1 - 2 - 3 | Next >