Click here to Skip to main content
15,918,041 members
Home / Discussions / Database
   

Database

 
QuestionRunning a SQL Script file using C# Pin
wasife3-Jul-07 19:25
wasife3-Jul-07 19:25 
AnswerRe: Running a SQL Script file using C# Pin
Colin Angus Mackay3-Jul-07 22:44
Colin Angus Mackay3-Jul-07 22:44 
GeneralRe: Running a SQL Script file using C# Pin
N a v a n e e t h4-Jul-07 3:33
N a v a n e e t h4-Jul-07 3:33 
GeneralRe: Running a SQL Script file using C# Pin
Colin Angus Mackay4-Jul-07 7:00
Colin Angus Mackay4-Jul-07 7:00 
GeneralRe: Running a SQL Script file using C# Pin
N a v a n e e t h4-Jul-07 18:20
N a v a n e e t h4-Jul-07 18:20 
GeneralRe: Running a SQL Script file using C# Pin
Colin Angus Mackay4-Jul-07 21:26
Colin Angus Mackay4-Jul-07 21:26 
QuestionColumn info in SQL Server 2005 Pin
I.explore.code3-Jul-07 18:39
I.explore.code3-Jul-07 18:39 
AnswerRe: Column info in SQL Server 2005 Pin
Tirthadip3-Jul-07 20:43
Tirthadip3-Jul-07 20:43 
Retrieving column names of a table

There are basically 3 approaches to this problem:

1.Use the sp_help procedure to get extended information about a
database object. By database object, we mean a table, view etc.

2.You can use the following select statement to retrieve a table’s columns:
SELECT TOP 0 * FROM table_name

3.The third approach, which I personally prefer, is using the schema object of SQL Server. For example, to retrieve the column names of Authors table, you can
use the following SELECT statement:
SELECT column_name FROM INFORMATION_SCHEMA.COLUMNS WHERE TABLE_NAME 'authors'

Which results in the following result set:

column_name<br />
----------------------------<br />
au_id<br />
au_lname<br />
au_fname<br />
phone<br />
address<br />
city<br />
state<br />
zip<br />
contract<br />
(9 row(s) affected)




Tirtha

Do not go where the path may lead, go instead where there is no path and leave a trail.

Author: Ralph Waldo Emerson (1803-82), American writer, philosopher, poet, essayist

QuestionDataTable Question using VB.NET Pin
HurricaneDan3-Jul-07 9:14
HurricaneDan3-Jul-07 9:14 
AnswerRe: DataTable Question using VB.NET Pin
DanB19835-Jul-07 1:27
DanB19835-Jul-07 1:27 
Question[Message Deleted] Pin
R_L_H3-Jul-07 2:48
R_L_H3-Jul-07 2:48 
AnswerRe: Can you access an nvachar OUT parameter? Pin
originSH3-Jul-07 3:07
originSH3-Jul-07 3:07 
General[Message Deleted] Pin
R_L_H3-Jul-07 3:24
R_L_H3-Jul-07 3:24 
GeneralRe: Can you access an nvachar OUT parameter? Pin
originSH3-Jul-07 3:38
originSH3-Jul-07 3:38 
General[Message Deleted] Pin
R_L_H3-Jul-07 3:45
R_L_H3-Jul-07 3:45 
GeneralRe: Can you access an nvachar OUT parameter? Pin
originSH3-Jul-07 3:48
originSH3-Jul-07 3:48 
General[Message Deleted] Pin
R_L_H3-Jul-07 3:27
R_L_H3-Jul-07 3:27 
GeneralRe: Can you access an nvachar OUT parameter? Pin
originSH3-Jul-07 3:39
originSH3-Jul-07 3:39 
QuestionReporting Services:Check if File Exists, problem with IIS/NTFS Permissions Pin
francorg2-Jul-07 22:59
francorg2-Jul-07 22:59 
QuestionHow to acccess the SQL database over a network Pin
ozzyrocsdbn2-Jul-07 22:41
ozzyrocsdbn2-Jul-07 22:41 
AnswerRe: How to acccess the SQL database over a network Pin
originSH2-Jul-07 23:36
originSH2-Jul-07 23:36 
AnswerRe: How to acccess the SQL database over a network Pin
ozzyrocsdbn3-Jul-07 1:11
ozzyrocsdbn3-Jul-07 1:11 
GeneralRe: How to acccess the SQL database over a network Pin
originSH3-Jul-07 1:19
originSH3-Jul-07 1:19 
QuestionHow can i embed SQL Server 2000 system???? Pin
john84vn2-Jul-07 21:29
john84vn2-Jul-07 21:29 
AnswerRe: How can i embed SQL Server 2000 system???? Pin
Ed.Poore2-Jul-07 22:28
Ed.Poore2-Jul-07 22:28 

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.