M
M
midarovrk2020-01-20 14:22:06
MySQL
midarovrk, 2020-01-20 14:22:06

How to add an additional field with a value to a certain news for DLE via mysql?

Everyone will accept.
How to add an additional field with the value ||fastnavigation|370 to a certain DLE news ?
There is a list of news id.
For example, news with id 401
Help me to correctly compose a mysql query to add this to the database for news with id 401 ||fastnavigation|370
It is necessary that a field be added to this news without touching other news, there are 15k more news on the site.
Here's what the news looks like in the database:

(90, 'Admin', '2018-05-25 00:25:27', '', '', 'comicsormanga|Comics||runame|Аквамен||number|#4', 'Aquaman', '', '', '12', 'aquaman', 0, 1, 0, 1, 0, 0, '', '', ''),
(91, 'Admin', '2018-05-25 00:25:28', '', '', 'comicsormanga|Comics||runame|Аквамен||number|#5', 'Aquaman', '', '', '12', 'aquaman', 0, 1, 0, 1, 0, 0, '', '', ''),
(92, 'Admin', '2018-05-25 00:25:29', '', '', 'comicsormanga|Comics||runame|Аквамен||number|#6', 'Aquaman', '', '', '12', 'aquaman', 0, 1, 0, 1, 0, 0, '', '', ''),

90, 91, 92 is the id of the news.
This is comicsormanga|Comics||runame|Aquaman||number|#6 and there are additional fields, that's where I need to insert ||fastnavigation|370 but only in certain news using the news id.

Answer the question

In order to leave comments, you need to log in

1 answer(s)
I
idShura, 2020-01-20
@idShura

A field (column) can only be added for the entire table, i.e. for all news.
You can read how to add a column here .

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question