update sqlc gen

This commit is contained in:
Pavel 2024-03-17 20:32:41 +03:00
parent 469ccf80e2
commit 3c3445b8fc
2 changed files with 11 additions and 11 deletions

@ -537,7 +537,7 @@ WITH Funnel AS (
Questions AS (
SELECT
q.title AS question_title,
NULL AS answer_content,
a.content AS answer_content,
CAST(COUNT(*) * 100.0 / NULLIF(q.total_answers, 0) AS INTEGER) AS percentage
FROM
answer a

@ -1631,7 +1631,7 @@ WITH Funnel AS (
Questions AS (
SELECT
q.title AS question_title,
NULL AS answer_content,
a.content AS answer_content,
CAST(COUNT(*) * 100.0 / NULLIF(q.total_answers, 0) AS INTEGER) AS percentage
FROM
answer a
@ -1685,15 +1685,15 @@ type QuestionsStatisticsParams struct {
}
type QuestionsStatisticsRow struct {
CountStartFalse int64 `db:"count_start_false" json:"count_start_false"`
CountStartTrue int64 `db:"count_start_true" json:"count_start_true"`
CountFResultWithTQuestion int64 `db:"count_f_result_with_t_question" json:"count_f_result_with_t_question"`
CountTResult int64 `db:"count_t_result" json:"count_t_result"`
ResultsTitle string `db:"results_title" json:"results_title"`
ResultsPercentage int32 `db:"results_percentage" json:"results_percentage"`
QuestionsTitle string `db:"questions_title" json:"questions_title"`
AnswerContent interface{} `db:"answer_content" json:"answer_content"`
QuestionsPercentage int32 `db:"questions_percentage" json:"questions_percentage"`
CountStartFalse int64 `db:"count_start_false" json:"count_start_false"`
CountStartTrue int64 `db:"count_start_true" json:"count_start_true"`
CountFResultWithTQuestion int64 `db:"count_f_result_with_t_question" json:"count_f_result_with_t_question"`
CountTResult int64 `db:"count_t_result" json:"count_t_result"`
ResultsTitle string `db:"results_title" json:"results_title"`
ResultsPercentage int32 `db:"results_percentage" json:"results_percentage"`
QuestionsTitle string `db:"questions_title" json:"questions_title"`
AnswerContent sql.NullString `db:"answer_content" json:"answer_content"`
QuestionsPercentage int32 `db:"questions_percentage" json:"questions_percentage"`
}
func (q *Queries) QuestionsStatistics(ctx context.Context, arg QuestionsStatisticsParams) ([]QuestionsStatisticsRow, error) {