S
shank
Using Dreamweaver, I'm trying to update a table using a stored procedure.
I'm getting the following error. The line# reference is on the last line:
rsUpdate.Execute(). That doesn't help much, but I'm sure the problem must be
with the number fields: Royalty (money) or Ownership (float). How do I
change the precision to match the table? In this line: "@Royalty", 6,
1,8,varRoyalty, what does 6,1,8 represent. Where can I find a
crossreference? I believe 6 is datatype money, 8 is size in bytes. What is
1...?
thanks
Microsoft OLE DB Provider for SQL Server error '80004005'
The precision is invalid.
<%
set rsUpdate = Server.CreateObject("ADODB.Command")
rsUpdate.ActiveConnection = ConnString
rsUpdate.CommandText = "stp_Publisher_Update"
rsUpdate.CommandType = 4
rsUpdate.CommandTimeout = 0
rsUpdate.Prepared = true
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Title", 200,
1,255,varTitle)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Artist", 200,
1,255,varArtist)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Gender", 200,
1,1,varGender)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Genre", 200,
1,50,varGenre)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@VocalRange", 200,
1,20,varVocalRange)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@GroupLevel", 200,
1,20,varGroupLevel)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@YearReleased", 200,
1,4,varYearReleased)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Agent", 200,
1,50,varAgent)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Publisher", 200,
1,50,varPublisher)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Royalty", 6,
1,8,varRoyalty)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Owner", 200,
1,50,varOwner)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Ownership", 131,
1,9,varOwnership)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Writers", 200,
1,255,varWriters)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Comments", 200,
1,8000,varComments)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@ID", 131, 1,9,varID)
rsUpdate.Execute()
%>
I'm getting the following error. The line# reference is on the last line:
rsUpdate.Execute(). That doesn't help much, but I'm sure the problem must be
with the number fields: Royalty (money) or Ownership (float). How do I
change the precision to match the table? In this line: "@Royalty", 6,
1,8,varRoyalty, what does 6,1,8 represent. Where can I find a
crossreference? I believe 6 is datatype money, 8 is size in bytes. What is
1...?
thanks
Microsoft OLE DB Provider for SQL Server error '80004005'
The precision is invalid.
<%
set rsUpdate = Server.CreateObject("ADODB.Command")
rsUpdate.ActiveConnection = ConnString
rsUpdate.CommandText = "stp_Publisher_Update"
rsUpdate.CommandType = 4
rsUpdate.CommandTimeout = 0
rsUpdate.Prepared = true
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Title", 200,
1,255,varTitle)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Artist", 200,
1,255,varArtist)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Gender", 200,
1,1,varGender)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Genre", 200,
1,50,varGenre)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@VocalRange", 200,
1,20,varVocalRange)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@GroupLevel", 200,
1,20,varGroupLevel)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@YearReleased", 200,
1,4,varYearReleased)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Agent", 200,
1,50,varAgent)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Publisher", 200,
1,50,varPublisher)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Royalty", 6,
1,8,varRoyalty)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Owner", 200,
1,50,varOwner)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Ownership", 131,
1,9,varOwnership)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Writers", 200,
1,255,varWriters)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@Comments", 200,
1,8000,varComments)
rsUpdate.Parameters.Append rsUpdate.CreateParameter("@ID", 131, 1,9,varID)
rsUpdate.Execute()
%>