无法从表中选择列 [英] Unable to select colums from table

查看:76
本文介绍了无法从表中选择列的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

在下面的代码中,我无法从表carttxno中选择所有列。



SqlDataAdapter sda1 = new SqlDataAdapter(select from carttxno,con) ;



如何选择所有列或特定列。

谢谢。

In he following code I am unable to select all the columns from table carttxno.

SqlDataAdapter sda1 = new SqlDataAdapter("Select all from carttxno", con);

How to select all the columns or specific columns.
Thanks.

推荐答案

对于所有列

For all columns
SqlDataAdapter sda1 = new SqlDataAdapter("Select * from carttxno", con);





和特定列:



and for specific columns:

SqlDataAdapter sda1 = new SqlDataAdapter("Select colm1Name, col2Name from carttxno", con);


这篇关于无法从表中选择列的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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