Do we have any query to union the three different columns of three different tables through stored procedure?

|
Andrey 2021-12-17 21:53:46
Queries are exactly the same so as business logic implementation. .netcore 5.0, tried different connectors. Still the difference is at least 30Γ·. I was told it could be due to PDO low level driver that php uses as oppose to ADO.net. I realize this is not a mysql issue, but there is no group php vs .netcore hereπŸ˜„
ssssss 2021-12-17 21:55:42
Hi guys, do we have any query that can be alter the same table in different databses? If it yes could you please share those queries which will be helpfull to me
ssssss 2021-12-17 21:57:10
At a time, means in single query
svart 2021-12-17 22:51:50
ssssss 2021-12-17 21:55:42
Hi guys, do we have any query that can be alter the same table in different databses? If it yes could you please share those queries which will be helpfull to me

it is not possible but you can run two queries in parallel.

MasterZiv 2021-12-17 23:13:14
ssssss 2021-12-17 21:55:42
Hi guys, do we have any query that can be alter the same table in different databses? If it yes could you please share those queries which will be helpfull to me

Not possible

snehakshaylata 2021-12-18 08:07:48
How to integration mySql workbench to nodejs…..
tat_vam_asi 2021-12-18 10:48:58
Hi. can anyone tell me command for restoring Backup in a docker based mysql using Ubuntu 20.04
tat_vam_asi 2021-12-18 10:49:14
cli
svart 2021-12-18 12:07:18
snehakshaylata 2021-12-18 08:07:48
How to integration mySql workbench to nodejs…..

They have nothing in common, you can’t integrate them

ChildProcessError 2021-12-18 14:50:01
MySQL is started in –skip-name-resolve mode;
ChildProcessError 2021-12-18 14:50:03
you must restart it without this switch for this grant to work
ChildProcessError 2021-12-18 14:50:09
restart didnt work
ChildProcessError 2021-12-18 14:50:12
what should i do
Prati 2021-12-18 21:04:59
Hi guys
Do we have any query to union the three different columns of three different tables through stored procedure? Because as I know union is only applicable to combine the columns with same type of data. Is it possible to combine columns containing different types of data?
piterden 2021-12-18 21:05:57
Prati 2021-12-18 21:04:59
Hi guys
Do we have any query to union the three different columns of three different tables through stored procedure? Because as I know union is only applicable to combine the columns with same type of data. Is it possible to combine columns containing different types of data?

Which types exactly?

Prati 2021-12-18 21:06:50
Like one column contains Id, another contains Name
ColonelMustang 2021-12-18 21:08:48
Prati 2021-12-18 21:06:50
Like one column contains Id, another contains Name

Can you not just use 3 sub queries somehow

ColonelMustang 2021-12-18 21:09:16
Just want to understand why would you want a union of data of different types (functionally speaking)
Prati 2021-12-18 21:12:03
ColonelMustang 2021-12-18 21:09:16
Just want to understand why would you want a union of data of different types (functionally speaking)

Actually I need to union the data of three different tables and with distinct records for three columns where each column belongs to each table and I need to load this data to target

rodrigo_tc7 2021-12-18 21:14:54
You can cast an integer as string and union then
Prati 2021-12-18 21:26:33
Ok
ColonelMustang 2021-12-18 21:40:23
Prati 2021-12-18 21:12:03
Actually I need to union the data of three different tables and with distinct records for three columns where each column belongs to each table and I need to load this data to target

Why not create 3 sub queries then?

ColonelMustang 2021-12-18 21:40:34
Union adds rows, not columns
whyamsx 2021-12-19 00:41:39
Hey
I have a request:
UPDATE category
SET name = (?) , title = (?), image = (?)
WHERE id = (?)

Instead of (?) I substitute values, but sometimes they can be empty and the request is not accepted, how can I ignore this and update only the data that is not empty?

piterden 2021-12-19 00:51:51
whyamsx 2021-12-19 00:41:39
Hey
I have a request:
UPDATE category
SET name = (?) , title = (?), image = (?)
WHERE id = (?)

Instead of (?) I substitute values, but sometimes they can be empty and the request is not accepted, how can I ignore this and update only the data that is not empty?

Validate values

piterden 2021-12-19 00:52:20
whyamsx 2021-12-19 00:41:39
Hey
I have a request:
UPDATE category
SET name = (?) , title = (?), image = (?)
WHERE id = (?)

Instead of (?) I substitute values, but sometimes they can be empty and the request is not accepted, how can I ignore this and update only the data that is not empty?

MySQL doesn’t support (?)

piterden 2021-12-19 00:52:43
Use your programming language
whyamsx 2021-12-19 01:03:50
piterden 2021-12-19 00:52:43
Use your programming language

COALESCE() solved my problem)

2021-12-19 13:38:24
Hey,
How can I use mySQL to store data filled used HTML
MasterZiv 2021-12-19 13:52:57
whyamsx 2021-12-19 00:41:39
Hey
I have a request:
UPDATE category
SET name = (?) , title = (?), image = (?)
WHERE id = (?)

Instead of (?) I substitute values, but sometimes they can be empty and the request is not accepted, how can I ignore this and update only the data that is not empty?

Use bound parameters and null value indicators in the API.

This query is candidate for garbage can anyway die to its SQL injection prone

I_am_3ngineeR 2021-12-20 14:13:52
mysql_en-14982.jpg
Hello people,
I am trying to learn MySQL on my own. I got stuck about something, it is clear that I miss one easy/obvious thing.
https://www.mysqltutorial.org/mysql-subquery/
Here is the original example that I try to complicate in order to improve my learning process.

In this example, it can print full name with offices codes, that’s fine but, I want to import names from offices table to print with it.
Here is code that work for fullname, and code for the next step I tried and does not work.

Sorry for my lacking English, I do not want to make any of you guys blind πŸ˜‚

I_am_3ngineeR 2021-12-20 14:13:53
mysql_en-14983.jpg

I_am_3ngineeR 2021-12-20 14:15:05
when I mean names, sorry it’s not clear, I want to import City Names from the offices table. That’s more clear I hope πŸ™‚
MasterZiv 2021-12-20 14:25:32
I_am_3ngineeR 2021-12-20 14:13:52
Hello people,
I am trying to learn MySQL on my own. I got stuck about something, it is clear that I miss one easy/obvious thing.
https://www.mysqltutorial.org/mysql-subquery/
Here is the original example that I try to complicate in order to improve my learning process.

In this example, it can print full name with offices codes, that’s fine but, I want to import names from offices table to print with it.
Here is code that work for fullname, and code for the next step I tried and does not work.

Sorry for my lacking English, I do not want to make any of you guys blind πŸ˜‚

Subqueries are not needed for this, at all.
Forget about subqueries so far.
Use JION.

Your join in the query is incorrect, learn how to write simple join and correct it.

I_am_3ngineeR 2021-12-20 14:28:49
MasterZiv 2021-12-20 14:25:32
Subqueries are not needed for this, at all.
Forget about subqueries so far.
Use JION.

Your join in the query is incorrect, learn how to write simple join and correct it.

The example also contains the subqueries, so I also want to use subqueries too. But thanks for your suggestion, I will check the JOIN again.

|