Installation and deployment Questions on installation, system configuration and deployment to the live server.
Version 6.x > Installation and deployment > SQL connection problem during installation View modes: 
User avatar
Member
Member
vinci - 1/16/2012 4:13:15 AM
   
SQL connection problem during installation
How to solve this problem when connect to database during installation process to shared hosting server?

Thanks in advance and appreciate all the help you all may provide.
ERROR: An error occurred: [DataConnection.ExecuteQuery]: Query: CREATE TABLE [CMS_Avatar] ( [AvatarID] [int] IDENTITY(1, 1) NOT NULL, [AvatarName] [nvarchar](200) NULL, [AvatarFileName] [nvarchar](200) NOT NULL, [AvatarFileExtension] [nvarchar](10) NOT NULL, [AvatarBinary] [varbinary](max) NULL, [AvatarType] [nvarchar](50) NOT NULL, [AvatarIsCustom] [bit] NOT NULL, [AvatarGUID] [uniqueidentifier] NOT NULL, [AvatarLastModified] [datetime] NOT NULL, [AvatarMimeType] [nvarchar](100) NOT NULL, [AvatarFileSize] [int] NOT NULL, [AvatarImageHeight] [int] NULL, [AvatarImageWidth] [int] NULL, [DefaultMaleUserAvatar] [bit] NULL, [DefaultFemaleUserAvatar] [bit] NULL, [DefaultGroupAvatar] [bit] NULL, [DefaultUserAvatar] [bit] NULL ) ON [PRIMARY] TEXTIMAGE_ON [PRIMARY] ALTER TABLE [CMS_Avatar] ADD CONSTRAINT [PK_CMS_Avatar] PRIMARY KEY NONCLUSTERED ([AvatarID]) WITH FILLFACTOR=80 ON [PRIMARY] ALTER TABLE [CMS_Avatar] ADD CONSTRAINT [DEFAULT_CMS_Avatar_DefaultFemaleUserAvatar] DEFAULT ((0)) FOR [DefaultFemaleUserAvatar] ALTER TABLE [CMS_Avatar] ADD CONSTRAINT [DEFAULT_CMS_Avatar_DefaultGroupAvatar] DEFAULT ((0)) FOR [DefaultGroupAvatar] ALTER TABLE [CMS_Avatar] ADD CONSTRAINT [DEFAULT_CMS_Avatar_DefaultMaleUserAvatar] DEFAULT ((0)) FOR [DefaultMaleUserAvatar] ALTER TABLE [CMS_Avatar] ADD CONSTRAINT [DEFAULT_CMS_Avatar_DefaultUserAvatar] DEFAULT ((0)) FOR [DefaultUserAvatar] CREATE NONCLUSTERED INDEX [IX_CMS_Avatar_AvatarGUID] ON [CMS_Avatar] ([AvatarGUID]) WITH ( FILLFACTOR = 80) ON [PRIMARY] CREATE CLUSTERED INDEX [IX_CMS_Avatar_AvatarName] ON [CMS_Avatar] ([AvatarName]) WITH ( FILLFACTOR = 80) ON [PRIMARY] CREATE NONCLUSTERED INDEX [IX_CMS_Avatar_AvatarType_AvatarIsCustom] ON [CMS_Avatar] ([AvatarType], [AvatarIsCustom]) WITH ( FILLFACTOR = 80) ON [PRIMARY] : caused exception: There is already an object named 'CMS_Avatar' in the database.

User avatar
Kentico Support
Kentico Support
kentico_radekm - 1/16/2012 7:22:29 AM
   
RE:SQL connection problem during installation
Hello.

Are you installing a new database from scratch or you used already existing DB? More details about the steps how to reproduce the issue would be much appreciated.

Isn't it possible that some objects were already created in the DB? Which option have you used when running the DB installer - create new DB or use existing DB?

Are you installing Kentico CMS on your own (dedicated) web server or on some shared hosting?

There are several options how this could happen - e.g. some connection issue and the postback was executed twice - I just tried installing to a completely empty DB and it is working just fine. Could you please try to remove the DB, create it again and run the DB installer one more time - are you using also the option to create the Kentico objects or not?

Could you please let me know what is version of SQL server that you are using?

Best Regards,
Radek Macalik


User avatar
Member
Member
vinci - 1/16/2012 8:45:52 PM
   
RE:SQL connection problem during installation
Hi,

I am currently using shared hosting server and the database is SQL Server 2005.
During installation, I used existing empty DB, also tried to delete and create new database in SQL server. Besides, I had tried checked and unchecked the box Create Kentico CMS database objects but it come with the same result.

Greatly appreciate your immediate assistance.

Thanks & Regards,
Vinci

User avatar
Member
Member
vinci - 1/16/2012 9:42:05 PM
   
RE:SQL connection problem during installation
Now with the new error after add connection string at web.config
Please assist.
SQL Connection Error:
The application could not connect to the database, please check the connection string in the web.config file and SQL server availability.

Original error:

The database version '' does not match the project version '6.0', please check your connection string.

Thanks & Regards,
Vinci

User avatar
Kentico Support
Kentico Support
kentico_radekm - 1/18/2012 1:26:05 AM
   
RE:SQL connection problem during installation
Hello.

Where the database you point your connectionString to comes from, please? Is it valid 6.0 DB? I guess you don’t have access to your SQL Server to restore some DB manually, am I correct? Or would it be possible? Maybe you could contact hosting server’s admin and ask him for that. Also, are you able to connect to SQL server using credentials you have defined in your connectionString outside of Kentico project? Thank you.

Best Regards,
Radek Macalik

User avatar
Member
Member
vinci - 2/9/2012 8:26:46 PM
   
RE:SQL connection problem during installation
Hi,

