Retro video games delivered to your door every month!
Click above to get retro games delivered to your door ever month!
X-Hacker.org- SoftC Database Library v2.1 Guide - usage http://www.X-Hacker.org [<<Previous Entry] [^^Up^^] [Next Entry>>] [Menu] [About The Guide]
USAGE
   int scdcinfo(
           int handle,
           SC_NTXINFO *info );

PROTOTYPE IN
   sc_base.h

DESCRIPTION
   scdcinfo gets the filename of the index file associated with handle,
   the index key type, the maximum index key length and number of decimal
   places (numeric keys), and the length of the index key expression via the
   structure SC_NTXINFO.

NOTES
   If you are using the value returned for the index expression to
   dynamically allocate memory to hold the key expression, be sure to add one
   to the length before allocation.

EXAMPLE
   #include <stdio.h>
   #include <softc.h>
   #include <sc_base.h>

   void main()
   {
     int ntx;
     SC_NTXINFO info;

     scdinit(20,0);
     if (scdcopenx(&ntx, "TOCNAME.NTX", SC_BUFFER) == SC_SUCCESS) {
       scdcinfo(ntx,&info);
       printf("File name = %s\n",info.fname);
       printf("Maximum key length = %d\n",info.keylen);
       printf("Number of decimals = %d\n,info.keydpl);
       printf("Key expression length = %d\n",info.exprlen);
       scdcclose(ntx);
     }
     scdterm();
   }

See Also: scdcopenx

Online resources provided by: http://www.X-Hacker.org --- NG 2 HTML conversion by Dave Pearson