Custom mysql query for TbDetailView

How to create a custom mysql query and show it on a TbDetailView…

Pleae help…

Thanks…

here is my code

<?php

$this->widget(‘bootstrap.widgets.TbDetailView’, array(

'data' =&gt; ItemTransactions::model()-&gt;getMemberTransactions(),


'type' =&gt; 'bordered striped',


'attributes' =&gt; array(


    array(


        'name' =&gt; 'text',


        'value' =&gt;'value from query',


    ),


),

));

?>

Your solution is here, follow this wiki -

http://www.yiiframework.com/wiki/722/how-to-display-data-from-two-tables-in-tbgridview-using-dataprovider/

i need to show it on a TbDetailView not on a TbGridView.

hi

use

‘value’ =>$model->id,

i hope useful

<?php

$this->widget(‘bootstrap.widgets.TbDetailView’, array(

‘data’ => CustomQueryHere,

‘type’ => ‘bordered striped’,

‘attributes’ => array(

array(

‘name’ => ‘text’,

‘value’ =>‘value from query’,

),

),

));

?>