After discussed with my server hosting admin, he had create me some new DB. But during process connecting to DB, it appear some problem shown as below. May i know what is the issue for this time and how to solve it? And what is valid 6.0 DB?

Thanks in advance.
ERROR: An error occurred: [DataConnection.ExecuteQuery]: Query: CREATE VIEW [View_PageInfo_Blank] AS SELECT dbo.CMS_Tree.NodeID, dbo.CMS_Tree.NodeAliasPath, dbo.CMS_Tree.NodeName, dbo.CMS_Tree.NodeAlias, dbo.CMS_Tree.NodeClassID, dbo.CMS_Tree.NodeParentID, dbo.CMS_Tree.NodeLevel, dbo.CMS_Tree.NodeACLID, dbo.CMS_Tree.NodeSiteID, dbo.CMS_Tree.NodeGUID, dbo.CMS_Tree.NodeOrder, dbo.CMS_Document.DocumentID, dbo.CMS_Document.DocumentName, dbo.CMS_Document.DocumentNamePath, dbo.CMS_Document.DocumentPublishFrom, dbo.CMS_Document.DocumentPublishTo, dbo.CMS_Document.DocumentUrlPath, dbo.CMS_Document.DocumentCulture, dbo.CMS_Document.DocumentPageTitle, dbo.CMS_Document.DocumentPageKeyWords, dbo.CMS_Document.DocumentPageDescription, dbo.CMS_Document.DocumentMenuCaption, dbo.CMS_Document.DocumentPageTemplateID, dbo.CMS_Class.ClassName, dbo.CMS_Document.DocumentContent, dbo.CMS_Document.DocumentStylesheetID, dbo.CMS_Tree.IsSecuredNode, dbo.CMS_Document.DocumentMenuRedirectUrl, dbo.CMS_Document.DocumentMenuJavascript, dbo.CMS_Tree.NodeCacheMinutes, dbo.CMS_Tree.NodeSKUID, dbo.CMS_Tree.NodeDocType, dbo.CMS_Tree.NodeHeadTags, dbo.CMS_Tree.NodeInheritPageLevels, dbo.CMS_Document.DocumentMenuItemInactive, dbo.CMS_Document.DocumentMenuClass, dbo.CMS_Document.DocumentMenuStyle, dbo.CMS_Document.DocumentMenuItemHideInNavigation, dbo.CMS_Tree.NodeChildNodesCount, dbo.CMS_Tree.NodeBodyElementAttributes, dbo.CMS_Tree.RequiresSSL, dbo.CMS_Tree.NodeLinkedNodeID, dbo.CMS_Tree.NodeOwner, dbo.CMS_Document.DocumentCheckedOutVersionHistoryID, dbo.CMS_Document.DocumentPublishedVersionHistoryID, dbo.CMS_Document.DocumentWorkflowStepID, dbo.CMS_WorkflowStep.StepName, dbo.CMS_Document.DocumentExtensions, dbo.CMS_Document.DocumentCampaign, dbo.CMS_Tree.NodeGroupID, dbo.CMS_Document.DocumentWebParts, dbo.CMS_Document.DocumentGroupWebParts,CMS_Document.DocumentTrackConversionName,CMS_Document.DocumentConversionValue, CMS_Tree.NodeLinkedNodeSiteID, CMS_Document.DocumentWorkflowCycleGUID, CMS_Document.DocumentGUID FROM dbo.CMS_WorkflowStep INNER JOIN dbo.CMS_Document ON dbo.CMS_WorkflowStep.StepID = dbo.CMS_Document.DocumentWorkflowStepID RIGHT OUTER JOIN dbo.CMS_Tree INNER JOIN dbo.CMS_Class ON dbo.CMS_Tree.NodeClassID = dbo.CMS_Class.ClassID ON 1 = 0: caused exception: Invalid object name 'dbo.CMS_WorkflowStep'.

User avatar
Member
Member
vinci - 2/13/2012 9:40:48 PM
   
RE:SQL connection problem during installation
Can someone solve my problem please?

User avatar
Kentico Support
Kentico Support
kentico_radekm - 2/14/2012 4:00:48 AM
   
RE:SQL connection problem during installation
Hello.

By valid Kentico CMS 6.0 database I mean DB, which has been installed via Kentico Database installer. If you are not able to install DB on your hosting server from some reason, I would try this:

1. Install this DB on your local machine, where should be no restrictions.
2. Back-up this DB.
3. Move and restore it on your server.
4. Update connectionString to match this DB.

Best Regards,
Radek Macalik

User avatar
Kentico Support
Kentico Support
kentico_radekm - 2/14/2012 4:50:03 AM
   
RE:SQL connection problem during installation
Hello.

In additional to my previous message, I think that it may be related to one bug which was in our installation scripts. It is already fixed, though, so could you please try to apply the latest hotfix and fix setup files? Other workaround is possible as well. However, I would need to send those instructions by e-mail, so in this case please send us an e-mail to support@kentico.com and refer to this forum post. Thank you.

Best Regards,
Radek Macalik

User avatar
Member
Member
Jasee - 12/17/2012 5:12:51 PM
   
RE:SQL connection problem during installation
This issue still prevails in your install (12/17/2012). The download installation setup for the database is very annoying and I'm not a novice. I can't get the database to install, nor use an existing database. I hope this isn't something to look forward to if we go forward with Kentico Enterprise :(

User avatar
Kentico Support
Kentico Support
kentico_jurajo - 12/24/2012 8:31:54 AM
   
RE:SQL connection problem during installation
Hi,

I am not aware of this issue for v7 installer - could you please describe the exact steps? What hosting provider are you using?
Have you already specified the connection string in the web.config file?

Best regards,
Juraj Ondrus