Hi Team,
I am creting DSN for Hive driver using C#, we are able to create using below code
- var driverKey = Microsoft.Win32.Registry.LocalMachine.CreateSubKey(ODBCINST_INI_REG_PATH + driverName);
- if (driverKey == null) throw new Exception(string.Format("ODBC Registry key for driver '{0}' does not exist", driverName));
- string driverPath = driverKey.GetValue("Driver").ToString();
- var datasourcesKey = Microsoft.Win32.Registry.LocalMachine.CreateSubKey(ODBC_INI_REG_PATH + "ODBC Data Sources");
- if (datasourcesKey == null) throw new Exception("ODBC Registry key for datasources does not exist");
- datasourcesKey.SetValue(dsnName, driverName);
- var dsnKey = Microsoft.Win32.Registry.LocalMachine.CreateSubKey(ODBC_INI_REG_PATH + dsnName);
- if (dsnKey == null) throw new Exception("ODBC Registry key for DSN was not created");
- dsnKey.SetValue("Database", database);
- dsnKey.SetValue("Description", description);
- dsnKey.SetValue("Driver", driverPath);
- dsnKey.SetValue("LastUser", Environment.UserName);
- dsnKey.SetValue("Server", server);
- dsnKey.SetValue("Database", database);
- dsnKey.SetValue("AuthMech", "3");
- dsnKey.SetValue("UID", "mapr");
- dsnKey.SetValue("PWD", "mapr");
However I want to set server side properties available in Advance options button by adding key and value.
I tried using below code
- dsnKey.SetValue("hive.vectorized.execution.enabled", "1");
- dsnKey.SetValue("hive.vectorized.execution.reduce.enabled", "1");
However, it is not working.
Please help me for the same