Gemini Community Support Site

This Gemini community support site can be used to find solutions to product issues. You can log in using Open Id, Google Profile and even Facebook. Feel free to ask a question or browse FAQs and documentation. Product tour videos are also available along with how-to videos demonstrating key Gemini capabilities.




Upgrading DB from 2.0.5 to 3.0.4

web-app

I ran the first two DB upgrade scripts without incident, but the third script (CREATEVIEWS.sql) throws these errors:

Msg 208, Level 16, State 1, Procedure geminiissuesview, Line 3
Invalid object name 'geminiissues'.
Msg 208, Level 16, State 1, Procedure gemini
issuestatusfinal, Line 3
Invalid object name 'geminiissuestatus'.
Msg 208, Level 16, State 1, Procedure gemini
issueresolutionfinal, Line 3
Invalid object name 'geminiissueresolutions'.
Msg 208, Level 16, State 1, Procedure gemini
issuestatusunassigned, Line 3
Invalid object name 'gemini_issuestatus'.

cncallison
· 1
cncallison
Replies (7)
helpful
0
not helpful

You need to run Createtables.sql first. See our migration guide: http://www.countersoft.com/Downloads/CounterSoftGeminiv300Documentation.zip


Mark Wing
· 9108
Mark Wing
helpful
0
not helpful

I was going by the upgrade process in the installation guide, which gave a 6-step upgrade process for v2.0.x on page 10 (section 8.7).

Was there a missing step between Step 2 Execute "UPGRADE v2-2.sql" and Step 3 Execute "CREATE_VIEWS.sql" or should i run the three steps you mentioned before the upgrade steps?


cncallison
· 1
cncallison
helpful
0
not helpful

Because it is incremental upgrade you need only to run the upgrade scripts to bring you to the latest and at the end run create_views and procs.


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

Okay, I ran the two upgrade scripts to bring the database to 2.2 and then the three 3.0 create scripts.  Now I am see a problem with the first 3.0 upgrade scripts, which seems to suggest a problem with a foreign key or a constraint:

 

Msg 547, Level 16, State 0, Line 225
The INSERT statement conflicted with the FOREIGN KEY constraint "geminicomponentsprojectidfk". The conflict occurred in database "Gemini", table "dbo.geminiprojects", column 'projectid'.
The statement has been terminated.

Msg 547, Level 16, State 0, Line 318
The INSERT statement conflicted with the FOREIGN KEY constraint "geminiissuecomponentscomponentidfk". The conflict occurred in database "Gemini", table "dbo.geminicomponents", column 'componentid'.
The statement has been terminated.

Any ideas?


cncallison
· 1
cncallison
helpful
0
not helpful

You have some components that belong to a non existing project.

You have some issues that have a component that does not exist.

Fix these by either removing the components and issues or amend the insert statments


Saar Cohen
· 5000
Saar Cohen
helpful
0
not helpful

Is there an FAQ on finding orphaned objects? I'm not sure how to investigate that....


cncallison
· 1
cncallison
helpful
0
not helpful

Replace the insert into geminicomponents with:

DELETE FROM geminicomponents

SET IDENTITYINSERT geminicomponents ON

INSERT INTO geminicomponents (componentid, projectid, componentname, componentdesc, componentreadonly, created)

SELECT compid, projid, compname, compdesc, compreadonly, created FROM components where projid in (select projid from projects)

SET IDENTITYINSERT geminicomponents OFF

 

And into issue components:

DELETE FROM geminiissuecomponents

SET IDENTITYINSERT geminiissuecomponents ON

INSERT INTO geminiissuecomponents (issuecomponentid, issueid, componentid, created)

SELECT issuecomponentid, issueid, componentid, created FROM issuecomponent

WHERE issueid IN (SELECT issueid FROM geminiissues) and componentid in (select componentid from gemninicomponents)

SET IDENTITYINSERT gemini_issuecomponents OFF

 


Mark Wing
· 9108
Mark Wing