G
G
goandkill2016-06-07 17:20:48
MySQL
goandkill, 2016-06-07 17:20:48

How to find out the number of characters on a website page?

Hello!
I heard that there is a resource for translators that determines the number of characters of the text on the site.
It didn't work, please help.

Answer the question

In order to leave comments, you need to log in

6 answer(s)
A
Artem Klimenko, 2015-10-04
@MIsternik

SELECT t.*
FROM __test t
LEFT JOIN __test t2 ON t.Content_id = t2.Content_id AND t2.Tag_id = 'bb'
WHERE t.Tag_id = 'aa' AND t2.Tag_id is NULL

if there are primary keys, then t.id = t2.id

T
Therapyx, 2015-10-04
@Therapyx

It’s not at all clear why you don’t use keys) in any case, the only option here is
In your case, you will get 2 lines... Just where 2 times "aa". These are id 1 and id 2.
Otherwise, change the structure, read about database normalization
club.shelek.ru/viewart.php?id=311

M
mletov, 2015-11-09
@mletov

SELECT Content_id 
FROM table
WHERE t.Tag_id = 'aa'
EXCEPT 
SELECT Content_id 
FROM table
WHERE t.Tag_id = 'bb'

Oops, sorry, I missed that this is MySql, it does not support EXCEPT
Then so
SELECT Content_id 
FROM table AS t
WHERE t.Tag_id = 'aa'
AND t.Tag_id NOT IN
( 
    SELECT Content_id 
    FROM table
    WHERE t.Tag_id = 'bb'
)

A
andwin, 2016-06-07
@romanbel

Посчитать

D
devian3000, 2016-06-07
@devian3000

Пишем коротенький скрипт и всё. Можно уложиться в 10 строк.

Сергей Горячев, 2016-06-15
@SergeGoryachev

Имхо, это слух...
Я как представлю... Это надо выкачать сайт, спарсить текст, вычистить всякое говно...
Если ничего не парсить, а просто посчитать знаки исходного кода, то задача, конечно, упрощается, но ценность этой информации стремится к 0.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question