#NEWLINE# def get( user , query_server = None ) : #NEWLINE# #INDENT# if ( query_server is None ) : #NEWLINE# #INDENT# query_server = get_query_server_config ( ) #NEWLINE# #UNINDENT# if ( query_server [ 'server_name' ] == 'mysql' ) : #NEWLINE# #INDENT# from librdbms.server.mysql_lib import MySQLClient #NEWLINE# return Rdbms ( MySQLClient ( query_server , user ) , MYSQL ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( query_server [ 'server_name' ] in ( 'postgresql' , 'postgresql_psycopg2' ) ) : #NEWLINE# #INDENT# from librdbms.server.postgresql_lib import PostgreSQLClient #NEWLINE# return Rdbms ( PostgreSQLClient ( query_server , user ) , POSTGRESQL ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( query_server [ 'server_name' ] in ( 'sqlite' , 'sqlite3' ) ) : #NEWLINE# #INDENT# from librdbms.server.sqlite_lib import SQLiteClient #NEWLINE# return Rdbms ( SQLiteClient ( query_server , user ) , SQLITE ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if ( query_server [ 'server_name' ] == 'oracle' ) : #NEWLINE# #INDENT# from librdbms.server.oracle_lib import OracleClient #NEWLINE# return Rdbms ( OracleClient ( query_server , user ) , ORACLE )