BugNET

Open source issue tracking & project management

Forums

HomeHomeDevelopment and...Development and...General Develop...General Develop...0.7 to 0.8 Upgrade Script0.7 to 0.8 Upgrade Script
Previous
 
Next
New Post
10/20/2009 6:24 PM
 

A upgrade script has been checked into SVN to start testing upgrades from BugNET 0.7 to 0.8.

Currently this is a manual process of running two sql scripts:

  1. Run the BugNet.Schema.SqlDataProvider.sql script to create all the new tables and stored procedures etc for 0.8
  2. Run the  0.7-0.8 Upgrade Script.sql script to clean up data, migrate all projects and drop old tables etc.

So far I have noticed that all projects become disabled after the migration. You can re-enable it from the admin section and this will be fixed at a later date.

This script works for me , but my installation is quite simple.  If you have time to help testing please do as it is much appreciated and helps us identify issues and prepare the release quicker.

Please note that this is purely for testing and may change in the final release.

Thanks.


Davin Dubeau

follow us on twitter facebook users group google plus
 
New Post
10/21/2009 6:42 AM
 

I have run the scripts, and these are my results:

Script 1 runs fine

Script 2 gave the following errors:
- On line 14 you use: "USE BugNETProd" which isn't the correct database name
- The other errors are:

Msg 2714, Level 16, State 6, Line 24

There is already an object named '#OldResolution' in the database.

(1 row(s) affected)

Msg 547, Level 16, State 0, Line 3

The INSERT statement conflicted with the FOREIGN KEY constraint "FK_BugNet_ProjectCustomFieldValues_BugNet_Issues". The conflict occurred in database "BugNET", table "dbo.BugNet_Issues", column 'IssueId'.

(1 row(s) affected)

Msg 8107, Level 16, State 1, Line 2

IDENTITY_INSERT is already ON for table 'BugNET.dbo.BugNet_ProjectCustomFieldValues'. Cannot perform SET operation for table 'BugNet_IssueNotifications'.

(1 row(s) affected)

Msg 8107, Level 16, State 1, Line 2

IDENTITY_INSERT is already ON for table 'BugNET.dbo.BugNet_ProjectCustomFieldValues'. Cannot perform SET operation for table 'BugNet_IssueHistory'.

(1 row(s) affected)

Msg 8107, Level 16, State 1, Line 2

IDENTITY_INSERT is already ON for table 'BugNET.dbo.BugNet_ProjectCustomFieldValues'. Cannot perform SET operation for table 'BugNet_IssueComments'.

(1 row(s) affected)

Msg 8107, Level 16, State 1, Line 2

IDENTITY_INSERT is already ON for table 'BugNET.dbo.BugNet_ProjectCustomFieldValues'. Cannot perform SET operation for table 'BugNet_IssueAttachments'.

(1 row(s) affected)

Msg 547, Level 16, State 0, Line 2

The INSERT statement conflicted with the FOREIGN KEY constraint "FK_BugNet_RelatedIssues_BugNet_Issues". The conflict occurred in database "BugNET", table "dbo.BugNet_Issues", column 'IssueId'.

(1 row(s) affected)

Msg 8107, Level 16, State 1, Line 2

IDENTITY_INSERT is already ON for table 'BugNET.dbo.BugNet_ProjectCustomFieldValues'. Cannot perform SET operation for table 'BugNet_IssueWorkReports'.

(1 row(s) affected)

Msg 8107, Level 16, State 1, Line 2

IDENTITY_INSERT is already ON for table 'BugNET.dbo.BugNet_ProjectCustomFieldValues'. Cannot perform SET operation for table 'BugNet_ProjectMailBoxes'.

(1 row(s) affected)

Msg 3701, Level 11, State 5, Line 1

Cannot drop the table 'dbo.dtproperties', because it does not exist or you do not have permission.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Permission' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Priority' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Project' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.ProjectCustomFields' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.ProjectCustomFieldType' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Resolution' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Roles' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Status' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Type' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

Msg 3726, Level 16, State 1, Line 1

Could not drop object 'dbo.Version' because it is referenced by a FOREIGN KEY constraint.

(1 row(s) affected)

(20 row(s) affected)

Database synchronization script failed

 

If you need more nfo, just ask

 
New Post
10/21/2009 8:17 AM
 

Oops forgot that use fn statement in there.  If you restore your database and change the use or remove it do you get further?

Those temp tables usually get stuck in the create state if there is an error in the script and you have to restore the database or run a drop table #OldResolutions .


Davin Dubeau

follow us on twitter facebook users group google plus
 
New Post
10/22/2009 7:42 AM
 

Script #1 run file for me after I fixed the casing errors (my database is case sensitive).

Script #2 had come casing errors as well, but here's the first major error:

(0 row(s) affected)
Msg 547, Level 16, State 0, Line 3
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_BugNet_IssueNotifications_BugNet_Issues". The conflict occurred in database "BugNetBackup8", table "dbo.BugNet_Issues", column 'IssueId'.
 

Doing a quick query:

SELECT * FROM BugNet_Issues

Tells me there is nothing in the BugNet_Issues table.

 
New Post
10/22/2009 12:27 PM
 

carlowahlstedt wrote

Script #1 run file for me after I fixed the casing errors (my database is case sensitive).

Script #2 had come casing errors as well, but here's the first major error:

(0 row(s) affected)
Msg 547, Level 16, State 0, Line 3
The INSERT statement conflicted with the FOREIGN KEY constraint "FK_BugNet_IssueNotifications_BugNet_Issues". The conflict occurred in database "BugNetBackup8", table "dbo.BugNet_Issues", column 'IssueId'.
 

Doing a quick query:

SELECT * FROM BugNet_Issues

Tells me there is nothing in the BugNet_Issues table.

Check the BugNotifications table for orphaned records with no matching Bug / Issue Id -  SELECT * FROM BugNotifications WHERE BugId NOT IN (SELECT BugId From Bug)

If that is the case then I can add in another cleanup statement to execute before data copy.


Davin Dubeau

follow us on twitter facebook users group google plus
 
Previous
 
Next
HomeHomeDevelopment and...Development and...General Develop...General Develop...0.7 to 0.8 Upgrade Script0.7 to 0.8 Upgrade Script


Forum Policy

These Discussion Forums are dedicated to the discussion of the BugNET issue tracker.

For the benefit of the community and to protect the integrity of the project, please observe the following posting guidelines:
1. No Advertising.
2. No Flaming or Trolling.
3. No Profanity, Racism, or Prejudice.
4. Site Moderators have the final word on approving/removing a thread or post or comment.
5. English language posting only, please.