string(2351) "SELECT DISTINCT
ranked_results.ID,
ranked_results.meta_key,
ranked_results.post_date,
ranked_results.meta_value,
ranked_results.title,
ranked_results.stock,
ranked_results.group_id
FROM (
SELECT
wp_30a7d99a36_posts.ID,
author_id.meta_key,
wp_30a7d99a36_posts.post_date,
book_year.meta_value,
books.title,
books.stock,
books.group_id,
ROW_NUMBER() OVER (
PARTITION BY books.group_id
ORDER BY
CASE WHEN books.stock > 0 THEN 0 ELSE 1 END,
wp_30a7d99a36_posts.post_date DESC
) as rn
FROM wp_30a7d99a36_posts
INNER JOIN books ON wp_30a7d99a36_posts.ID = books.id
LEFT JOIN wp_30a7d99a36_postmeta author_id
ON (author_id.post_id = wp_30a7d99a36_posts.ID AND author_id.meta_key LIKE 'acf_book_creators_%_acf_book_creator_id')
LEFT JOIN wp_30a7d99a36_postmeta book_group_id
ON (book_group_id.post_id = wp_30a7d99a36_posts.ID AND book_group_id.meta_key = 'acf_book_argo_group_id')
LEFT JOIN wp_30a7d99a36_postmeta author_role
ON (author_role.post_id = wp_30a7d99a36_posts.ID AND author_role.meta_key LIKE REPLACE(author_id.meta_key, 'id', 'role'))
LEFT JOIN wp_30a7d99a36_postmeta book_id
ON (book_id.post_id = wp_30a7d99a36_posts.ID AND book_id.meta_key = 'acf_book_argo_id')
LEFT JOIN wp_30a7d99a36_postmeta book_year
ON (book_year.post_id = wp_30a7d99a36_posts.ID AND book_year.meta_key = 'acf_book_year')
LEFT JOIN wp_30a7d99a36_term_relationships determination
ON (determination.object_id = wp_30a7d99a36_posts.ID AND determination.term_taxonomy_id = 48)
LEFT JOIN wp_30a7d99a36_postmeta thumbnail_id
ON (thumbnail_id.post_id = wp_30a7d99a36_posts.ID AND thumbnail_id.meta_key = '_thumbnail_id')
WHERE
wp_30a7d99a36_posts.post_type = 'book'
AND wp_30a7d99a36_posts.post_status IN ('publish', 'future')
AND author_id.meta_value = 2784
AND author_role.meta_value IN ('Autor', 'Ilustrace', 'Překlad')
AND books.binding <> ''
AND book_id.meta_value IN (61651,62510,159882,160895,177523,177524,189731,195201,205609,225031,225032,225033,225034,225035,247193,247195,247197)
) ranked_results
WHERE ranked_results.rn = 1
ORDER BY ranked_results.post_date DESC"
Raymond Carver was born in Clatskanie, Oregon, in 1938. His father was a saw-mill worker and his mother was a waitress and clerk. He married early and for years writing had to come second to earning a living for his young family. Despite, small-press publication, it was not until Will You Please Be Quiet Please? appeared in 1976 that his work began to reach a wider audience. This was the year in which he gave up alcohol, which had contributed to the collapse of his marriage. In 1977 he met the writer Tess Gallagher, with whom he shared the last eleven years of his life. During this prolific period he wrote three collections of stories, What We Talk About When We Talk About Love, Cathedral and Elephant. Fires, a collection of essays, poems and stories, appeared in 1985, followed by three further collections of poetry. In 1988 he completed the poetry collection A New Path to the Waterfall.