我希望从下拉菜单中为我的用户提供一个选项,以选择他们想要运行的查询,然后在单击菜单时触发查询运行。我在想类似的东西......
姓名-----地址----销售人员----完整报告--
因此,例如,如果用户从菜单中单击完整报告选项,它将触发此查询。
'SELECT DISTINCT jsfdName.baseData AS Name, jsfdAddr.baseData as Address,
jsfdZip.baseData AS Zip, jsfdCity.baseData AS City, jsfdState.baseData AS State,
jsfdEmail.baseData AS Email,jsfdPhone.baseData AS Phone, jsfdPerson.baseData AS Person,
jsfdContacted.baseData AS Contacted
FROM jos_sobipro_field_data AS jsfdName
JOIN jos_sobipro_field_data AS jsfdAddr USING(sid)
JOIN jos_sobipro_field_data AS jsfdZip USING(sid)
JOIN jos_sobipro_field_data AS jsfdCity USING(sid)
JOIN jos_sobipro_field_data AS jsfdState USING(sid)
JOIN jos_sobipro_field_data AS jsfdEmail USING(sid)
JOIN jos_sobipro_field_data AS jsfdPhone USING(sid)
JOIN jos_sobipro_field_data AS jsfdPerson USING(sid)
JOIN jos_sobipro_field_data AS jsfdContacted USING(sid)
WHERE jsfdName.fid = 36 AND jsfdAddr.fid = 37 AND jsfdZip.fid=38 AND jsfdCity.fid = 39
AND jsfdState.fid = 41 AND jsfdEmail.fid = 65 AND jsfdPhone.fid = 46 AND jsfdPerson.fid
= 66 AND jsfdContacted.fid = 63 AND sid > 900';
有任何想法吗?我也试图在一个文件中完成这一切,因为我希望它受到密码保护,以便只有用户才能访问它。谢谢你们的帮助。