| | | Senior Member
       
Group: Forum Members Last Login: Friday, March 14, 2008 Posts: 9, Visits: 26 |
| | I'm trying to set up a User Provider to connect to an existing database table. I keep getting "Invalid connection string" errors. I can't verify the connection string directly, since the syntax (based on the sample on the Central Configuration under the Datasouce field) is not the same as .NET / OLEDB, but I tried the parts and they work. User Entity properties: <properties> <property name="user_name" type="string" displayname="Full Name" purpose="name"/> <property name="user_code" type="string" displayname="Name" purpose="identifier"/> <property name="email" type="string" displayname="Email" purpose="email"/> <property name="supervisor_user_code" type="string" displayname="Supervisor" purpose="manager"/> <property name="default_company_id" type="string" displayname="Pwd" purpose="password"/> </properties>
User provider properties: <properties> <property name="user_name" type="string" displayname="Full Name" purpose="name"/> <property name="user_code" type="string" displayname="Name" purpose="identifier"/> <property name="email" type="string" displayname="Email" purpose="email"/> <property name="supervisor_user_code" type="string" displayname="Supervisor" purpose="manager"/> <property name="default_company_id" type="string" displayname="Pwd" purpose="password"/> </properties>
Datasouce: (password is not really xxx, I tested with the real one) (SQL Server 2000 Database) server=localhost;database=ePC_06_04_00_25;User ID=sa;pwd=xxx; I also tried my machine name: server=pauyoupc3;database=ePC_06_04_00_25;User Id=sa;pwd=xxx; Data Table / View system_user_id User login property user_code (this is a column in the system_user_id table) I get the error when I click "Test SQL Connection", I get the error. The Logger console shows: ! - Table Exists failed, - Invalid connection string. Please check MSDTC setting s and check if Database User settings are valid., Module - C:\WINDOWS\assembly\G AC_MSIL\Skelta.Configurations.DB\3.5.0.0__2e19164ab495b4e7\Skelta.Configurations .DB.dll, Source - at Skelta.Configurations.DB.SqlDbCore.TableExists(String ta bleName), pauyoupc3, Process - aspnet_wp, 1/18/2008 1:20:35 PM ! - Test Connection failed:-Invalid connection string. Please check MSDTC settin gs and check if Database User settings are valid., - Invalid connection string. Please check MSDTC settings and check if Database User settings are valid., Inne r Exception :Invalid connection string. Please check MSDTC settings and check if Database User settings are valid., Module - C:\WINDOWS\assembly\GAC_MSIL\Skelta .CentralConfigCodeBehind\3.5.0.0__0b81c60a2e4cd174\Skelta.CentralConfigCodeBehin d.dll, Source - at Skelta.Configurations.DB.SqlDbCore.TableExists(String tabl eName) at Skelta.CentralConfigCodeBehind.CreateRepository.CreateConnectionString(Boo lean forTestConnection, String connectionstr, String buttonname) at Skelta.CentralConfigCodeBehind.CreateRepository.btnTestForms_ServerClick(O bject sender, EventArgs e), pauyoupc3, Process - aspnet_wp, 1/18/2008 1:20:35 PM |
| | | | Supreme Being
       
Group: Forum Members Last Login: Saturday, April 26, 2008 Posts: 128, Visits: 422 |
| Hi, Can you make sure the MSDTC settings are configured correctly. First verify if the "Distribute Transaction Coordinator" Service is running on both the Database Server computer and the Client computer. Go to "Administrative Tools > Services" Turn on the "Distribute Transaction Coordinator" Service if it is not running. If it is running and the client application is not on the same computer as the database server, carry out the following steps on the computer running the database server. Go to "Administrative Tools > Component Services" On the left navigation tree, go to "Component Services > Computers > My Computer" Right click on "My Computer" and select "Properties" Select "MSDTC" tab Click "Security Configuration" Make sure you check "Network DTC Access", "Allow Remote Client", "Allow Inbound/Outbound", "Enable TIP" The service will restart You may need to reboot your server if it still does not work.
On your client computer use the same procedure as above to open the "Security Configuration" setting. Then make sure you check "Network DTC Access", and "Allow Inbound/Outbound" options. Restart the service and the computer if necessary. On you SQL Server Service Manager, click the "Service" dropdown, select "Distribute Transaction Coordinator". It should also be running on your server computer.
Regards,
Moderator |
| | | | Forum Newbie
       
