.net 1.1 to Sql Server 2000

How can i connect ASP.NET 1.1 to SQL Server 2000? Please help me.


******** To climb steep hills requires a slow pace at first ****************
0
adonweb
4/5/2008 8:00:54 AM
asp.net.sql-datasource 29906 articles. 0 followers. Follow

3 Replies
536 Views

Similar Articles

[PageSpeed] 34

Using the SQLConnection...This is available in ToolBox DataTab..

 

0
Shahnidhi_14
4/5/2008 10:52:04 AM

Hi adonweb ,

Ado.net is supported in .net1.1(both sqlconnections, sqlcommand, sqldatareader etc are supported) , so I think you can connected to sql 2000 using .net1.1 the same way as .net2.0.

Example from msdn:

private static void ReadOrderData(string connectionString)
{
    string queryString = 
        "SELECT OrderID, CustomerID FROM dbo.Orders;";
    using (SqlConnection connection = new SqlConnection(
               connectionString))
    {
        SqlCommand command = new SqlCommand(
            queryString, connection);
        connection.Open();
        SqlDataReader reader = command.ExecuteReader();
        try
        {
            while (reader.Read())
            {
                Console.WriteLine(String.Format("{0}, {1}",
                    reader[0], reader[1]));
            }
        }
        finally
        {
            // Always call Close when done reading.
            reader.Close();
        }
    }
}
Hope my sgugestion helps

Please remember to click “Mark as Answer” on the post that helps you, and to click “Unmark as Answer” if a marked post does not actually answer your question. This can be beneficial to other community members reading the thread.
0
Bo
4/9/2008 8:55:56 AM

hi,

try to like this,

Web.Config

<add key="DSN" value="server=localhost;uid=sa;pwd=;database=Your_DBName" />

Database Connection Class

public class DatabaseManagerDA

 {
  private string _connectionString;
  private SqlConnection _connectionObject = null;

  public DatabaseManagerDA()
  {
   _connectionString = System.Configuration.ConfigurationSettings.AppSettings["DSN"];
  }

  public SqlConnection GetConnection()
  {
   if(_connectionObject != null)
   {
    _connectionObject = null;
   }
   _connectionObject = new SqlConnection(_connectionString);
   return _connectionObject;
  }
 }

 

Fetch records from Database

SqlConnection _connectionObject;
_connectionObject = new DatabaseManagerDA().GetConnection();

#region GetEstimateDocumenttoTickets
  public  DataTable GetEstimateDocumenttoTickets(int estimateNumber)
  {
   DataTable returnValue = null;

   SqlCommand selectCommand = new SqlCommand();
   selectCommand.CommandText = "SP_GetEstimateDocumenttoTickets";
   selectCommand.CommandType = CommandType.StoredProcedure;
   selectCommand.Connection = _connectionObject;

   selectCommand.Parameters.Add(new SqlParameter("@EstimateNo", estimateNumber));
   

   try
   {
    _connectionObject.Open();
    DataSet dataSet = new DataSet();
    SqlDataAdapter dataAdapter = new SqlDataAdapter(selectCommand);
    dataAdapter.Fill(dataSet);
    returnValue = dataSet.Tables[0];
    _connectionObject.Close();
   }
   catch (Exception exception)
   {
    if (_connectionObject.State == ConnectionState.Open)
    {
     _connectionObject.Close();
    }
    throw new Exception(exception.Message);
   }
   if (_connectionObject.State == ConnectionState.Open)
   {
    _connectionObject.Close();
   }
   return returnValue;
  }
  #endregion

0
gopalanmani
4/9/2008 9:47:37 AM
Reply:

Similar Artilces:

Reports building from SQL SERVER 2000 and .NET 1.1
Dear all I would like to produce a report on the data i have in my database probably in a pdf or excel or word document. What i have is SQL Server 2000 with .NET 1.1 platform.  Is there anything out there i could use? I have done some work on reporting services but thats with SQL server 2005, but now i have to go a bit back. Any advice? cheers  Dan Or is there any other solution to the problem or producing reports in excel/word/pdf formats except for using Reporting services or crystal reports?  Dan You need SQL Server 2000 Enterprise edition or Developer edition i...

XML from SQL Server 2000 tables
i've to write an utility that runs all the time as a service, which extracs data from multiple sql tables and should generate xml data based on a particular schema (some data are optional, some are required in schema) and should store this xml in a file (say xml file).  db is sql server 2000.  .net we currently use 1.1 but planning to change soon to vs.net 2008. I have to write a program that extracts data from multiple tables (in the schema defined by us) and store it as xml in a file. This tables will have atleast 100-10000 records daily and i have to convert this data q...

