Click here to Skip to main content
15,899,025 members
Home / Discussions / Database
   

Database

 
QuestionGetting Column Names Through Query Pin
sindhutiwari3-Nov-07 2:57
sindhutiwari3-Nov-07 2:57 
AnswerRe: Getting Column Names Through Query Pin
Muhammad Shahid Farooq3-Nov-07 5:02
professionalMuhammad Shahid Farooq3-Nov-07 5:02 
AnswerRe: Getting Column Names Through Query Pin
pmarfleet3-Nov-07 6:24
pmarfleet3-Nov-07 6:24 
AnswerRe: Getting Column Names Through Query Pin
Mitesh Darji6-Nov-07 16:59
Mitesh Darji6-Nov-07 16:59 
QuestionGetting Table names through query Pin
sindhutiwari2-Nov-07 22:56
sindhutiwari2-Nov-07 22:56 
AnswerRe: Getting Table names through query Pin
pmarfleet2-Nov-07 23:28
pmarfleet2-Nov-07 23:28 
GeneralRe: Getting Table names through query Pin
sindhutiwari2-Nov-07 23:34
sindhutiwari2-Nov-07 23:34 
AnswerRe: Getting Table names through query Pin
Muhammad Shahid Farooq3-Nov-07 5:37
professionalMuhammad Shahid Farooq3-Nov-07 5:37 
string connectionString;
OleDbConnection connection = new OleDbConnection();
OleDbDataAdapter dataAdapter;
DataTable schemaTable = new DataTable();

public Form1()
{
InitializeComponent();
}

public void openConnection()
{
try
{
connectionString = "Provider=Microsoft.Jet.OLEDB.4.0; Data Source=C:\\Test.mdb";
connection.ConnectionString = connectionString;
connection.Open();
}
catch (Exception e)
{
MessageBox.Show(e.ToString());
}
}

public void closeConnection()
{
try
{
if (connection.State != 0)
{
connection.Close();
}
}
catch (Exception e)
{
MessageBox.Show(e.ToString());
}
}

public void getTables()
{
openConnection();
schemaTable = connection.GetOleDbSchemaTable(OleDbSchemaGuid.Tables, new object[] { null, null, null, "TABLE" });
closeConnection();
}

public void fillComboBox()
{
getTables();

for (int i = 0; i < schemaTable.Rows.Count; i++ )
{
cmbColumnNames.Items.Add(schemaTable.Rows[i]["Table_Name"].ToString());
}
}

private void Form1_Load(object sender, EventArgs e)
{
fillComboBox();
}
Questiontruncate a sql table from access Pin
nicetohaveyou2-Nov-07 20:38
nicetohaveyou2-Nov-07 20:38 
AnswerRe: truncate a sql table from access Pin
pmarfleet2-Nov-07 23:34
pmarfleet2-Nov-07 23:34 
Questionhow to find the last updated row Pin
VG Ramanan2-Nov-07 19:38
VG Ramanan2-Nov-07 19:38 
AnswerRe: how to find the last updated row Pin
Imran Khan Pathan2-Nov-07 20:28
Imran Khan Pathan2-Nov-07 20:28 
QuestionDotNet Nuke Pin
sandipchandra17@gmail.com2-Nov-07 19:32
sandipchandra17@gmail.com2-Nov-07 19:32 
AnswerRe: DotNet Nuke Pin
John-ph2-Nov-07 20:54
John-ph2-Nov-07 20:54 
AnswerRe: DotNet Nuke Pin
Paul Conrad3-Nov-07 5:37
professionalPaul Conrad3-Nov-07 5:37 
QuestionDotNet Nuke Pin
sandipchandra17@gmail.com2-Nov-07 19:32
sandipchandra17@gmail.com2-Nov-07 19:32 
AnswerRe: DotNet Nuke Pin
John-ph2-Nov-07 20:26
John-ph2-Nov-07 20:26 
AnswerRe: DotNet Nuke Pin
Paul Conrad3-Nov-07 5:37
professionalPaul Conrad3-Nov-07 5:37 
QuestionStatic Ip Problem with sql server Pin
cm pandian2-Nov-07 19:02
cm pandian2-Nov-07 19:02 
AnswerRe: Static Ip Problem with sql server Pin
Ghazi H. Wadi2-Nov-07 22:24
Ghazi H. Wadi2-Nov-07 22:24 
AnswerRe: Static Ip Problem with sql server Pin
Paul Conrad3-Nov-07 5:38
professionalPaul Conrad3-Nov-07 5:38 
QuestionFileDialog assistance needed... [modified] Pin
new_phoenix2-Nov-07 7:21
new_phoenix2-Nov-07 7:21 
AnswerRe: FileDialog assistance needed... Pin
pmarfleet2-Nov-07 13:18
pmarfleet2-Nov-07 13:18 
QuestionRemembering the Query ResultsSet across Pages in a GridView Pin
Brian C Hart2-Nov-07 6:53
professionalBrian C Hart2-Nov-07 6:53 
AnswerRe: Remembering the Query ResultsSet across Pages in a GridView Pin
Brian C Hart2-Nov-07 7:18
professionalBrian C Hart2-Nov-07 7:18 

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.