Group: Forum Members Last Login: Saturday, January 19, 2008 Posts: 1, Visits: 2 |
| | Pauyou, Firstly, you may try with the below connection string (uid instead of User Id) and then try the scenario. server=pauyoupc3;database=ePC_06_04_00_25;uid=sa;pwd=xxx; If that doesn't help and the same issue persists, then go for the below MSDTC check. Go to "Administrative Tools > Services" Turn on the "Distribute Transaction Coordinator" Service if it is not running. If it is running and the client application is not on the same computer as the database server, carry out the following steps on the computer running the database server.
Go to "Administrative Tools > Component Services" On the left navigation tree, go to "Component Services > Computers > My Computer" Right click on "My Computer" and select "Properties" Select "MSDTC" tab Click "Security Configuration" Make sure you check "Network DTC Access", "Allow Remote Client", "Allow Inbound/Outbound", "Enable TIP" The service will restart You may need to reboot your server if it still does not work.
On your client computer use the same procedure as above to open the "Security Configuration" setting. Then make sure you check "Network DTC Access", and "Allow Inbound/Outbound" options. Restart the service and the computer if necessary.
On you SQL Server Service Manager, click the "Service" dropdown, select "Distribute Transaction Coordinator". It should also be running on your server computer.
Thanks, Sri |
| | | | Senior Member
       
Group: Forum Members Last Login: Friday, March 14, 2008 Posts: 9, Visits: 26 |
| | I had made those DTC changes when I got BPM.NET 2007 working the first time using the Skelta List users, and I rechecked them. I tried uid instead of User Id and it still didn't work. Finally I tried to connect to a SQL Server 2005 database on another machine (the one I put the Skelta Repository on) - and that worked! I guess even the Forms/User Provider featuer does not support SQL Server 2000 (I knew BPM.NET 2007 itself required 2005. . |
| | | | Supreme Being
       
Group: Forum Members Last Login: Saturday, April 26, 2008 Posts: 128, Visits: 422 |
| Hi, BPM.NET 2007 works fine with Sql server 2000 as well as Sql server 2005.There should be some settings which might be causing an issue. Can you use the attached tool to test the connection string which you had provided. Rename the file from.txt to .exe after download.regards,
Moderator
|
| | | | Senior Member
       
Group: Forum Members Last Login: Friday, March 14, 2008 Posts: 9, Visits: 26 |
| | OK, I pasted in to Conn-1 and Conn-2: server=pauyoupc3;database=ePC_06_04_00_25;uid=sa;pwd=xxxx; Clicked all 3 Test buttons, and they all responded "Connection Success..." I also tried: Conn1: server=pauyoupc3;database=ePC_06_04_00_25;uid=sa;pwd=xxxx; (Skelta Datasource) Conn2: server=dev;database=SkeltaEval1;uid=sa;pwd=xxxx; Clicked all 3 buttons, and they all responded "Connection Success..." (To recheck, I pasted the 1st database back into Central Config / User Provider / Datasource and and clicked "Test SQL Connection" and got back "Forms test failed - Invalid connection string. Please check MSDTC settings and check if Database User settings are valid. - Check logger console for more details" (Also with the connection (same database contents as above): server=dev;database=PAUYOU060401MSS;uid=sa;pwd=xxxx; I can use Enterprise Console and logon as a user out of that database, add Queues, and assign users out of that database, so I assume the other configuration settings are correct.)
|
| | | | Supreme Being
       
Group: Forum Members Last Login: Yesterday @ 6:29 AM Posts: 105, Visits: 556 |
| Hi, Can you send the screen shot of MSDTC settings please?
Regards, Bineesh E Raghavan |
| | | | Senior Member
       
Group: Forum Members Last Login: Friday, March 14, 2008 Posts: 9, Visits: 26 |
| | | | | Supreme Being
       
Group: Forum Members Last Login: Saturday, April 26, 2008 Posts: 128, Visits: 422 |
| Hi, Thanks for the details. The settings looks perfect. The only difference from test connection tool is exception occurs when the connection is open from w3w process. Can you set the connection string correctly and try the below code from an aspx page.
using System.Transactions;SqlConnection sqlConn = new SqlConnection("server=pauyoupc3;database=ePC_06_04_00_25;uid=sa;pwd=xxxx;"); try { System.Transactions.TransactionOptions to = new System.Transactions.TransactionOptions(); to.IsolationLevel = System.Transactions.IsolationLevel.ReadCommitted; to.Timeout = TimeSpan.Zero; using (TransactionScope tscope = new TransactionScope(System.Transactions.TransactionScopeOption.Required, to)) { sqlConn.Open(); tscope.Complete(); } } catch (Exception ex) { Response.Write(ex.Message + ((ex.InnerException == null) ? "" : "\r\n \r\nInnerException:" + ex.InnerException.Message)); } finally { sqlConn.Close(); }
Moderator |
| |
|
|