7RJ FLAG CÑl LINE CHÒl C-------------------------COMMANDS------------------------------ C* Undisplayed comment (like NOTE) - see also REMARK C? Display expression(s) on the console ? exp [,exp ...] Display expression(s) on a new line ?? exp [,exp ...] Concatenate to previous line ? Display CR,LF only C@ x,y Formatted screen or printer output @ x,y [SAY exp [USING 'format']] [GET var [PICTURE 'format']] Format chars: 9 or # = numeric '99,999.99' X = any char, A = alpha only $ or * = leading fill, ! = upcase on GET (GET takes effect only when READ command is executed). CACCEPT Input a character string from console ACCEPT 'prompt' TO memvar Display prompt, then input character string to memvar. ACCEPT TO memvar Input character string without prompt CAPPEND Add records to the current database APPEND Prompts for data input from console APPEND BLANK Adds a blank record (which you can then EDIT) APPEND FROM file [FOR exp] Add records from a DBASE file APPEND FROM file [FOR exp] SDF Add records from a standard text file (CR,LF ends record) APPEND FROM file [FOR exp] DELIMITED Add records from a BASIC file (commas between fields) CBROWSE Browse in database, modifying records as needed Uses full-screen editing controls: ^R=prev record, ^C=next record, ^Z=pan left, ^B=pan right, ^U=delete, ^W=exit w/save CCANCEL Abort execution of a command file CCHANGE Make multiple changes to database items CHANGE [scope] FIELD list [FOR exp] CHANGE FIELD f1,f2,... Prompts for changes to current record CHANGE FIELD f1,f2,... FOR condition On completion, advances to next record meeting condition CCLEAR Reset dBASE file and memory variables CCONTINUE Continue a LOCATE command CCOPY Copy data to another file COPY TO file STRUCTURE Copy structure only to a new .DBF file COPY [scope] TO file [FOR exp] Copy entire file (or part of it) to new .DBF file COPY [scope] TO file FIELD list [FOR exp] Copy designated fields only to new .DBF file COPY [scope] TO file [FOR exp] SDF Copy to an ASCII text file, with CR,LF at end of records COPY [scope] TO file [FOR exp] DELIMITED Copy to BASIC text file, with "," between fields and character fields enclosed in single quotes. COPY ..... DELIMITED WITH " Same, except character fields enclosed in double quotes. CCOUNT Count the number of records that satisfy some condition COUNT [scope] [FOR exp] Display count at console COUNT [scope] [FOR exp] TO memvar Store count in memvar CCREATE Create a new database Prompts for entry of the structure CDELETE Mark specified records for deletion DELETE [scope] [FOR exp] Default is current record. (Use PACK to complete deletion) CDELETE FILE filename Delete a file from disk CDISPLAY Show contents of data records (default=current record) DISPLAY [scope] [FOR exp] [exp list] [OFF] Show entire contents of selected records DISPLAY .... expressionlist Show values of specific items/expressions DISPLAY OFF ..... Suppress display of record number CDISPLAY STRUCTURE Show the structure of current database CDISPLAY MEMORY Show the contents of the memory variables CDISPLAY FILES DISPLAY FILES [ON diskdrive] Shows .DBF files only DISPLAY FILES LIKE ambiguousfilename [ON diskdrive] Show all files that match ambiguousfilename CDO filename Execute a command file CDO WHILE Repeats statements while is true. DO WHILE exp ..statements.. ENDDO CDO CASE Performs the first applicable CASE that follows CASE condition1 ..statements.. (performed if condition1=TRUE) CASE condition2 [OTHERWISE (only if no other case applies) ..statements..] ENDCASE CEDIT Alter data in the database EDIT recordnum Edit the designated record EDIT Edit the current record CEJECT Do a form-feed on the printer CELSE Alternate path for an IF command CENDCASE Terminates DO CASE command CENDDO Terminates DO WHILE command CENDIF Terminates IF command CERASE Clear console screen CFIND Locate record in an indexed database FIND key (Must USE database INDEX indexfile) CGOTO Position to given place in a database GOTO RECORD n GOTO TOP First record in database GOTO BOTTOM Last record in database CIF Conditional execution (up to ELSE or ENDIF) CINDEX Generate an indexfile and attach for USE INDEX ON exp TO indexfilename Indexfile becomes the current index CINPUT Input from console with type checking INPUT ['prompt'] TO memvar Same as ACCEPT except it checks for correct type CINSERT Insert a record into the database INSERT [BEFORE] Insert a record after[before] the current one INSERT BLANK [BEFORE] Insert a blank record CJOIN Create a new database combining PRIMARY & SECONDARY JOIN TO filename ON exp [FIELDS fieldlist] Create a new record where is TRUE (see manual) CLIST Show data records (default=all records) Same as DISPLAY except for default condition CLOCATE Find record without using index LOCATE [scope] [FOR exp] Does sequential search from current position CLOOP Used inside DO WHILE, goes to ENDDO CMODIFY COMMAND Modify a command file from dBASE MODIFY COMMAND filename (do NOT include the .CMD) CMODIFY STRUCTURE Modify structure of a data file (Deletes all data records - do COPY first) CNOTE Comment in command file, not displayed (also *) CPACK Eliminate records marked for deletion CQUIT Terminate DBASE QUIT TO 'command1' [,'command2',...] Terminate, then issue commands to CP/M CREAD Perform data entry for a formatted screen Activates GET fields set up by previous @ x,y commands CRECALL Unmark records marked for deletion RECALL [scope] [FOR exp] Qualifying records will be "un-deleted" CRELEASE Erase memory variables (to save space) RELEASE varlist Erase specified memory variables RELEASE ALL Erase all memory variables CREMARK Comment in command file, displayed on screen CRENAME Rename a disk file RENAME oldfilename TO newfilename Rename any file (assumes .DBF if no suffix) CREPLACE Alter data fields REPLACE [scope] field WITH exp [,field WITH exp ...] Changes content of specified data fields (Current record only if not specified) CREPORT Prepare a report from the datafile REPORT [scope] [FORM filename] [TO PRINT] [FOR exp] If does not exist, will prompt to create it. CRESET Reset CP/M after swapping disks CRESTORE Reload memvars from SAVEd file RESTORE FROM filename (Destroys all existing memvars and values) CRETURN Return from a command file CSAVE Save all memory variables for future RESTORE SAVE TO filename (creates filename.MEM) CSELECT Switch working areas SELECT PRIMARY SELECT SECONDARY CSET Set values for option parameters SET parameter ON SET parameter OFF SET parameter TO value CSKIP [number] Move forward (or back) in the database CSORT Generate a new sorted database (single key only) SORT ON key TO filename [ASCENDING][DESCENDING] (Note - INDEX, then COPY is more flexible and faster) CSTORE exp TO memvar Assignment statement for memory variables CSUM Compute the database sum for given fields/expressions SUM [scope] explist [TO memvarlist] [FOR exp] CTOTAL Generate an aggregated database TOTAL TO filename ON key [FIELDS fieldlist] CUPDATE Modify with data from another database UPDATE FROM filename ON key [ADD fieldlist] [REPLACE fieldlist] Perform ADDs and/or REPLACEs when keys match (Update file must be .DBF file sorted in key order) CUSE Opens the specified .DBF database file USE filename [INDEX filename [,filename...]] Open database with up to 7 index files USE Close previously open database CWAIT Wait for next keyboard character WAIT TO memvar Save char in memvar (CR = " ") WAIT Discard char and continue C F------------------------FUNCTIONS------------------------------- F# Current record number F* True if current record marked for deletion FDATE() Returns system date "mm/dd/yy" or "00/00/00" FEOF True if last record has been read FFILE(filename) True if file exists FTYPE(exp) "C"=Character, "N"=Numeric, "L"=Logical F TYPE(145) = "N" FINT(exp) Truncation to integer F INT(2.85) = 2 FVAL(stringexp) Convert string to integer F VAL("-3.7") = -3 FSTR(exp,width,dec) Convert numeric expression to string F STR(8/3,5,2) = " 2.66" ****Truncates!**** F STR(2.9,3) = " 2" FCHR(number) Convert number to ASCII F CHR(65) = "A" FLEN(string) Length of string F LEN("ABC") = 3 F@(target,string) Location of target in string F @("C","ABCD") = 3 F$(string,start,length) Substring function F $("ABCDEF",2,3) = "BCD" FTRIM(stringexp) Remove trailing blanks F TRIM("A B ") = "A B" F!(stringexp) Convert to uppercase F !("AbcD") = "ABCD" F&memvar Macro substitution (strings only) F &BASE = whatever's in BASE S------------------SET PARAMETERS------------------------- SALTERNATE OFF Save screen output on disk SBELL ON Sound bell when field is full SCARRY OFF Carry old record forward with APPEND SCOLON ON Bound GET items with colons in @ commands SCONFIRM OFF Wait for CR before exiting field on entry SCONSOLE ON Echo output to console SDEBUG OFF Send ECHO and STEP to printer SECHO OFF Echo command file on the console SEJECT OFF Enable page feed with REPORT SESCAPE ON Allow Esc to abort command file SEXACT OFF Require complete match for = SINTENSITY ON Dual intensity/Reverse Video SLINKAGE OFF Link databases for LIST, DISPLAY, etc. SPRINT OFF Echo output to printer SRAW OFF LIST/DISPLAY without blank between fields SSCREEN ON Full-screen for APPEND, EDIT, INSERT SSTEP OFF Halt after each command for debugging STALK ON Display results on console S SALTERNATE TO filename Create .TXT file for saving SDATE TO mm/dd/yy Set current date SDEFAULT TO B: Change DBASE default disk SFORMAT TO SCREEN @ commands go to screen SFORMAT TO PRINT @ commands go to printer SFORMAT TO fmtfile @ commands come from file.FMT SHEADING TO string Changes heading in REPORT SINDEX TO filelist Attach up to 7 index files SINDEX TO Cancel index file use SMARGIN TO 0 Sets left margin <=254 * o uppercase