Returns the length of the data in a compute column.
SqlADLen& ( sqlconn%, computeid%, column% )
where
The length, in bytes, of the data in a compute column. When no such column or COMPUTE clause exists, -1 is returned. When the data has a null value, 0 is returned.
'Put the command into the command buffer. cmd$ = "SELECT name FROM sysobjects" cmd$ = cmd$ " ORDER BY name" cmd$ = cmd$ " COMPUTE MAX(name)" 'Send the command to SQL Server and start execution. Result% = SqlCmd%(Sqlconn%,cmd$) Result% = SqlExec%(Sqlconn%) 'Process the results of each statement. DO UNTIL Result% = NOMOREROWS Result% = SqlNextRow%(Sqlconn%) IF Result% = NOMOREROWS THEN Exit DO ELSE IF Result = REGROW THEN PRINT "regular row returned." PRINT ELSE 'This row is the result of a COMPUTE clause. DataLength& = SqlADLen&(Sqlconn%, ComputeID%, 1) Data$ = SqlAData$(Sqlconn%, ComputeID%, 1) PRINT "The length of " Data$ " is " DataLength& "bytes." END IF LOOP
SqlAData$, SqlAltLen%, SqlAltType%, SqlGetRow%, SqlNextRow%, SqlNumAlts%