This topic is locked

How to print Searchpanel Lookup parameter in Cross tab report

12/6/2022 11:08:35 AM
PHPRunner General questions
J
jackwood author

I need to Print Searchpanel parameter from Lookup Data in Cross tab report.
EX:
if I Filter the Date From Date October to November 2002 and Filter Lookup from another Table Sites. In The cross tab List will Echo show the Search parameter From Date A to Date B and Sites = 'AMERICA'.

I've insert the snippet :
global $strTableName;
$srchObj = SearchClause::getSearchObject($strTableName);
$fields = $srchObj->getSearchFields();
if(count($fields))
echo "Search was completed."."
";
foreach ($fields as $field=>$value ) {
echo $field.": " .$srchObj->getSearchOption($field);
if ($srchObj->getSearchOption($field)=="Between") {
echo " AND ".$srchObj->getSecondFieldValue($field);
}
echo " ".$srchObj->getFieldValue($field);
echo "
";
}

it shows only ID, not Site Name from Lookup Data.

img alt

kindly please advise and help me

dageciDevClub member 12/7/2022

Hello,
simply get the data from the database with Database API: Select()

https://xlinesoft.com/phprunner/docs/db_select.htm