AnsweredAssumed Answered

Changing SIS information

Question asked by abdullah.shabbab on Jan 3, 2017

dear

how i can change the source field for specific field to anther database?

i am trying to change the source field from SIS to anther database which is in different server. i am trying the Use a Custom Script option. and i have written the following code to change the email from SIS to username in different database.

The Code

var connection = new ActiveXObject("ADODB.Connection") ;

 

 

var connectionstring="Data Source=\\**********;Initial Catalog=********;User ID=************;Password=********;Provider=SQLOLEDB";

 

 

connection.Open(connectionstring);

var rs = new ActiveXObject("ADODB.Recordset");

rs.Open("select * from View_userdata where extensionAttribute3 ='"+user_id+"'", connection);

rs.MoveFirst

while(!rs.eof)

{

   helper.logInfo("THE USERNAME sAMameATTRER GOOOD GOOOD GOOD " +rs.fields(1));

   email = rs.fields(1);

   rs.movenext;

}

helper.logInfo("THE USERNAME sAMameATTRER fffffffffffffffff ");

rs.close;

connection.close;

Outcomes