DAL: How to Use the "$col" Function in a C Program

I tried to use the "$col" function from within a C program using the example in the DAL documentation, but it did not work. The "$col" function is supposed to return the number of columns in the selected rowset.
The example in the DAL documentation is not complete. Put the code into a DAL program string and do clsend("program text").
Published Date: Feb 18, 2012