Syntax error (missing operator) in query expression 'Site_Info.Location_ID='.
02-27-09, 03:33 PM
New Member
Join Date: Feb 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Syntax error (missing operator) in query expression 'Site_Info.Location_ID='.
I am hoping someone has seen this before. The query I have on my page works fine. When I submit the form which simply updates a table I get the error that the query is broke. I have a text box that I use to hold the variable and after I submit the page it is blank which would explain the error. I do not know why after I submit the page the field is blank.. HELP........
03-01-09, 08:51 PM
Newbie Coder
Join Date: Sep 2008
Location: Ohio
Posts: 35
Thanks: 0
Thanked 0 Times in 0 Posts
Syntax error (missing operator) in query expression 'Site_Info.Location_ID='
This can be a number of causes, can you provide some code and I'll see if I can help you out?
03-02-09, 09:54 AM
New Member
Join Date: Feb 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
I used to pass the information through using a link in the previous page. I changed to a query with a single variable and that is when I broke it.
Last edited by Yeroon; 03-02-09 at 10:44 AM .
Reason: Code tags
03-02-09, 09:56 AM
New Member
Join Date: Feb 2009
Posts: 3
Thanks: 0
Thanked 0 Times in 0 Posts
Here is the query.
Code:
sql = "SELECT Site_Info.Dsply_Form, Site_Info.Mod_Flag, Site_Info.Hub_ID, Site_Info.Man_Entry, Site_Info.Location_ID1, Site_Info.Network_ID, Site_Info.Internet_Service, Site_Info.Location_ID, Site_Info.Bill_Grp, Site_Info.One_Net, Site_Info.Cost_Center, Site_Info.Comp_Code, Site_Info.GroupName, Site_Info.Name, Site_Info.Address, Site_Info.City, Site_Info.State, Site_Info.Zip, Site_Info.Contact, Site_Info.Contact_Phone, Site_Info.RemoteTech_ID, Site_Info.Afterhours_Contact, Site_Info.Afterhours_Phone, Site_Info.Contact_Hours, System_Info.Name, System_Info.Sold_To, System_Info.System, System_Info.System_Number, System_Info.Notes, System_Info.Directions, System_Info.MID_No, System_Info.SID_No, System_Info.Maint_Contract_Exp, System_Info.Cisco_Port_No, System_Info.INADS, System_Info.Port_Network_No, System_Info.DID_Ranges, System_Info.Location_Subnet, System_Info.Gateway_Model, System_Info.Gateway1_Address, System_Info.Gateway1_Serial, System_Info.Gateway2_Address, System_Info.Gateway2_Serial, System_Info.Gateway3_Address, System_Info.Gateway3_Serial, System_Info.Gateway4_Address, System_Info.Gateway4_Serial, System_Info.Server_Model, System_Info.Server_Address, System_Info.Server_Serial, System_Info.Stack_Processor, System_Info.Stack_Address, System_Info.UPS_Model, System_Info.UPS_Address, System_Info.Audix, System_Info.Audix_Address, System_Info.Audix_Dialup, System_Info.CLan1_Address, System_Info.CLan2_Address, System_Info.CLan3_Address, System_Info.CLan4_Address, System_Info.VOIP1_Address, System_Info.VOIP2_Address, System_Info.VOIP3_Address, System_Info.VOIP4_Address, System_Info.MediaProc1_Address, System_Info.MediaProc2_Address, System_Info.MediaProc3_Address, RemoteTech_Info.LastName, RemoteTech_Info.FirstName, RemoteTech_Info.work, RemoteTech_Info.cell, RemoteTech_Info.Home, RemoteTech_Info.Home_work, RemoteTech_Info.E_Mail, RemoteTech_Info.Type, Hub_Info.HubName, Hub_Info.HubDescription, Hub_Info.Type FROM (RemoteTech_Info INNER JOIN (Site_Info INNER JOIN System_Info ON Site_Info.Location_ID = System_Info.Location_ID) ON RemoteTech_Info.ID = Site_Info.RemoteTech_ID) INNER JOIN Hub_Info ON Site_Info.Hub_ID = Hub_Info.Hub_ID WHERE Site_Info.Location_ID= " & testid & " "
Last edited by Yeroon; 03-02-09 at 10:45 AM .
Reason: Code tags
03-02-09, 10:47 AM
Code Master
Join Date: Aug 2007
Location: Netherlands, Nijmegen
Posts: 850
Thanks: 2
Thanked 20 Times in 20 Posts
If the value needs to come from the hidden field called: SYSlocationid, then try this
Code:
sql = "SELECT Site_Info.Dsply_Form, Site_Info.Mod_Flag, Site_Info.Hub_ID, Site_Info.Man_Entry, Site_Info.Location_ID1, Site_Info.Network_ID, Site_Info.Internet_Service, Site_Info.Location_ID, Site_Info.Bill_Grp, Site_Info.One_Net, Site_Info.Cost_Center, Site_Info.Comp_Code, Site_Info.GroupName, Site_Info.Name, Site_Info.Address, Site_Info.City, Site_Info.State, Site_Info.Zip, Site_Info.Contact, Site_Info.Contact_Phone, Site_Info.RemoteTech_ID, Site_Info.Afterhours_Contact, Site_Info.Afterhours_Phone, Site_Info.Contact_Hours, System_Info.Name, System_Info.Sold_To, System_Info.System, System_Info.System_Number, System_Info.Notes, System_Info.Directions, System_Info.MID_No, System_Info.SID_No, System_Info.Maint_Contract_Exp, System_Info.Cisco_Port_No, System_Info.INADS, System_Info.Port_Network_No, System_Info.DID_Ranges, System_Info.Location_Subnet, System_Info.Gateway_Model, System_Info.Gateway1_Address, System_Info.Gateway1_Serial, System_Info.Gateway2_Address, System_Info.Gateway2_Serial, System_Info.Gateway3_Address, System_Info.Gateway3_Serial, System_Info.Gateway4_Address, System_Info.Gateway4_Serial, System_Info.Server_Model, System_Info.Server_Address, System_Info.Server_Serial, System_Info.Stack_Processor, System_Info.Stack_Address, System_Info.UPS_Model, System_Info.UPS_Address, System_Info.Audix, System_Info.Audix_Address, System_Info.Audix_Dialup, System_Info.CLan1_Address, System_Info.CLan2_Address, System_Info.CLan3_Address, System_Info.CLan4_Address, System_Info.VOIP1_Address, System_Info.VOIP2_Address, System_Info.VOIP3_Address, System_Info.VOIP4_Address, System_Info.MediaProc1_Address, System_Info.MediaProc2_Address, System_Info.MediaProc3_Address, RemoteTech_Info.LastName, RemoteTech_Info.FirstName, RemoteTech_Info.work, RemoteTech_Info.cell, RemoteTech_Info.Home, RemoteTech_Info.Home_work, RemoteTech_Info.E_Mail, RemoteTech_Info.Type, Hub_Info.HubName, Hub_Info.HubDescription, Hub_Info.Type FROM (RemoteTech_Info INNER JOIN (Site_Info INNER JOIN System_Info ON Site_Info.Location_ID = System_Info.Location_ID) ON RemoteTech_Info.ID = Site_Info.RemoteTech_ID) INNER JOIN Hub_Info ON Site_Info.Hub_ID = Hub_Info.Hub_ID
WHERE Site_Info.Location_ID= " & Request.Form("SYSlocationid")
If the ID is a text field instead of numeric use:
__________________
Feel free to thank people if they help you by clicking thanks at a post.
=================================
Make it idiot proof and someone will make a better idiot.
=================================
Realise the impotence of proof reading everything you publish
03-11-09, 03:51 AM
Newbie Coder
Join Date: Mar 2009
Posts: 6
Thanks: 0
Thanked 0 Times in 0 Posts
What version of asp are you using?
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
Thread Tools
Display Modes
Linear Mode
Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts
HTML code is Off