MS SQL简单表查询 [英] MS SQL simple table query

查看:72
本文介绍了MS SQL简单表查询的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述




我有一张表如下

展开 | 选择 | Wrap | 行号

解决方案

我想,有一个与empid和statusid的Foriegn关键关系。

如果我是你,我想拖动两个控件。首先是GridView,第二个是DetailsView。在GridView中,我会选择编辑命令选项并执行select命令,这样当您选择empid时,所有状态值都将显示在DetailsView中。


了解整体过程您可以在MSDN中看到此链接:

http://msdn.microsoft.com/en-us/library/ms171924.aspx


Bytes有一些关于如何使用数据库也是如此。

查看:
http://bytes.com/topic/net/insights/...e-your-program
http://bytes.com/topic/net/insights/...rogram-part-ii


您是否在尝试找出SQL查询中需要的内容时遇到问题?



-Frinny

这是sql语句

展开 | 选择 | Wrap | 行号


Hi,

I hav a table as follows

Expand|Select|Wrap|Line Numbers

解决方案

I suppose, there is a Foriegn key relationship with empid and statusid.
If I were you, i''d like to drag two controls. First, a GridView and second a DetailsView. In GridView, I''d go for edit command options and take a select command so that when you select empid, the all status values will be shown in DetailsView.

To understand the whole procedure you can see this link in MSDN:

http://msdn.microsoft.com/en-us/library/ms171924.aspx


Bytes has a quick couple of articles on how to use a database as well.
Check out:
http://bytes.com/topic/net/insights/...e-your-program
http://bytes.com/topic/net/insights/...rogram-part-ii

Are you having a problem trying to figure out what you need in your SQL query?


-Frinny


Here is the sql statement

Expand|Select|Wrap|Line Numbers


这篇关于MS SQL简单表查询的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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