.NET 1.1 and SQL Server 2005
Hi, I am migrating my client's site from SQL 2k to 2005. The site was built on .NET 1.1 In order to run SQL 2005, do we need to upgrade to .NET 2.0 in order to run the site? If we do need to upgrade to .net 2.0, is there any way to get around the problem and run it on .NET 1.1. This is because we have a lot of 3rd party componenet which only support .NET 1.1 Thanks in advance. Paul...

SQL Server Reporting Services for SQL SERVER 2000 AND Visual Studio.NET 2005 .NET 2.0
Hi, Which version of SQl Server Reporting Services will work with SQL SERVER 2000 in pararrel with ASP.NET 2.0 (.NET 2.0 framework)?  Thanks, Azam HighOnCodingWanna get high! Hi, Okay I got the answer. Yes, we can use the SQL SERVER 2005 Reporting Services with SQL SERVER 2000. HighOnCodingWanna get high! ...

.net 1.1 and SQL Server 2005 #2
Hi,I run .net 1.1, VS2003 with SQL Server Enterprise Manager v 8.0 on my home XP Pro machine.I have recently purchased some hosting with SQL Server 2005 capabilities.  I was in a real rush but I should have checked I suppose.I would love to be able to use my Enterprise Manager but obviously that wont work as it isnt compatible with 2005. It would be preferable not to have to use the web based admin and I have been told I have to install Microsoft SQL Server Management Studio Express, which requires .net 2.0 to be installed. It seems a bit of a mess really.Can anyone enlighten me as to w...

.NET 1.1 running on SQL Server 2005
Hi, I am migrating my client's site from SQL 2k to 2005. The site was built on .NET 1.1 In order to run SQL 2005, do we need to upgrade to .NET 2.0 in order to run the site? If we do need to upgrade to .net 2.0, is there any way to get around the problem and run it on .NET 1.1. This is because we have a lot of 3rd party componenet which only support .NET 1.1 Thanks in advance. Paul No. You would need the 2.0 framework for sure. I think the SQL 2005 installation wizard would detect and install the framework for you.You dont need to upgrade your application to VS 2005, however.*******...

Can .net 1.1 work with SQL SERVER 2005 ?
 What should I do if I want my asp.net 1.1 work with sql server 2005I get wrong message : SQL Server does not exist or access denied It's HARD to be Advanced ProgrammerIrwan. Well, you don't need to change any code.. there is no different of working against a SQL 2005, it's the same way as working against SQL server 2000 etc. If you have some problem to connect to the SQL Server 2005, just check your connection string if it's correct. For example if you provide the right user name and password etc. The connection string for connecting to a SQL Server 2000 and SQL Serv...

