Hi..
Ques : I want to force the data reader to return only schema of the data store rather than data?
I want to force the data reader
2 Answers
Know the answer? Post it. Somebody with the same question will find it here.
Know the answer? Post it. Somebody with the same question will find it here.
Answer a question in the forums and earn +20 SHARP for every answer.
See unanswered questions
DevSocialUpcoming · 3rd editionAI Agents ConferenceDec 1–3, 2026Live onlineFree to attend5days leftRegister
Satyapriya NayakRank #47 · 31.5K reputationPosted Feb 21, 2012, 4:52 PM EST
PobjDataReader = pobjCommand.ExecuteReader (CommandBehavior.SchemaOnly)
Thanks
Jignesh TrivediRank #16 · 50.3K reputationPosted Feb 21, 2012, 5:39 PM EST
try
myReader = cmd.ExecuteReader(CommandBehavior.KeyInfo)
'Retrieve column schema into a DataTable.
also referschemaTable = myReader.GetSchemaTable()
http://support.microsoft.com/kb/310108
http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqldatareader.getschematable.aspx
hope this help.