Difference between revisions of "DBF NDX()"

From Lianjapedia
Jump to: navigation, search
m (1 revision)
m (Text replace - "lianjaapi.h" to "lianja_api.h")
 
Line 7: Line 7:
 
==SYNOPSIS==
 
==SYNOPSIS==
 
<code lang="c">
 
<code lang="c">
#include "lianjaapi.h"
+
#include "lianja_api.h"
  
 
char *DBF_NDX(order)
 
char *DBF_NDX(order)
Line 27: Line 27:
  
 
<code lang="c">
 
<code lang="c">
#include "lianjaapi.h"
+
#include "lianja_api.h"
  
 
lianjaapi_dbf_ndx()
 
lianjaapi_dbf_ndx()

Latest revision as of 05:56, 11 April 2013

PURPOSE

Return index name

SYNONYM

api_dbf_ndx()

SYNOPSIS

#include "lianja_api.h"
 
char	*DBF_NDX(order)
 
<input parameters>
long	order;		/* Index order		*/
 
<output parameters>
none

DESCRIPTION

The DBF_NDX() function will return the index name from the currently selected table for the specified index order as a character string, if no index is active then a NULL string will be returned.

The character string is returned in lower case including the file extension

EXAMPLE

The following example returns the index name for the specified order.

#include "lianja_api.h"
 
lianjaapi_dbf_ndx()
{
    char	*indexname;
 
    if (_parinfo(1) == API_NTYPE ) {
       indexname = DBF_NDX( _parni(1) );
    } else {
       strcpy(indexname, "");
    }
 
    _retc( indexname );
}

SEE ALSO

COMMAND(), DBF_ALIAS(), DBF_DBF(), DBF_DELETED(), DBF_FETCH(), DBF_FILTER(), DBF_FMT(), DBF_INDEXKEY(), DBF_INDEXORDER(), DBF_SEEK(), DBF_SELECT(), DBF_SKIP(), DBF_USED(), FIELD_COUNT(), FIELD_LOOKUP()