[U2] Hello

2012-03-05 Thread u2ug
Is the list alive ? Haven't seen anything for a week. ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: [U2] Hello

2012-03-05 Thread Jeff Schasny
I'm afraid we're all quite dead. Haven't you heard about the zombies? u2ug wrote: Is the list alive ? Haven't seen anything for a week. ___ U2-Users mailing list U2-Users@listserver.u2ug.org http://listserver.u2ug.org/mailman/listinfo/u2-users

Re: [U2] Hello

2012-03-05 Thread Dave Laansma
Okay, I've got a pretty simple question ... How do I get a list of all files that are currently OPEN so I know whether I need to open a given file again? Sincerely, David Laansma IT Manager Hubbard Supply Co. Direct: 810-342-7143 Office: 810-234-8681 Fax: 810-234-6142 www.hubbardsupply.com

Re: [U2] Hello

2012-03-05 Thread Israel, John R.
I assume you have some way of knowing what files you want. Do something like: IF (FILEINFO(yourfilename, 0) = 0) THEN OPEN yourfilename ... END John -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Dave

Re: [U2] Hello

2012-03-05 Thread Wjhonson
I don't think this will work. In your example John, you need to know the file variable assigned to the file. So IF (FILEINFO(CUSTOMER,0)=0) THEN OPEN CUSTOMER TO CUSTOMER ELSE... But you can't use FILEINFO to check CUSTOMER, only to check CUSTOMER. So you can't tell if a file is opened

Re: [U2] Hello

2012-03-05 Thread David Wolverton
In that case, where every file is named FILE in your programs, but you want to make sure FILE is opened against CUSTOMER, I would guess you would do this: IF (FILEINFO(FILE, 0) = 0) THEN OPEN 'CUSTOMER' TO FILE ELSE END END ELSE IF FILEINFO(FILE,17) # CUSTOMER THEN CLOSE

Re: [U2] Hello

2012-03-05 Thread Wjhonson
I have to guess that the OP really wanted something like N.FILE = CUSTOMER; GOSUB CHECK.IF.FILE.IS.OPEN IF ERROR.FILE THEN OPEN N.FILE TO F.FILE ELSE do something here END ELSE IS.OPEN = TRUE END CHECK.IF.FILE.IS.OPEN: some function which checks if N.FILE exists in some rotating pool of

[U2] keeping track of opened files

2012-03-05 Thread Ed Clark
So the guru question is: Does either universe or unidata provide a way to get a list of opened files from some internal list or pool? I don't think so. Your application will need to keep track of each file as it opens them. Somewhere there's a universe technical bulletin that describes a method

Re: [U2] keeping track of opened files

2012-03-05 Thread Wjhonson
Yeah just be aware that you *cannot* setup file pointers in a dynamic array, but you can setup the names in a dynamic array So you would LOCATE N.FILE IN L.FILES SETTING W.FILE THEN F.FILE = FILES(W.FILE) END you have to use a dynamic for the names so you can do a locate, then you have to

Re: [U2] keeping track of opened files

2012-03-05 Thread David A. Green
Look at SYSTEM(50) David A. Green (480) 813-1725 DAG Consulting -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Ed Clark Sent: Monday, March 05, 2012 11:42 AM To: U2 Users List Subject: [U2] keeping track of opened

Re: [U2] keeping track of opened files

2012-03-05 Thread Bill Haskett
However, note that if you're using a web-environment, where your state variables are written to disk between browser calls, this won't work at all, since file-variables cannot be written to disk. So file open functions have to be done locally and not kept in common (as common may change from

Re: [U2] Hello

2012-03-05 Thread Symeon Breen
In unidata this would be in SYSTEM(50) not sure on UV , tho I presume it has something similar. -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Dave Laansma Sent: 05 March 2012 15:38 To: U2 Users List Subject: Re:

Re: [U2] keeping track of opened files

2012-03-05 Thread David A. Green
Unless, of course, you use a phantom process to do all of your I/O. David A. Green (480) 813-1725 DAG Consulting -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of Bill Haskett Sent: Monday, March 05, 2012 12:09 PM

Re: [U2] keeping track of opened files

2012-03-05 Thread Jeff Schasny
SYSTEM(50) in Universe Returns the field number of the last READNEXT statement when reading an exploded select list. I didn't find any documented way of getting a list of currently open files in Universe. David A. Green wrote: Unless, of course, you use a phantom process to do all of

Re: [U2] keeping track of opened files

2012-03-05 Thread Symeon Breen
Or used pooled connections :) -Original Message- From: u2-users-boun...@listserver.u2ug.org [mailto:u2-users-boun...@listserver.u2ug.org] On Behalf Of David A. Green Sent: 05 March 2012 19:19 To: 'U2 Users List' Subject: Re: [U2] keeping track of opened files Unless, of course, you use a

Re: [U2] Hello

2012-03-05 Thread Tony Gravagno
From: Dave Laansma How do I get a list of all files that are currently OPEN so I know whether I need to open a given file again? While our other colleagues are responding to the specific question, and I'm eager to see that discussion continue, I'll suggest that the real answer to the specific

Re: [U2] keeping track of opened files

2012-03-05 Thread Kate Stanton
Trap is if file pointer changes, as open file variable does not. Most common reasons are VOC pointer changing, or user logs to another account (where file pointers are different). Suggest additional array in the file common of (LOWERed) VOC record at time of opening: check each time someone

Re: [U2] Hello

2012-03-05 Thread David Jordan
I set up a function to open files. Instead of using the open file command in a program, I call the function. The function first calls the fileinfo command to see if the file is open and then returns otherwise it opens the file and returns. David Jordan

Re: [U2] Hello: keeping track of open files

2012-03-05 Thread Ed Clark
That will tell you if a particular variable contains a file pointer, which may be useful if you always use the same name for a file everywhere that it is used, but it doesn't help if you use different names. For example, if you had a program that took two file names as command line arguments

Re: [U2] keeping track of opened files

2012-03-05 Thread Ed Clark
On unidata, system(50) gives you a list of the names of files that have been opened, but doesn't give you the file pointer variables that they have been opened into. On universe there isn't an equivalent system() function that I can see. On Mar 5, 2012, at 2:07 PM, David A. Green wrote: Look