mldardy -1 Light Poster

I have a hyperlink column in a datagrid that uses DataNavigateUrlFormatString to open a popup window via javascript. I am trying to get two variables from a sql to show in the query string for the popup window. I am able to pass the sessionstart date which is ={0} but the other those two variables in the javascript I am not sure how to pass. The two are school_id and program_id in the select statement below:

strsql = "select count(z.iIndividualid) as enrolled,session_id,school_id as SchoolId,program_id as ProgramId,convert(nvarchar(10),session_start_date,101) as SessionStartDate, session_class_size as SessionClassSize from dbo.cnSchoolProgramSessions cn with (nolock) left join customerproductdetail cpd on cn.session_start_date = cpd.dtdate1 left join customerproduct cp  on cpd.iproductid=cp.iproductid and cp.iSiteId = cpd.iSiteId and cpd.tiRecordStatus = cp.tiRecordStatus left join individual z on z.iIndividualId = cp.iOwnerId And z.tiRecordStatus = cp.tiRecordStatus where record_status = 1 and school_id = '" & iSchool & "' and program_id = '" & iProgram & "'   group by session_id, school_id, program_id,session_start_date,session_class_size

and the hyperlink column code in the data grid that is not working

<asp:HyperLinkColumn HeaderStyle-BorderColor="Black" DataNavigateUrlField="sessionstartdate"  HeaderStyle-BorderStyle ="Inset" ItemStyle-BorderColor = "Black" ItemStyle-BorderStyle="Inset"  DataTextField="sessionstartdate" HeaderText="Session Class Date"   DataNavigateUrlFormatString="javascript:var w=window.open('updsessiondate.aspx?sessionstartdate={0}&program=<%=strProgramID%>&school='&SchoolId&','','width=850,height=400');" />

What do I need to pass in the hyperlink column to get the proper? Hopefully this makes sense to someone