home *** CD-ROM | disk | FTP | other *** search
/ Liren Large Software Subsidy 5 / 05.iso / a / a006 / 1.ddi / PASEXAM.ZIP / TBLEXIST.PAS < prev    next >
Encoding:
Pascal/Delphi Source File  |  1991-03-11  |  394 b   |  21 lines

  1. program TblExits;
  2. uses PXEngine;
  3.  
  4. const TableName = 'Table';
  5.  
  6. var   PxErr: Integer;
  7.       Exist: Boolean;
  8. begin
  9.   PX(PXInit);
  10.  
  11.   (* See if table exists *)
  12.   PxErr := PXTblExist(TableName, Exist);
  13.   if PxErr <> PxSuccess then
  14.     Writeln(PxErrMsg(PxErr))
  15.   else if Exist then
  16.          Writeln('Table exists')
  17.        else Writeln('Table does not exist');
  18.  
  19.   PX(PXExit);
  20. end.
  21.