Differences between .net 1, .net 1.1, .net 2.0 and .net 3.0
Hi, This seems to be a common question, but i havent got an answer yet:(Can, any one please explain me the differences between these versions.If you keep your feet firmly on the ground, you'll have trouble putting on your pants! Have a look into this links http://en.wikipedia.org/wiki/.NET_Framework http://blogs.msdn.com/mohammadakif/archive/2006/12/03/net-3-0-different-versions-of-the-net-framework.aspx http://www.codeproject.com/aspnet/ComparisonASP1xASP20.aspAshok Rajawww.iGold.inDon't forget to click "Mark as Answer" on the post that helped you. This credits that m...

Using Pull method with SQL server and VB.Net 1.1
I am using the developer 11 version of Crystal. I have created a few reports successfully using the push method (creating a dataset, populating it then assigning it to the report). Because of decision making that is needed in some of the sub-reports etc. I chose to use a larger dataset rather than many more database lookups returning smaller data sets. I am trying to figure out whether I can accomplish some of this using the pull method. I need to be able to use the same report from multiple sites using differnt databases and credentials. It LOOKS like if I try to use the pull method I ha...

Differences between .net 1, .net 1.1, .net 2.0 and .net 3.0 #2
Hi, This seems to be a common question, but i havent got an answer yet:(Can, any one please explain me the differences between these versions.If you keep your feet firmly on the ground, you'll have trouble putting on your pants! There are too many differences for one email - - from 1.0 to 1.1 (not a whole lot of real change, other than fixes, at least compared to 1.1 to 2.0) With 2.0, there were many new declarative controls, with many new ideas added in With 3.0, it's a superset of 2.0 - instead of replacing the installation completely, it just 'added on' new functionality - I would...

Writing Stored Procedure in .NET 1.1 and using in SQL Server 2005
Hi, I am working on an application in ASP.NET 1.1 and SQL Server 2005 as database.I wanted to use SQLCLR feature of SQL Server 2005. Is it possible that i write Stored Procedures in C# 1.1 and deploy on SQL Server 2005? as it is in case of C# 2.0. Please refer some good tutorial for it. Regards,Imran GhaniImran Abdul Ghani SQL Server requires 2.0. The .net team made a number of changes to the memory manager and gc so .net could be hosted in SQL Server....

is .net framework 1.1 same as .net framework SDK 1.1
is .net framework 1.1 same as  .net framework SDK 1.1 Basically Framework 1.1 of .NET includes the Sofware Development Kit (SDK) 1.1 http://www.microsoft.com/downloads/details.aspx?FamilyID=9b3a2ca6-3647-4070-9f41-a333c6b9181d&displaylang=en Regards,Vinz"Code, Beer and Music" that's my way of being a programmer!How to get your Forum Question Answered | Blog | CodeASP.NET I think .net framework 1.1 is just the runtime library to view .net 1.1 programs.  the .net framework SDK 1.1 one is the actual development library used to create them.   Eri...

moving data from vb.net 1.1 Datagrid to sql server 2005 database
Hi, I was hoping someone could help me with a problem I am having. I can get the datagrid to populate from the database fine, like so:     Public Sub BindTheData()         Dim strConn As String        strConn = System.Configuration.ConfigurationSettings.AppSettings("ConnectionString")        Dim objConn As SqlConnection        objConn = New SqlConnection(strConn)        Dim myCmd As SqlComman...

Developed C#.net WebService 1.1 for Client C#.net 1.1. Getting error "Server was unable to process the Request" Pls Help
Hi., I developed Microsoft C#.net Web Services2003 for the Client Application C#.net 2003. When it runs in 5 machines it gives good performance and has no errors. But if i run the same application in about 80 client machines. Getting error "Server was unable to process the request". I use Sql Server 2005 as my database. I get error even when i login at a time for about 25 users. Tried modifying machine.config too. But went unsuccessful. Live Server is 2003 using IIS 6.0 I use very expensive data handling.  Its very urgent pls help. Have to post in Live Server. Thank u., ...

Web resources about - .net 1.1 to Sql Server 2000 - asp.net.sql-datasource

Server farm - Wikipedia, the free encyclopedia
A server farm or server cluster is a collection of computer servers usually maintained by an enterprise to accomplish server needs far beyond ...

Turkey internet servers under sustained cyber attack: internet body
Turkish internet servers have suffered one of the most intense cyberattacks ever seen in the country over the past week, raising fears Ankara ...

Cock.li e-mail server seized by German authorities, admin announces
(credit: Vincent Canfield ) In a new video statement posted on Monday, the administrator of novelty e-mail provider cock.li announced that one ...

Amazon deal: Save $85 on this Sony portable wireless server
Smartphones' memory storage gets filled so quickly these days thanks to photos, videos and more, so get yourself a handy portable wireless server ...

Facebook releases design for its souped-up A.I. server, 'Big Sur'
Facebook is releasing the hardware design for a server it uses to train artificial intelligence (A.I.) software, allowing other companies exploring ...

Applebee’s Server Returns $32,000 In Cash Family Accidentally Left On The Table
... and scored a huge tip from some abnormally generous person, and you figure the money is yours to keep. Or, if you’re like one Applebee’s server ...

Former Intelligence Chief Calls ‘Top Secret’ Info on Hillary’s Server ‘Unreal’
Former Intelligence Chief Calls ‘Top Secret’ Info on Hillary’s Server ‘Unreal’

Facebook, Google server outsourcing strategy change expected to impact profitability for ODMs
Facebook is planning to add Wiwynn, a server subsidiary of Wistron, as a new datacenter server supplier, joining its primary supplier Quanta ...

Hillary Clinton's private server had two 'top secret' emails
Those concerns that Hillary Clinton's private email server had classified intel? They're apparently well-founded. Sources for Fox News and Politico ...

CTERA Unveils Server Data Protection for Enterprise CloudOps
The data protection solution evolves the backup capabilities developed as part of the company’s Enterprise File Services Platform.

Resources last updated: 12/26/2015 3:51:41 PM