DB Read - How to join tables?

Join tables in ChronoForms DB Read event.

Overview

The user encountered errors when trying to join two tables in a MySQL query within the DB Read event structure, as the event's model-column relationship was unclear.
Upgrade to ChronoForms v7 for easier relation setup and use its SQL data action to directly input custom SQL queries, ensuring to clear the site's temporary and cache folders if installation issues occur.

Answered
ChronoForms v5
He HerKle 10 Dec, 2020
Hi,
I try to read data from one table via the condition of a second table - but I cannot manage to put the mysql query into that structure of DB Read Event. Which is in such a case main table, which the related second? Whatever I tried, I got errors such as "there is no model.column in tableX".

How would a query like this one be set into work in CF?

SELECT tableA.created, tableA.title FROM tableA LEFT JOIN tableB ON tableA.id = tableB.itemid WHERE tableB.catid = 11 ORDER BY tableA.created DESC LIMIT 1;

I am somehow stuck and so thankful for any advice.
Herbert
Max_admin Max_admin 11 Dec, 2020
Answer
Hello HerKle,

You better use v7 which can be installed with v5 on the same website, the relations are easier to setup and there is a SQL data action where you can just write your own SQL code
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
He HerKle 11 Dec, 2020
Thanks Max, for your opinion, but aren't there any other possibilities than buying an entire new system - just for one single item?

Btw: The installation of CFv7 failed on https://drogenfreie-erziehung.de - any idea why? "Could'nt find installation package"
Max_admin Max_admin 12 Dec, 2020
you download and install or you do it through the joomla installer ?

v7 has better functionality and more features!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
He HerKle 12 Dec, 2020
I downloaded first and then used the joomla installer.
Max_admin Max_admin 14 Dec, 2020
try to clear your website's tmp and cache folders!
Max, ChronoForms developer
ChronoMyAdmin: Database administration within Joomla, no phpMyAdmin needed.
ChronoMails simplifies Joomla email: newsletters, logging, and custom templates.
This topic is locked and no more replies can be posted.