Parameters
$rows - An array of data records.
$keyNames - An array of key names.
Returns
An array of key rows with key values.
Syntax
| PHP |
|
public function CreateResultKeys($rows, $keyNames)
|
Create the keys from the result.
Example
| PHP |
// Create the keys from the result.
private static function CreateResultKeys(LJCDataManager $manager)
{
$methodName = "CreateResultKeys";
// See constructor for how to create $manager.
$rows = $manager->Load();
// Get primary key and unique key.
$keyNames = [
"ID",
"Name",
];
$resultKeys = $manager->CreateResultKeys($rows, $keyNames);
if (null == $resultKeys
|| 0 == count($resultKeys))
{
echo("{$methodName}: \$resultKeys were not created.");
}
}
|
Copyright © Lester J. Clark and Contributors.
Licensed under the MIT License.