In case you want to read/write values from/to Settings.Global, you should use the public methods | Settings.Global | API reference.
Settings.Global
Just don't exec shell command in your Android application.