in reply to Re^2: Append JSON (from hashref)
in thread Append JSON (from hashref)
Yes.
See perldsc on how to manipulate Perl data structures.
You could either add your entry to the result directly, in your Perl code:
$tmp->[0]->{ 'inputPhrase' } = $SearchWord;
... or simply select the search phrase as another column:
SELECT RECNO, DESCRIPTION, ? as inputPhrase FROM RECORDS_TABLE WHERE RECNO LIKE ?
... $sth->execute( $SearchWord, $recno ); ...
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^4: Append JSON (from hashref)
by Anonymous Monk on Apr 06, 2017 at 13:29 UTC | |
by Corion (Patriarch) on Apr 06, 2017 at 13:32 UTC | |
by Anonymous Monk on Apr 06, 2017 at 15:36 UTC | |
by Corion (Patriarch) on Apr 07, 2017 at 06:12 UTC | |
by huck (Prior) on Apr 06, 2017 at 15:51 UTC | |
by Anonymous Monk on Apr 07, 2017 at 13:12 UTC | |
by AnomalousMonk (Archbishop) on Apr 06, 2017 at 19:41 UTC |