Buy Now
Sign in

LOAD DATABASE RECORD

atanunu , May 20 2017, 00:53
A
atanunu 80
May 20 2017, 00:53 #368380
Sir,

Please I need load a database record; using the schoolid retrieved from a previous DB READ action. I am having issues doing this kindly assist.


Data12.SCHMSschoolnumber:{var:read_data10.SCHUAschoolid}
Data12.SCHMSRemark:1
Attachments
A.png
A.png
(116.01 KiB)
352 Downloads/Views
B.png
B.png
(24.96 KiB)
312 Downloads/Views
calculus00 1
May 20 2017, 00:54 #368381
Hello atanunu,
I'm not a Chrono professional, but after checking your new post, I think that the following links may help:
How to load record data from a database table into your form
How can I edit a record from a database table?
How can I link two DB Multi Record Loaders?
P.S: I'm just an automated service
I'm an automated service, my answers may help, but they may not be accurate.
admin 28
May 20 2017, 07:25 #368383
 1
 Answer
Hi atanunu,

As per the debug, the value is under this path:
{var:read_data10.0.Data10.SCHUAschoolid}


If you are using only 1 result then set the "data read" to return the first record only and use this:
{var:read_data10.Data10.SCHUAschoolid}


The model name must be included.

Best regards,
Max
Max
If your main question got answered then please mark the answer using the button!
Did you try the new ChronoForms7 ? if yes then please send us your comments!!
A
atanunu 80
May 20 2017, 07:33 #368386
Thanks Sir,

it worked perfectly, but how can I pass it as form data using the code below
<?php 
$this->data['Perfect'] = $this->data['Data10']['SCHUAschoolid'];
?>
GreyHead 64
May 20 2017, 13:48 #368395
Hi atanunu ,

There are several ways, one is to add a hidden input to your form with the name=Perfect

You could also look up this information after the form submits if you don't need to display it.

Bob
ChronoForms technical support
If you'd like to buy me a coffee or two, thank you very much
A
atanunu 80
May 20 2017, 14:02 #368397
Thanks Sir,

I had tried different ways to look up the information; as I need to turn it to form data {data:} with out displaying or revealing it in anyway.

Kindly assist further.
admin 28
May 20 2017, 14:18 #368399
 1
 Answer
Hi atanunu,

Why do you want to put the info in the form data ?

You can use this in a PHP function:

$this->data['perfect'] = $this->get("read_data10.0.Data10.SCHUAschoolid");

but its really unnecessary as the value can be retrieved by the syntax I posted before.

Best regards,
Max
Max
If your main question got answered then please mark the answer using the button!
Did you try the new ChronoForms7 ? if yes then please send us your comments!!
A
atanunu 80
May 20 2017, 16:36 #368401
Thanks Sir,

I had used this format in CF V5 form, i am migrating to CF V6 and CC V6 and want to maintain the same procedure as I am not yet good on the new versions.

It worked perfectly. Thanks a lot for your support