Welcome To The Home Of The Visual FoxPro Experts  
home. signup. forum. archives. search. google. articles. downloads. faq. members. weblogs. file info. rss.
 From: Anders Altberg
  Where is Anders Altberg?
 Uppsala
 Sweden
 Anders Altberg
 To: John Barrie
  Where is John Barrie?
 Memphis
 Tennessee - United States
 John Barrie
 Tags
Subject: RE: Int var taking max -ve value
Thread ID: 248650 Message ID: 249215 # Views: 3 # Ratings: 0
Version: Visual FoxPro 8 Category: Errors & Debugging
Date: Wednesday, December 30, 2009 1:41:00 PM         
   


> Hello experts - I hope this is in the correct category
>
> I have an integer variable that is initially taken from a view on an SQL Server table field (type int), then saved to a Form property and incremented as a counter (it keeps track of an item's position in a scan process). This variable has sporadically been taking the value of -2^31 (maximum negative value for int), for no apparent reason that I can decipher. The strange thing is that this issue only appeared recently - the program is part of an inventory-taking application that runs once a year, and last year this did not happen at all. I'm stumped as to what could cause this - any ideas would be most welcome.
>
> Thanks
>
> John
>
> Extra - 28th December 2009
>
> This has got no replies so I thought maybe I should add more detail. I should stress that this problem has not only appeared on one machine - it showed up on several machines in various locations, ruling out hardware faults - the problem has to be with the software, whether with Foxpro itself, or with the way Foxpro is interacting with the Windows (XP) environment (perhaps something changed after a Windows update?). Again, any ideas as to a cause will be greatly welcomed.
>
> Thanks again.

Could you run the same query in th SQL Server Manager to see if this number is an artifact of VFP, or ODBC, or exctly what SQL Server produces?

-Anders

ENTIRE THREAD

Int var taking max -ve value Posted by John Barrie @ 12/22/2009 2:43:34 AM
RE: Int var taking max -ve value Posted by John Barrie @ 12/29/2009 6:47:05 PM
RE: Int var taking max -ve value Posted by kulwant singh @ 12/30/2009 5:45:46 AM
RE: Int var taking max -ve value Posted by Anders Altberg @ 12/30/2009 1:41:00 PM
RE: Int var taking max -ve value Posted by John Barrie @ 1/3/2010 11:04:50 PM