CF8 and SQL action

How to use results from one SQL query in another SQL query in ChronoForms 8.

Overview

The problem is that ChronoForms 8 does not directly support the same variable syntax as CF7 for passing query results between SQL actions.
Use the Read Data action with either the PHP or SQL Code behavior to write a custom query that combines both SQL statements, allowing you to use the results of the first query as input for the second.

Answered
ChronoForms v8
Co Colnem 26 Jul, 2026

Hi

How to do someone like this in CF8 ?

CF7 SQL Action sql_data1 :SELECT username FROM #__users LIMIT 2;

CF7 SQL Action sql_data2 :SELECT username, name FROM #__users WHERE username IN ('{var.join[', ']:sql_data_1.[n].username}');

Thanks

Co Colnem 27 Jul, 2026

Thanks

But how I do that in message action?

<p>{var.in:read_data_6.[n].id}/</p>

.[n]. doesn't work in CF8...

Is there a manual for CF8 like CF6?

Thanks

Co Colnem 28 Jul, 2026

Hi

I Want to have this in a HTML view (CF7 Syntax):

{var.pr:read_data6}

Array(    [0] => Array        (            [model] => Array                (                    [id] => 2010                    [label] => Billard                )

        )

    [1] => Array        (            [model] => Array                (                    [id] => 2030                    [label] => Jeux de société                )

        )

)

{var.pr:read_data6.[n].model.id}

Array(    [0] => 2010    [1] => 2030)

Is it possible with CF8? {var.in:read_data6.model.id} doesn't work.

Thanks

Max_admin Max_admin 22d ago

Hi Colnem

Unfortunately this syntax is not available in v8, you will need to use PHP code to loop over the array and get the id value of each record.

But the next update will support this: 

{var.array:read_data14.#.name}

which will do the same thing

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Max_admin Max_admin 21d ago

No problem

Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
Post a Reply