How to set spinner filled by SimpleCursorAdapter by value not spinner position?
I populate a spinner with data of the SQLite-DB via a SimpleCursorAdapter.
I would like to set the default of the spinner by the value, not the position.
For example "en" for "English".
Any help is appreciated.

            SQLiteDatabase myDB = null; 
        	
            myDB = this.openOrCreateDatabase(getString(R.string.settings_db_name), MODE_PRIVATE, null);
            
            Cursor languageCursor = null;	// Info: languageCursor deklarieren
                       
            if (Locale.getDefault().getLanguage().equals("de"))
            {languageCursor = myDB.rawQuery("SELECT _id, languageID, sLanguage_German AS sLanguage FROM " + "languages" + " ORDER BY sLanguage ASC" + ";", null);}        
            if (Locale.getDefault().getLanguage().equals("en"))
            {languageCursor = myDB.rawQuery("SELECT _id, languageID, sLanguage_English AS sLanguage FROM " + "languages" + " ORDER BY sLanguage ASC" + ";", null);}
            
            startManagingCursor(languageCursor);    	    
            Spinner spinner_languages = (Spinner)findViewById(R.id.spinner_languages);
            languageCursor.moveToFirst();
    	
            SimpleCursorAdapter language_spinadapter = new SimpleCursorAdapter(
    					this,
    					R.layout.spinnerlayout,
    					languageCursor,
    					new String[] { "sLanguage" },
    					new int[] {android.R.id.text1});                       
    	        
            language_spinadapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
            spinner_languages.setAdapter(language_spinadapter);
              
             //spinner_languages.setSelection(2);

How to set spinner filled by SimpleCursorAdapter by value not spinner position?
===

I populate a spinner with data of the SQLite-DB via a SimpleCursorAdapter.
I would like to set the default of the spinner by the value, not the position.
For example "en" for "English".
Any help is appreciated.

            SQLiteDatabase myDB = null; 
        	
            myDB = this.openOrCreateDatabase(getString(R.string.settings_db_name), MODE_PRIVATE, null);
            
            Cursor languageCursor = null;	// Info: languageCursor deklarieren
                       
            if (Locale.getDefault().getLanguage().equals("de"))
            {languageCursor = myDB.rawQuery("SELECT _id, languageID, sLanguage_German AS sLanguage FROM " + "languages" + " ORDER BY sLanguage ASC" + ";", null);}        
            if (Locale.getDefault().getLanguage().equals("en"))
            {languageCursor = myDB.rawQuery("SELECT _id, languageID, sLanguage_English AS sLanguage FROM " + "languages" + " ORDER BY sLanguage ASC" + ";", null);}
            
            startManagingCursor(languageCursor);    	    
            Spinner spinner_languages = (Spinner)findViewById(R.id.spinner_languages);
            languageCursor.moveToFirst();
    	
            SimpleCursorAdapter language_spinadapter = new SimpleCursorAdapter(
    					this,
    					R.layout.spinnerlayout,
    					languageCursor,
    					new String[] { "sLanguage" },
    					new int[] {android.R.id.text1});                       
    	        
            language_spinadapter.setDropDownViewResource(android.R.layout.simple_spinner_dropdown_item);
            spinner_languages.setAdapter(language_spinadapter);
              
             //spinner_languages.setSelection(2);
