|   | ![[ Previous ]](navbprev.gif)  ![[ Contents ]](navbhome.gif)  ![[ Index ]](navbhelp.gif)  ![[ Next ]](navbnext.gif)  | 
This function frees an Ns_PdRowInfo data structure.
void Ns_PdFreeRowInfo(Ns_PdRowInfo * rowInfo, int fFreeData)
If fFreeData is a non-zero value, then this function frees the data associated with the Ns_PdRowData structure (encapsulated in Ns_PdRowInfo) as well.
    /* Things italicized would be your DBMS-specific structures and 
calls. */
    /* defined in nspd.h */ 
    typedef struct Ns_PdRowData {
    int elSize;
    char *elData;
    } Ns_PdRowData;
    typedef struct Ns_PdRowInfo {
        int             numColumns;
        Ns_PdRowData   *rowData;
    }; 
    void 
    DBMSFunction (void) { 
        
        Ns_PdRowInfo   *getRowInfo, *bindRowInfo;
        if ((bindRowInfo = DBMSBindRow(state)) != NULL) {
           if ((getRowInfo = 
Ns_PdNewRowInfo(Ns_PdGetRowInfoNumColumns(bindRowInfo))) != 
NULL) {
                /* process getRowInfo */
                /* ... */
                /* free the getRowInfo structure when done */
                Ns_PdFreeRowInfo(getRowInfo, 0);
               
           }
           /* free the bindRowInfo data and structure when done */
           Ns_PdFreeRowInfo(bindRowInfo, 1);
        }
    }