根据标签名称输出 [英] Output according to Tag Name

查看:68
本文介绍了根据标签名称输出的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

你好,

大家好.

我又遇到新问题了

有四个表.

1. tblQuestion


一世. QuestionID
ii.问题


2. tblAnswerChoice


一世. AnswerChoiceID
ii. QuestionID
ii. AnswerChoice


3. tblTag


一世. TagID
ii.标签

4. tblTagQuestion


i.TagQuestionID
ii.QuestionID
iii. TagID

我有一个搜索按钮,可以搜索存储在数据库中的所有标签,并显示与该标签相关的所有问题和答案选择.

主要问题是标签存储在tblTag中,问题存储在tblQuestion中,答案选择存储在tblAnswerChoice中.

现在的问题是,我想根据标签名称显示问题和选择.我的主要要求是显示具有相同标签名称的Question和AnswerChoice.但是标签名称存储在tblTag中.
为了显示所需的输出,我必须使用所有四个表,但是如何使用.

致谢,
Deepak

Hello,

Good Moring to all.

I am again with new problem

there are four tables.

1. tblQuestion

columns
i. QuestionID
ii. Question


2. tblAnswerChoice

Columns
i. AnswerChoiceID
ii. QuestionID
ii. AnswerChoice


3. tblTag

Columns
i. TagID
ii. Tag

4. tblTagQuestion

columns
i.TagQuestionID
ii.QuestionID
iii. TagID

I have one search button which search the all tags stored in the database and show all the question and answer choices of the question related to that tag.

Main problem is that tag is stored in tblTag, Question is stored in tblQuestion and answer choices are stored in tblAnswerChoice.

now the problem is that I want to show the Question and Choices according to there Tag Name. Mainly my requirement is to show Question and AnswerChoice which are of same Tag Name. But the Tag Name is sotored in the tblTag.
To the show the desired output I have to use all the four tables but how.

Thnaks,
Deepak

推荐答案

看看 JOIN [ ^ ]语句有效.


您能用更多解释来定义您的问题吗?
Could you define your problem with more explanations?


这篇关于根据标签名称输出的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