John Valentine
New Member Posts:17
|
03/05/2008 6:02 PM |
|
Hey Peter,
Update:
I got my Upgrade sort of working. It turns out that the SQL script that runs on install doesn't really work on my database server. I was able to pine through all the scripts running them individually in the SQL module in the host menu. Some of them keep failing on the keyword MAX. I fixed it by changing it to 4000 since they were NVarChar fields. This caused the DMX_LongTexts Table creation query to fail. I ran the create statements manually from your 04.00.00.SqlDataProvider script and was able (with the changes above) to get the module rendering.
Now the module renders but I see icons but not text in any instance of the module. Also, I think I am going to have to change the menu colors to match our site - but I am sure thats a different story. So why can't I see any text?
I ran the scripts from the admin menu, but the rename to .resources and the rename from .resources back to whatever document types they were failed on each and every file. Thats about all the info I have right now. Please let me know if there is anything else you need.
TIA,
John Valentine |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
03/06/2008 12:03 AM |
|
John, Are you running on SQL 2000 by any chance? Peter |
|
|
|
|
John Valentine
New Member Posts:17
|
03/06/2008 3:21 PM |
|
As a matter of a fact we are. |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
03/08/2008 11:11 AM |
|
John,
So there's your answer. As you'll notice in the system requirements for DMX 4 SQL 2005/Express is expected.
Peter |
|
|
|
|
John Valentine
New Member Posts:17
|
03/10/2008 2:50 PM |
|
So where do we go from here? Can the module be made to support SQL Server 2000 or do we have to upgrade to SQL Server 2005? We can't run our corporate intranet on an Express database, its simply too large.
And what of the text? Is there something that can be done to recover the text in the new module?
Thanks! |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
03/10/2008 8:31 PM |
|
Hi John,
Your first problem is that you have a failed install. This means it's hard to tell what got installed and what not. If an installation does not complete you have to find a way to roll back. DNN does not have something for that out-of-the-box. I know there are modules out there to help making backups so you can do that quickly before installing a module, but that is before. We're now in after. So if you can roll-back, please do. If not we have to pick apart what got installed and what not.
Then after all this is sorted we can concentrate on trying to engineer it in a way to run on SQL 2000. You could try do a search and replace on 'NVARCHAR(MAX)' and replace it with 'NTEXT' in all the SQL scripts. That should get you there, IMO.
Peter
|
|
|
|
|
John Valentine
New Member Posts:17
|
03/10/2008 10:04 PM |
|
Yeah, at this point, I don't have a rollback option.
Actually, I did that search already and replaced the MAX with the value 4000. That way I don’t have to change data types in the database. It also leaves me with the ability to upgrade your product later (assuming we do eventually upgrade to SQL Server 2005).
Unfortunately, I just don’t know where the text has gone. The tables still contain the Original File names and their complete descriptions, they just aren't displayed in any module instances. I get the icons, but no text.
Thanks!
|
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
03/11/2008 10:35 PM |
|
Hi John,
You need to run the DMX 3 to 4 upgrade script from within the module (Run Scripts) to migrate the data from the original location (DMX_Entries.Description) to the DMX 4 location (DMX_ShortTexts.Text). Can you confirm you ran this script and can you verify the arrival of the data in the DMX_ShortTexts table?
Peter |
|
|
|
|
John Valentine
New Member Posts:17
|
03/12/2008 3:18 PM |
|
Hey Peter,
I did run all the scripts in order on the Run Scripts page. The "Root Script" throws the following error:
System.Data.SqlClient.SqlException: Must declare the variable '@PortalID'.
at System.Data.SqlClient.SqlConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.SqlInternalConnection.OnError(SqlException exception, Boolean breakConnection)
at System.Data.SqlClient.TdsParser.ThrowExceptionAndWarning(TdsParserStateObject stateObj)
at System.Data.SqlClient.TdsParser.Run(RunBehavior runBehavior, SqlCommand cmdHandler, SqlDataReader dataStream, BulkCopySimpleResultSet bulkCopyHandler, TdsParserStateObject stateObj)
at System.Data.SqlClient.SqlCommand.RunExecuteNonQueryTds(String methodName, Boolean async)
at System.Data.SqlClient.SqlCommand.InternalExecuteNonQuery(DbAsyncResult result, String methodName, Boolean sendToPipe)
at System.Data.SqlClient.SqlCommand.ExecuteNonQuery()
at Bring2mind.DNN.Modules.DMX.Data.SqlDataProvider.ᜁ(String A_0)
at Bring2mind.DNN.Modules.DMX.Data.SqlDataProvider.ExecuteScript(String Script)
on this statement:
UPDATE {databaseOwner}{objectQualifier}ModuleSettings SET
[SettingValue]=CAST(@NewID AS NVARCHAR(10))
WHERE
[SettingName]='RootId'
AND
[SettingValue]='0'
AND
[ModuleId]=(SELECT m.[ModuleId] FROM {databaseOwner}{objectQualifier}Modules m
INNER JOIN {databaseOwner}{objectQualifier}ModuleDefinitions md ON m.ModuleDefId=md.ModuleDefId
INNER JOIN {databaseOwner}{objectQualifier}DesktopModules dm ON md.DesktopModuleId=dm.DesktopModuleId
INNER JOIN {databaseOwner}{objectQualifier}TabModules tm ON m.ModuleId=tm.ModuleId
INNER JOIN {databaseOwner}{objectQualifier}Tabs t ON tm.TabID=t.TabID
WHERE dm.FolderName='Bring2mind\DMX'
AND t.PortalID=@PortalID
)
COMMIT
All the rest of the "upgrade" scripts seem to run ok, but the two .resources conversion scripts throw output errors stating that they were unable to convert the files.
Kind Regards,
John |
|
|
|
|
John Valentine
New Member Posts:17
|
03/12/2008 3:22 PM |
|
Oh, and you were correct in assessing that the DMX_ShortTexts table is empty.
Thanks again!
John |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
03/12/2008 9:09 PM |
|
Hi John,
Looks like it was a token replacement error in the script. I have no clue why this happens as I double check the tokens. My guess is that it could be a text file encoding issue. In any case in 04.02.01 that will be made more robust even I believe and these errors should be a thing of the past.
For your situation: you needed to run ONLY the upgrade scripts. Those scripts are there for various reasons and one of them is upgrading a DMX 3 installation. Do NOT run any script unless you are sure that that is what you need to do. There is only ONE script for upgrading. After that script the DMX_Shorttexts should be populated.
Peter |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
03/12/2008 9:10 PM |
|
Note that if you've hacked your installation to work under SQL 2000, then of course you'll need to hand work the scripts yourself (DesktopModules/Bring2mind/DMX/Admin/Scripts)
Peter |
|
|
|
|
John Valentine
New Member Posts:17
|
03/12/2008 9:33 PM |
|
Hey Peter,
I got it! Thanks for pointing me in the right direction. I "downgraded" the scripts and ran them logged in as host - we are golden now!
Thank you for all your help, this was a big deal and you really helped me out here. I was actually looking at the cost of purchasing a new SQL Server (2005) and presenting that to the powers that be.
This saved us thousands - and we can now wait for SQL Server 2008 rollouts like we initially planned.
Cheers!
John |
|
|
|
|
Jack
New Member Posts:3
|
04/07/2008 10:37 PM |
|
Hi John,
I'm not a good sql guy. But do you think you can shed some light on what's been modified in the scripts? I am hoping to get it to work on SQL 2000.
Thanks! |
|
|
|
|
John Valentine
New Member Posts:17
|
04/07/2008 10:51 PM |
|
Basically, you can't use the word MAX, you have to actually type in the max size instead. in this case it was 4000.
Hope that helps!
John |
|
|
|
|
Jack
New Member Posts:3
|
04/08/2008 12:09 AM |
|
Thanks John. Just wanted to confirm it's the Install.04.00.00.SqlDataProvider file which needs updated?
This is so strange. I found a total of 3 strings containing "MAX". However, the third one is shown as:
WHERE
[LastVersionId] = @LastVersionId
AND e.Version=(SELECT MAX(Version) FROM {databaseOwner}{objectQualifier}DMX_Entries WHERE LastVersionId=e.LastVersionId AND IsApproved=1)
I assume I should leave this one alone?
I wonder why other issues we may encounter. I wonder why they wouldn't support SQL 2000. Thanks! |
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
04/08/2008 9:55 PM |
|
Jack,
Leave that MAX there. It only concerns the NVARCHAR(MAX) items. They should be replaced with NTEXT.
Peter |
|
|
|
|
John Valentine
New Member Posts:17
|
04/08/2008 10:55 PM |
|
Yes, I agree with Peter leave that one alone. The MAX function is fine; it’s the use of MAX as a keyword for a field precision argument that SQL 2000 cannot parse. 2000 expects a number as a precision argument so it fails to parse the declaration of that variable. One other thing to note would be that if you so chose, you could keep it as NVARCHAR(4000) instead of changing the datatype as Peter recommends. Either way it will work fine for you. Peter would know best in this instance since he is the developer so I would defer to him on that. I chose to go the other way because NTEXT fields are unicode text fields that can hold 1073741823 characters (thats 2 GB of storage space folks!) each, are treated differently by SQL Server for searching, parsing, and encoding; therefore, I chose to let it remain NVARCHAR. That said, I still defer to Peter's expertise!
Cheers!
|
|
|
|
|
Peter Donker
Veteran Member Posts:4536
|
04/12/2008 12:01 AM |
|
I think either way is possible. It's currently only used for the remarks field of a document. Peter |
|
|
|
|
John Valentine
New Member Posts:17
|
04/14/2008 4:18 PM |
|
Posted By Peter Donker on 04/12/2008 00:01:12
I think either way is possible. It's currently only used for the remarks field of a document.
Peter
There you have it Jack, it looks like you can do it either way.
Cheers! |
|
|
|
|