Actually, in GETS^DIQ, the first argument is the file and the second is the IENS. If you set the FIELD argument to "*", that means you want all the fields in a file, and if you set it to "**", it means you want all fields in the file, including all fields in its subfiles, etc. The IENS is kind of like a URL for a file entry, giving you a string of internal entry numbers (hence the name) you must follow to get to the (sub)entry (remembering that subfiles may be nested arbitrarily). The call looks like this

D GETS^DIQ(file,iens,fields,flags,target_root,message_root)

(of which the first 3 arguments are required).

===
Gregory Woodhouse

"The policy of being too cautious is
the greatest risk of all."
--Jawaharlal Nehru


On Jul 11, 2005, at 6:26 AM, Robert H Dobbins/HOSPOPS/VET/UTIA wrote:


Kevin,

Here's are some Database Server/FM calls that will return all fields in a file, and subfile:  

     S FILE=20101
     S MSG=""
     S FDA=""
     S IENS="**"
     S FLAGS=""
     D GETS^DIQ(1,FILE,IENS,FLAGS,"FDA","MSG")


To get just the top-level fields from the file:

     S FILE=20101
     S MSG=""
     S FDA=""
     S IENS="*"  ;just change this from 2 asterisks to 1 asterisk
     S FLAGS=""
     D GETS^DIQ(1,FILE,IENS,FLAGS,"FDA","MSG")


HTH,
Bob

---------------------------------------------------------------
Robert H. Dobbins
IT Administrator III -- Computer Operations
Univ. of Tenn. -- College of Veterinary Medicine
2407 River Drive, Rm. A108
Knoxville, TN 37996-4500
(865) 974-5593
[EMAIL PROTECTED]
"Knowledge, Compassion, Discovery"
---------------------------------------------------------------

Reply via email to