Morning all, how are you ?

I've a new error to contend with, but for the first time I actually have a theory (rough guess really) as to why it may be happening.

This post is essentially for clarification and knowledge.

I have a "Save" button in an ASP page, that when selected should update a table in a database and save the information added. However, I keep getting this error:

Microsoft OLE DB Provider for SQL Server (0x80040E14)
Unclosed quotation mark after the character string ',4'.
/admin/stores/index.asp, line 401.

Here is the code / line that is being referenced:

Sub UpdateStoreDetailsRow()
sSQL = "EXEC storedprocedure_one " & iStoreID & ",'" & sOpensMonday & "'" &_
",'" & sClosesMonday & "'" &_
",'" & sOpensTuesday & "'" &_
",'" & sClosesTuesday & "'" &_
",'" & sOpensWednesday & "'" &_
",'" & sClosesWednesday & "'" &_
",'" & sOpensThursday & "'" &_
",'" & sClosesThursday & "'" &_
",'" & sOpensFriday & "'" &_
",'" & sClosesFriday & "'" &_
",'" & sOpensSaturday & "'" &_
",'" & sClosesSaturday & "'" &_
",'" & sOpensSunday & "'" &_
",'" & sClosesSunday & "'" &_
",'" & sTelNumber & "'" &_
",'" & sFaxNumber & "'" &_
",'" & sEmailAddress & "'" &_
",'" & sSocialProfileAddress & "'" &_
",'" & sPostalAddress & "'" &_
"," & iWinID & "'"&_
","& iFloorID
oDB.execute(sSQL) (line 401)
End Sub

However (heres my guess) the "storedprocedure_one" (see below) does not have any reference to "iFloorID", and so, when the Procedures is running through what it needs to update, it arrives to the end and has no idea of "iFloorID" it will go crazy and error?

ALTER PROCEDURE [dbo].[spstoredprocedure_one]
@iStoreID DECIMAL
,@sOpensMonday VARCHAR(8)
,@sClosesMonday VARCHAR(8)
,@sOpensTuesday VARCHAR(8)
,@sClosesTuesday VARCHAR(8)
,@sOpensWednesday VARCHAR(8)
,@sClosesWednesday VARCHAR(8)
,@sOpensThursday VARCHAR(8)
,@sClosesThursday VARCHAR(8)
,@sOpensFriday VARCHAR(8)
,@sClosesFriday VARCHAR(8)
,@sOpensSaturday VARCHAR(8)
,@sClosesSaturday VARCHAR(8)
,@sOpensSunday VARCHAR(8)
,@sClosesSunday VARCHAR(8)
,@sTelNumber VARCHAR(50)
,@sFaxNumber VARCHAR(50)
,@sEmailAddress VARCHAR(250)
,@sSocialProfileAddress VARCHAR(250)
,@sPostalAddress VARCHAR(500)
,@iWindowID DECIMAL
AS
BEGIN
SET NOCOUNT ON

IF EXISTS (SELECT fk_storeID FROM tblname_one WHERE fk_storeID = @iStoreID)
BEGIN
UPDATE tbname_one
SET
OpensMonday = @sOpensMonday
,ClosesMonday = @sClosesMonday
,OpensTuesday = @sOpensTuesday
,ClosesTuesday = @sClosesTuesday
,OpensWednesday = @sOpensWednesday
,ClosesWednesday = @sClosesWednesday
,OpensThursday = @sOpensThursday
,ClosesThursday = @sClosesThursday
,OpensFriday = @sOpensFriday
,ClosesFriday = @sClosesFriday
,OpensSaturday = @sOpensSaturday
,ClosesSaturday = @sClosesSaturday
,OpensSunday = @sOpensSunday
,ClosesSunday = @sClosesSunday
,TelNumber = @sTelNumber
,FaxNumber = @sFaxNumber
,EmailAddress = @sEmailAddress
,SocialProfileAddress = @sSocialProfileAddress
,PostalAddress = @sPostalAddress
,fk_windowID = @iWindowID
WHERE
fk_StoreID = @iStoreID

END
ELSE
BEGIN
INSERT INTO tblname_one (
fk_StoreID
,OpensMonday
,ClosesMonday
,OpensTuesday
,ClosesTuesday
,OpensWednesday
,ClosesWednesday
,OpensThursday
,ClosesThursday
,OpensFriday
,ClosesFriday
,OpensSaturday
,ClosesSaturday
,OpensSunday
,ClosesSunday
,TelNumber
,FaxNumber
,EmailAddress
,SocialProfileAddress
,PostalAddress
,fk_windowID
)
VALUES (
@iStoreID
,@sOpensMonday
,@sClosesMonday
,@sOpensTuesday
,@sClosesTuesday
,@sOpensWednesday
,@sClosesWednesday
,@sOpensThursday
,@sClosesThursday
,@sOpensFriday
,@sClosesFriday
,@sOpensSaturday
,@sClosesSaturday
,@sOpensSunday
,@sClosesSunday
,@sTelNumber
,@sFaxNumber
,@sEmailAddress
,@sSocialProfileAddress
,@sPostalAddress
,@iWindowID
)
END
END

Reading that back it seems to make sense, but I am a newbie and apologise if this is common sense to the more knowledgeable coders and DB experts.

Kind regards
MG