Contributions
Updating db Checkpoints
I am using KeywordTests. I would like to change the Data Source for my db Checkpoint. Is there a way to just change myData Source without changing the data? It seems as though you have to run everything just to make a small change. Currently the only way I am aware I can make this sort of change is to run my test (giving me the data I want) then to update my db checkpoint. Why can't I just change the Data Source?682Views0likes1CommentChanging Server Login info
I am currently trying to change the login info for my db checkpoints for a project. All of my test data is on sql2008R2. It is now time to switch my data over to SQL2012. I probably will only be doing this every four years or so. The code below seems to work with the following exception. Every time my script finishes running my string returns to its original state. Any help would be appreciated. The code came from the following link: https://community.smartbear.com/t5/TestComplete-General-Discussions/Variable-for-connection-string-or-Data-Source-Name/m-p/74699#M11809 Here is my script. function UpdateConnectionString() //Obtain a collection of the DBTable elements using the aqObject.GetProperties method. { var props = aqObject.GetProperties(DBTables); var prop; var tableName; var newConnectionString = "Provider=SQLNCLI.1;Password=csl123;Persist Security Info=True;User ID=cslinh;Initial Catalog=UM0_DemoTestComplete;Data Source=JKM\\SQL2012"; //If you use a project variable to keep the new connection string (for example, called myConnectionString), use the following line instead:. //var newConnectionString = Project.Variables.myConnectionString; while (props.HasNext()) { //Move to the next property prop = props.Next(); //Obtain the table name tableName = prop.Name; //Use the eval function to assign a new value to the table's ConnectionString property eval("DBTables." + tableName + ".ConnectionString = newConnectionString"); } }1KViews0likes2Comments