All pastes #102221 Raw Edit

Anonymous

public unlisted text v1 · immutable
#102221 ·published 2006-07-27 12:42 UTC
rendered paste body
using System;
using System.Data;
using System.Data.SQLite;
using System.Diagnostics;
using System.Text;

namespace TestEnvironment
{
    class SQLExec
    {
        public SQLiteConnection conn;
        public SQLiteDataReader sqlrd;
        public SQLiteCommand sqlcmd;

        public void SQLExec(string strDBPath, string strQuery)
        {
            SQLExec(strDBPath);
            SQLQuery(strQuery);
        }

        public void SQLExec(string strDBPath)
        {
            conn = new SQLiteConnection(strDBPath);
            conn.Open();
            //Dbug(Convert.ToString(sqlrd.GetValue(1)));
        }

        public void SQLQuery(string strQuery)
        {
            //Do something ffs..
            sqlcmd = new SQLiteCommand(@"select * from emailaddresses", conn);
            sqlcmd.CommandType = CommandType.Text;
            sqlrd = sqlcmd.ExecuteReader();
        }

    }
}