Click here to Skip to main content
15,921,841 members
Home / Discussions / Database
   

Database

 
Questionto display date in repeater in MM.dd.yyyy format Pin
yogita charhate14-Nov-06 2:02
yogita charhate14-Nov-06 2:02 
AnswerRe: to display date in repeater in MM.dd.yyyy format Pin
Elina Blank14-Nov-06 2:32
sitebuilderElina Blank14-Nov-06 2:32 
GeneralRe: to display date in repeater in MM.dd.yyyy format Pin
Iridania14-Nov-06 7:56
Iridania14-Nov-06 7:56 
GeneralRe: to display date in repeater in MM.dd.yyyy format Pin
Elina Blank14-Nov-06 8:06
sitebuilderElina Blank14-Nov-06 8:06 
AnswerRe: to display date in repeater in MM.dd.yyyy format Pin
Eric Dahlvang14-Nov-06 3:18
Eric Dahlvang14-Nov-06 3:18 
Questionquery problem Pin
Saira Tanwir13-Nov-06 20:48
Saira Tanwir13-Nov-06 20:48 
AnswerRe: query problem Pin
coolestCoder13-Nov-06 21:07
coolestCoder13-Nov-06 21:07 
GeneralRe: query problem Pin
Saira Tanwir13-Nov-06 21:17
Saira Tanwir13-Nov-06 21:17 
ok!

the query i'm using top retrieve the primary keys of all tables in the database is

sql="SELECT name FROM sysobjects WHERE xtype='PK'";

when i execute this query through
DataTable pkey=new DataTable();<br />
        sql="SELECT name FROM sysobjects WHERE xtype='PK'";<br />
	cmd=new SqlCommand(sql, conn);<br />
	reader=cmd.ExecuteReader();<br />
	pkey=reader.GetSchemaTable();<br />
	reader.Close();<br />
	if(pkey!=null)<br />
	{<br />
	dataGrid2.DataSource=pkey;<br />
	}


the output i get is always the same i.e. always only one column name is returned with its attributes and the column name is always 'name'.

i've also tried the following queries:

sql="SELECT name FROM sysobjects WHERE xtype='PK' AND name='name'";

the result is still the same

Saira
GeneralRe: query problem Pin
Saira Tanwir13-Nov-06 21:26
Saira Tanwir13-Nov-06 21:26 
GeneralRe: query problem Pin
coolestCoder13-Nov-06 22:37
coolestCoder13-Nov-06 22:37 
GeneralRe: query problem Pin
Colin Angus Mackay13-Nov-06 22:53
Colin Angus Mackay13-Nov-06 22:53 
AnswerRe: query problem Pin
Parwej Ahamad14-Nov-06 5:21
professionalParwej Ahamad14-Nov-06 5:21 
Questionread from ps2 port Pin
M.Nouri13-Nov-06 19:44
M.Nouri13-Nov-06 19:44 
AnswerRe: read from ps2 port Pin
Frank Kerrigan13-Nov-06 23:36
Frank Kerrigan13-Nov-06 23:36 
AnswerRe: read from ps2 port Pin
Christian Graus14-Nov-06 18:40
protectorChristian Graus14-Nov-06 18:40 
GeneralRe: read from ps2 port Pin
Frank Kerrigan15-Nov-06 3:19
Frank Kerrigan15-Nov-06 3:19 
QuestionAbout Swapping in Sql Pin
prameelapydi13-Nov-06 17:45
prameelapydi13-Nov-06 17:45 
AnswerRe: About Swapping in Sql Pin
Colin Angus Mackay13-Nov-06 22:54
Colin Angus Mackay13-Nov-06 22:54 
GeneralRe: About Swapping in Sql Pin
Frank Kerrigan13-Nov-06 23:40
Frank Kerrigan13-Nov-06 23:40 
GeneralRe: About Swapping in Sql Pin
prameelapydi15-Nov-06 17:55
prameelapydi15-Nov-06 17:55 
Questionhow can i make data visualisation? [modified] Pin
MAYKY13-Nov-06 8:03
MAYKY13-Nov-06 8:03 
AnswerRe: how can i make data visualisation? Pin
Frank Kerrigan13-Nov-06 23:51
Frank Kerrigan13-Nov-06 23:51 
Questionupdating a database using dataAdapter update Pin
steve_rm13-Nov-06 6:43
steve_rm13-Nov-06 6:43 
AnswerRe: updating a database using dataAdapter update Pin
Frank Kerrigan13-Nov-06 23:56
Frank Kerrigan13-Nov-06 23:56 
QuestionHow to Add(sum) from two Different tables Pin
Iridania13-Nov-06 4:40
Iridania13-Nov-06 4:40 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.