Writing Drupal 7 queries using drupals DB abstract. (Similar to an entity wrapper) Drupal (7) uses an abstact for handling DB-s. 

I'd like to write dynamic queries where i can use drupals abstract.

There's entity wrapper for entities and I'm
Looking for something similar to DB-s. 

Is there anything like that?
If by level of abstraction close to the one given by entity wrappers, you mean a module/library that would allow to write code similar to the following, no, there isn't anything like that.

$field_value = database_wrapper('table')-&gt;table_field;
database_wrapper('table')-&gt;set('table_field', $new_value)-&gt;save();


The level of abstraction that would offer, in the case of reading the database, would not be worth the code you would write to implement it, and it would just save a few method calls. In fact, $field_value = database_wrapper('table')-&gt;table_field; would be equivalent to the following Drupal 7 code.

$result = db_query("SELECT table_field FROM {table}");
foreach ($result as $record) {
  // Use $record-&gt;table_field;
}


Also for writing, the Drupal 7 code is not much complicated to require a wrapper.

db_insert('table')
  -&gt;fields(array(
    'table_field' =&gt; $new_value,
    ))
  -&gt;execute();


Real code would be more complicated than this, but a wrapper that should consider every case would be even more complicated.