home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: 10 Tools / 10-Tools.zip / DBPROC.ZIP / DBINC.H < prev    next >
C/C++ Source or Header  |  1992-05-24  |  1KB  |  40 lines

  1. #define INCL_BASE
  2. #include <os2.h>
  3. #define READONLY    0
  4. #define READWRITE    1
  5. #define UNLOCK        0
  6. #define LOCK        1
  7.  
  8. typedef struct _fldinfo
  9.     {
  10.     CHAR name[11];
  11.     CHAR type;
  12.     CHAR length;
  13.     CHAR decimal;
  14.     }FLDDATA;
  15.  
  16. typedef struct _dbreport
  17.     {
  18.     CHAR  updatey;
  19.     CHAR  updatem;
  20.     CHAR  updated;
  21.     LONG  maxrec;
  22.     SHORT reclngth;
  23.     }DBREPORT;
  24.  
  25. //function prototypes
  26. SHORT EXPENTRY AddRec     (SHORT dbhndl, CHAR FAR *recdata, LONG FAR *recnum, SHORT lockstatus) ;
  27. SHORT EXPENTRY PutRec     (SHORT dbhndl, CHAR FAR *recdata, LONG recnum) ;
  28. SHORT EXPENTRY GetRec     (SHORT dbhndl, CHAR FAR *recdata, LONG recnum) ;
  29. SHORT EXPENTRY DeleteRec (SHORT dbhndl, LONG recnum) ;
  30. SHORT EXPENTRY RecoverRec(SHORT dbhndl, LONG recnum) ;
  31. SHORT EXPENTRY LockRec     (SHORT dbhndl, LONG recnum) ;
  32. SHORT EXPENTRY UnLockRec (SHORT dbhndl, LONG recnum) ;
  33. SHORT EXPENTRY DbOpen     (CHAR FAR *file, SHORT readwrite) ;
  34. SHORT EXPENTRY DbClose     (SHORT dbhndl) ;
  35. SHORT EXPENTRY DbCreate  (CHAR FAR *file, SHORT fldcount, FLDDATA FAR *info) ;
  36. SHORT EXPENTRY DbInfo     (SHORT hndl, DBREPORT FAR *info) ;
  37. SHORT EXPENTRY GetField  (SHORT dbhndl, LONG recnum, CHAR FAR *buff, SHORT fieldnum) ;
  38. SHORT EXPENTRY PutField  (SHORT dbhndl, LONG recnum, CHAR FAR *buff, SHORT fieldnum) ;
  39. SHORT EXPENTRY FldInfo     (SHORT hndl, SHORT fldnum, FLDDATA FAR *fldinfo) ;
  40.