recordset as a result of a function

Results 1 to 2 of 2

Thread: recordset as a result of a function

  1. #1
    Join Date
    Dec 1969

    Default recordset as a result of a function

    Hi! <BR><BR>Hard to explain what want but it looks like this:<BR><BR>function result (recordset, query)<BR> ... do the query etc...<BR> recordset = ...<BR>end function<BR><BR>&#060;%<BR> Dim RS<BR><BR> if result(RS, "select * from tbl") then<BR> response.write (RS ("id")<BR> end if<BR>%&#062;<BR><BR>Anyone got any idea??<BR><BR><BR><BR>

  2. #2
    Pete Nelson Guest

    Default RE: recordset as a result of a function

    I use a function to create recordsets for me all the time. Here&#039s the function I use:<BR><BR>Function MakeRecordSet(byval strLocalSqlCmd) &#039 Returns a ready-to-go recordset object<BR><BR>&nbsp;&nbsp;Set MakeRecordSet = Server.CreateObject("ADODB.RecordSet")<BR>&nbsp;&n bsp;MakeRecordSet.Source = strLocalSqlCmd<BR>&nbsp;&nbsp;MakeRecordSet.Active Connection = conDB<BR>&nbsp;&nbsp;MakeRecordSet.CacheSize = 25<BR><BR>End Function<BR><BR><BR>

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts