RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Allen E. Elwood
M "CLEARSELECT" STOP -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of Bright, Frank Sent: Monday, November 29, 2004 13:38 To: U2-Users Group (E-mail) Subject: [U2] Testing if a Unidata file has records or not! To All: I am writing an interesting pr

RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Kryka, Richard
I would do this: SEL.8 = 8 OPEN '', 'TEST.FILE' TO OPEN.FILE THEN SELECT OPEN.FILE TO SEL.8 READNEXT ID FROM SEL.8 THEN HAVE.RECORDS = 1 END ELSE HAVE.RECORDS = 0 END CLEARSELECT SEL.8 END This should work on UV and UD. Dick Kryka Director of Applications CCCS of Great

RE: Unclassified RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Kevin King
L PROTECTED] On Behalf Of HENDERSON MICHAEL MR Sent: Monday, November 29, 2004 3:17 PM To: [EMAIL PROTECTED] Subject: Unclassified RE: [U2] Testing if a Unidata file has records or not! Frank, I wouldn't do it that way! If the file actually has a gazillion records in it, "COUNT" cou

RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Larry Hiscock
1:38 PM To: U2-Users Group (E-mail) Subject: [U2] Testing if a Unidata file has records or not! To All: I am writing an interesting program. One that finds where a file is empty of records or not. I used the EXECUTE command with the COUNT command to get the number of records in a file. If its 0 th

Re: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Allen Egerton
On Mon, 29 Nov 2004 16:37:32 -0500, you wrote: >To All: > >I am writing an interesting program. One that finds where a file is empty of >records or not. I used the EXECUTE command with the COUNT command to get the >number of records in a file. If its 0 then the file is empty. > >But is there

RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Bob Woodward
le Grocery [EMAIL PROTECTED] > -Original Message- > From: [EMAIL PROTECTED] [mailto:owner-u2- > [EMAIL PROTECTED] On Behalf Of Bright, Frank > Sent: Monday, November 29, 2004 1:38 PM > To: U2-Users Group (E-mail) > Subject: [U2] Testing if a Unidata file has records or not! &g

Re: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Craig Bennett
Hi Frank, I'm not a UD expert, but how about this: OPEN "MYFILE" TO FH ELSE PRINT "FAILED TO OPEN MYFILE" STOP END SELECT FH * After a UniBASIC SELECT, SYSTEM(11) contains the number of items in the current group. If this is 0 then the file should be empty. IF SYSTEM(11) THEN PRIN

RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread [EMAIL PROTECTED]
> I am writing an interesting program. One that finds where a > file is empty of records or not. I used the EXECUTE command > with the COUNT command to get the number of records in a > file. If its 0 then the file is empty. > > But is there a better way as the execution command causes > problem

Unclassified RE: [U2] Testing if a Unidata file has records or not!

2004-11-29 Thread HENDERSON MICHAEL MR
END [This is the UniVerse syntax, but UDT should be similar] HTH Mike -Original Message- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of Bright, Frank Sent: Tuesday, 30 November 2004 10:38 To: U2-Users Group (E-mail) Subject: [U2] Testing if a Unidata file has re

[U2] Testing if a Unidata file has records or not!

2004-11-29 Thread Bright, Frank
To All: I am writing an interesting program. One that finds where a file is empty of records or not. I used the EXECUTE command with the COUNT command to get the number of records in a file. If its 0 then the file is empty. But is there a better way as the execution command causes problem in