I can confirm that I had this error when upgrading from 4.0.3 to 4.3.3.
The cause in my case was as people mentioned in this thread the SQL in
the provider file "03.02.06.SqlDataProvider" was correct but didn't
seem to have been applied to the database.
Basically the original version of the following Stored Proc was still in the database:
"AddPortalInfo" - this original version still has EXTRA variables passed in to it namely:
@FirstName nvarchar(100),
@LastName nvarchar(100),
@Username nvarchar(100),
@Password nvarchar(50),
@Email nvarchar(100),
These need to be removed from the stored procedure - it then works fine
It is worth noting that in the Code Behind (Source Code) there is the
following comment which explains that this is a quite recent ammendment:
[cnurse] 05/10/2006 Removed unneccessary use of Administrator properties.
I have the advantage of being able to manage my database directly so I
could just edit the Stored Proc. If you rely on the DNN interface I
would suggest running just the Create Procedure part of the code
(Remembering that the top part i.e. the DROP part of the SQL is
important):
Remember to change the {databaseOwner} to the owner (if logged in as
host you may be able to remove it. Also you can probably remove
{objectQualifier} so the statement might look like: "if exists (select
* from dbo.sysobjects where id =
object_id(N'dbo.[AddPortalInfo]') and
OBJECTPROPERTY(id, N'IsProcedure') = 1)").
Relevant Code From "03.02.06.SqlDataProvider"
if exists (select * from dbo.sysobjects where id =
object_id(N'{databaseOwner}[{objectQualifier}AddPortalInfo]') and
OBJECTPROPERTY(id, N'IsProcedure') = 1)
DROP PROCEDURE {databaseOwner}[{objectQualifier}AddPortalInfo]
GO
CREATE PROCEDURE {databaseOwner}[{objectQualifier}AddPortalInfo]
@PortalName nvarchar(128),
@Currency char(3),
@ExpiryDate datetime,
@HostFee money,
@HostSpace int,
@SiteLogHistory int,
@HomeDirectory varchar(100)
as
DECLARE @PortalID int
insert into {objectQualifier}Portals (
PortalName,
ExpiryDate,
UserRegistration,
BannerAdvertising,
Currency,
HostFee,
HostSpace,
Description,
KeyWords,
SiteLogHistory,
HomeDirectory
)
values (
@PortalName,
@ExpiryDate,
0,
0,
@Currency,
@HostFee,
@HostSpace,
@PortalName,
@PortalName,
@SiteLogHistory,
@HomeDirectory
)
SET @PortalID = SCOPE_IDENTITY()
IF @HomeDirectory = ''
BEGIN
UPDATE {objectQualifier}Portals SET HomeDirectory =
'Portals/' + convert(varchar(10), @PortalID) WHERE PortalID = @PortalID
END
SELECT @PortalID
GO
|