<%@? codepage="65001">
<% Response.CharSet = "utf-8"
Response.AddHeader "Pragma","no-cache"
Response.AddHeader "Expires","0"%@?>
idx = request("idx")
sQuery = ""
sQuery = sQuery & " select * "
sQuery = sQuery & " from table where rec_idx = '" & idx & "'; "
Set RS = Server.CreateObject("ADODB.REcordSet")
RS.Open sQuery, dbconn, 1, 1
If Not(RS.EOF OR RS.BOF) Then
'json
response.write "{"
response.write """product_serial_no"":""" & RS("serial_no") & """"
response.write ",""buy_year"":""" & RS("buy_year") & """"
response.write ",""buy_month"":""" & RS("buy_month") & """"
response.write ",""buy_day"":""" & RS("bue_day") & """"
response.write "}"
End If
RS.close
Set RS = Nothing
%>
|