Skip to content

Conversation

abbadon1334
Copy link
Contributor

In PHP 7.1.15 if you do something like :
SQL :
SELECT
tbl_a.col_a, tbl_a.col_b,
tbl_b.col_ba, tbl_b.col_bb
FROM tbl_a
LEFT JOIN tbl_b ON (tbl_a.ID = tbl_b.ID)

results will be nulled for all tbl_b columns

with USING this problem is solved.

it works but i don't like my conditional : strpos(array_values($val)[0],'.')

if i want a table alias, because i put it in the conf, i need to get it in my query
In PHP 7.1.15 if you do something like :
SQL : 
SELECT
tbl_a.col_a, tbl_a.col_b,
tbl_b.col_ba, tbl_b.col_bb
FROM tbl_a
LEFT JOIN tbl_b ON (tbl_a.ID = tbl_b.ID)

results will be nulled for all tbl_b columns

with USING this problem is solved.

it works but i don't like my conditional : strpos(array_values($val)[0],'.')
@Andrews54757
Copy link
Collaborator

@abbadon1334 I will investigate the USING statement.

However, the PHP count and strpos functions are very slow. I try to not use them entirely, as inserting only a couple slows things dramatically. I will try to find alternative ways to do this.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants