smacc5 accounting program crack sites
.
A:
As you can see the query you are doing is:
SELECT *
FROM `template_option`
WHERE `option_value` ='sidebar_first'
AND `name` LIKE '%sidebar%'
AND `template` = 'kentro'
As you are doing it on two tables you can try to use a JOIN like this:
SELECT *
FROM `template_option`
INNER JOIN `template_redirect`
ON `template_redirect`.`option_name` = `template_option`.`option_name`
WHERE `template_option`.`option_value` ='sidebar_first'
AND `template_redirect`.`template` = 'kentro'
AND `template_redirect`.`redirect_to` = 'home'
As you are looking for content on 2 tables, you can do it with a UNION like this:
SELECT *
FROM `template_option`
WHERE `option_value` ='sidebar_first'
AND `name` LIKE '%sidebar%'
AND `template` = 'kentro'
UNION
SELECT *
FROM `template_option`
INNER JOIN `template_redirect`
ON `template_redirect`.`option_name` = `template_option`.`option_name`
WHERE `template_option`.`option_value` ='sidebar_first'
AND `template_redirect`.`template` = 'kentro'
AND `template_redirect`.`redirect_to` = 'home'
But keep in mind that it is not always the best way to do it as it doesn't guaranty that the queries will be ordered correctly and that they will execute as expected.
If you need more info on how to query in Mysql just take a look at this.
//
// Generated by class-dump 3.5 (64 bit) (Debug version compiled Jun 9 2015 22:53:21).
//
// class-dump is Copyright (C) 1997-1998, 2000-2001, 2004 be359ba680
Related links:
Comments