DataSource Controls :: Different Databases Residing On Two Different Servers?

Feb 11, 2010

I need to query two table from different databases residing on two different servers.

Scenario:

1st Server : Abc

Database: DB1

Table: Accounts

2nd Server: Xyz

Database: DB2

Table: Clients

The common linking information between Clients and Accounts is "email_id". I'm sure a lot you are saying why am I not maintaining both tables on single server but there is a lot going on behind scenes and if I move tables, I'll have to modify many dependent web pages.

View 1 Replies


Similar Messages:

DataSource Controls :: Join Across Two Databases On (possibly) Different Servers

Feb 12, 2010

I would like to create a gridview where all of the items in one table are listed and a checkbox is checked if that item also shows up in another table. The difficulty comes in the fact that table are not only in different databases, but possibly on different servers.

Is there any way to do this via ASP.NET connection strings, so that it doesn't matter where the databases live? I'd rather use connection strings, because I don't want to hard-code credentials into the queries (OPENROWSET or whatnot).

View 1 Replies

DataSource Controls :: Can Load The Data Into SQL Servers Table From FoxPro

Jan 8, 2010

I am using SQL Server 2005 and i have a application that using FoxPro.

Can I load the data into SQL Server's table from FoxPro? if yes, i would like schedule this job daily, can i write it in Store Procedure and run daily in special time?

View 7 Replies

DataSource Controls :: Connecting Two Servers With A Readonly Privilage To A Database?

Apr 12, 2010

I have two PCs with Windows Server 2003 standard adition installed on them, each are in a saperte room, and having SQL Server 2005 Express. Now I want to let Myserver to connect to server1 with a readonly access to a database on it. I figured to create a user acount on server1, and make it as a login account in SQL Server and grant the appropreate privilage. Now I'm wandering are there any security risks regarding this approch.

View 1 Replies

DataSource Controls :: TableDiff Comparing Tables On SQL 2005 And SQL 2008 Servers?

Jun 16, 2010

C:Program FilesMicrosoft SQL Server100COM>tablediff -sourceserver "warehousebox"
-sourcedatabase "table1" -sourcetable "siqvirtual" -destinationserver "mainbox" -de
stinationdatabase "table1" -destinationtable "siqvirtual" -destinationuser "sarah"
-destinationpassword "hello" -strict -f "c:fooDiff.sql"

Since these table are on two different boxes and 2 different versions, I am getting error message that tables cant be compared because they have different schema's.Schema's are the same but they are on different machines and different servers. What is a work around it?

View 2 Replies

Double Hop On Workgroup Servers Vs Domain Servers

Nov 16, 2010

I am trying to set up my web site on a stand alone server using Windows Server 2003 with IIS 6 which will access SQL server database (2008) on windows 2008 R2 server (also not in the domain) I am using form authentication and I have configured a custom identity account in IIS6. The local account is on both servers with same password and I have registered the account using aspnet_regiis.exe -ga The application pool in my iis6 has the custom local account set as the identity and my web.config file has the appropriate tags in the system.web element <identity impersonate="true" />

The problem is the local account does not seem to get passed to the sql server. Right now my iis settings are anonymous access (using the local acct vs isr) and no authentication specified under that - I did try Integrated and basic but it prompts for the username and password which I do not want. One article I read stated this: windows authentication does not support delegation (passing credentials from one server to another) and is limited to the one hop rule, only a primary token can be passed to a second server. windows
authentication on iis (all versions) gives the thread a secondary(impersonation) token which can not be used to access any network resouce

View 1 Replies

DataSource Controls :: Merging SQL Databases?

Jan 3, 2010

Before I can upload my web site I need to merge my 6 small databases into one otherwise I am going to pay unreasonable hosting fees.Is there any easy way to do this?

View 4 Replies

DataSource Controls :: Transfer Data Between Databases

May 7, 2010

I want to transfer data from an acces database to a sqldatabase. This is my code:

using System;
using System.Configuration;
using System.Data;
using System.Data.SqlClient;
using System.Data.OleDb;
using System.Linq;
using System.Web;
using System.Web.Security;
using System.Web.UI;
using System.Web.UI.HtmlControls;
using System.Web.UI.WebControls;
using System.Web.UI.WebControls.WebParts;
using System.Xml.Linq;
public partial class _Default : System.Web.UI.Page
{
#region page load
protected void Page_Load(object sender, EventArgs e)
{
}
#endregion
protected void click_Transfer(object sender, EventArgs e)
{
OleDbConnection conn1 = null;
OleDbDataAdapter da1 = null;
DataSet ds1 = null;
SqlConnection conn2 = null;
SqlDataAdapter da2 = null;
DataSet ds2 = null;
// 1 Opzetten dataAdapter en dataset
try
{
// Ophalen connectiestring en opzetten v/d connectie
string connString1 = ConfigurationManager.ConnectionStrings["PrinterConnectionString"].ToString();
conn1 = new OleDbConnection(connString1);
string connString2 = ConfigurationManager.ConnectionStrings["PrinterConnectionString2"].ToString();
conn2 = new SqlConnection(connString2);
// Aanmaken van DataAdapters
da1 = new OleDbDataAdapter();
da2 = new SqlDataAdapter();
// Opzetten SelectieCommand
string sql1 = "SELECT * FROM tblPrinter";
OleDbCommand cmd1 = new OleDbCommand(sql1, conn1);
SqlCommand cmd2 = new SqlCommand(sql1, conn2);
da1.SelectCommand = cmd1;
da2.SelectCommand = cmd2;
string sql2 = @"INSERT INTO tblPrinter(PRINTER_ID, tblSoortApparaat, MERK, MODEL, LOKAAL_ID )" +
@"VALUES (@id, @soort, @merk, @model, @lokaal)";
cmd2 = new SqlCommand(sql2, conn2);
// InsertCommand dataAdapter
cmd2.Parameters.Add("@id", SqlDbType.Int, 0, "PRINTER_ID");
cmd2.Parameters.Add("@soort", SqlDbType.NVarChar, 100, "tblSoortApparaat");
cmd2.Parameters.Add("@merk", SqlDbType.NVarChar, 100, "MERK");
cmd2.Parameters.Add("@model", SqlDbType.NVarChar, 100, "MODEL");
cmd2.Parameters.Add("@lokaal", SqlDbType.Int, 0, "LOKAAL_ID");
da2.InsertCommand = cmd2;
ds1 = new DataSet();
da1.Fill(ds1, "PRINTERS");
ds2 = new DataSet();
da2.Fill(ds2, "PRINTERS2");
// Stap 2: Start bewerking!!
DataTable table1 = ds1.Tables["PRINTERS"];
DataTable table2 = ds2.Tables["PRINTERS2"];
DataRow newrow = null;
for (int i = 0; i < table1.Rows.Count; i++)
{
newrow = table2.NewRow();
newrow["PRINTER_ID"] = i + 1;
newrow["tblSoortApparaat"] = table1.Columns[1].;
newrow["MERK"] = table1.Columns[2].DefaultValue;
newrow["MODEL"] = table1.Columns[3].DefaultValue;
newrow["LOKAAL_ID"] = table1.Columns[4].DefaultValue;
table2.Rows.Add(newrow);
}
da2.Update(ds2, "PRINTERS2");
lblMessage.Text = table1.Rows.Count.ToString() + " rijen zijn toegevoegd";
// bindgrid();
}
catch (Exception ex)
{
lblError.Text = ex.Message;
}
}
}

Here is my problem newrow["tblSoortApparaat"] = table1.Columns[1].; When i do that al the rows in my sql database are filt up with the columname. But i want the specik data. For example sql database:

1 tblSoortApparaat
2 tblSoortApparaat
3 tblSoortApparaat

But what i want is

1 PRINTER
2 PC
3 PRINTER

View 1 Replies

DataSource Controls :: How To Connect To Multiple Databases

Jun 8, 2010

i want to know how to connect to multiple databases in sql from our asp.net code??

View 4 Replies

DataSource Controls :: How To Compare Two Scripts Or Databases

Jan 9, 2010

I'm using SQL Server Management Studio Express 2005. I have a database that I'm trying to make an exact copy of under a new name. I generated a script, made a new database then ran the script on it. My problem is the new database is short two objects, it shoudl have 840, but has 838.

I need to find out which two objects are not there.

Maybe there is a way to copy the exact database under a new name? I tried to detach, copy to a new name and then attach, but that did not work.

View 8 Replies

DataSource Controls :: Can Synchronize The Design Of Two Databases

Jan 17, 2010

I used the Database Publishing Wizard to create a copy of my live SQL Server database for testing purposes. Both the live and test databases are hosted by my ISP.

What is the easiest way to transfer design changes from one database to the other without altering the data (assuming that the design changes are compatible with the existing data in the target database)?

Any proposed solution would have to be available via Visual Web Developer 2008 Express or SQL Server 2008 Development Edition.

View 11 Replies

DataSource Controls :: Unable To See Default Databases?

Apr 17, 2010

When I opened sql server configuration manager I am not able to see default databases like master etc. Does anybody know the reason? Did I miss any installation?

View 3 Replies

DataSource Controls :: How To Make One DataContext For Multiple Databases

Apr 17, 2010

I have 2 databases one called DB1, and the other DB2. Both of them has exactly the same design (tables, procedures and etc..)

Now, I am using SQLMETAL to create the DataContext. problem is that there are two lines that direct to a certain database and so I cannot use the same code for both databases.

here is the code:

[Code]....

Now, What I am lookin for is a programmatically way to change this two lines (DataBaseAttribute and the connrection string) .

The easiest solution for me of course is to create the class twice, with the same code and just change manually what I need which is not what I am looking for.

There is a full discussion with microsoft stuff right here: [URL]

View 4 Replies

DataSource Controls :: Use Two Identical SQL Databases Local And Remote?

Mar 13, 2010

I am developing a website with ASP.NET pages that uses an SQL Server database with LINQ to SQL. I am using Visual Studio's Web Developer along with SQL Server 2008 (Developer Edition) database tables on my personal PC to develop this software. When ready, I intend to transfer the compiled web pages to a web hosting service with an SQL server database that is identical to the database on my PC.

I now have a version of my website deployed on a web hosting service at: [URL] and all of my database tables duplicated at the remote SQL server. However, this version of my website does not work with the database yet. I realize that I can have the VS Server Explorer connect to both databases, but I do not know if the web pages on my PC can use both databases interactively.

I am asking how I can develop my website to use the local SQL Server database and then have the deployed pages use the remote SQL Server database with LINQ to SQL. Do I need to create one version that works with the local database and another deployable version that works with the remote database? What should I do?

View 5 Replies

DataSource Controls :: Bad Sql Server Sessionstate Affect Other Databases?

Feb 4, 2010

We have a webfarm using a SQL Server 2000 database to store our session state.

On the same SQL server are our databases for the rest of the websites. The databases are separate but on the same server.

Recently I found that one of our developers is using the session very inefficiently. He is storing large datatables within the session for users when he could accomplish the same thing through other methods.

Can this inefficient use of the session state (when stored in SQL Server) affect the performance of our main database when they are on the same server?

The answer seems to be yes, to some degree. However, I cannot find any documentation to back me up.

View 3 Replies

AJAX :: Refreshing "Grid Residing" Updatepanel From Javascript

Nov 17, 2010

How to refresh updatePanel from Javascript? What i want to do is i want to refresh Grid residing in a updatePanel from Javascript.

View 2 Replies

DataSource Controls :: How To Handle Membership Info Among Multiple Databases

May 13, 2010

I'm creating a site that will offer several different services (blogs, videos, images..), all under the same site.

Each service will use a separate database and all services must use the same membeship info. Users will only need one login to access all these services.

For the membership database i will use the default aspnetdb database.

There are two ways i can think of:

1) Use a join-query between two databases, each time i want to show some service records per user.

2) Create a custom membership-info table in each service's database, and keep it in sync with the master membership table in aspnetdb database.

The custom membership table will be like this:

Id - int, primary, identity
UserId - uniqueidentifier (of aspnetdb database)

What is the best way to do this in the long run, when i will have six or seven or more services ?

View 2 Replies

DataSource Controls :: Unable To Open Attached Databases In SQL Express?

Jan 28, 2010

I have attached two databases (from an ASP.NET application to SQL Express). They have attached fine and are working alright but what disturbs me is when I go and check it from SQL management studio, I could see those databases at attached in SQLExpress but I couldn't open it out them there. I need to update them with many records and I want to open them. Any clue what I am missing? I could have sent you the screen shot but I dont know how to attach an image in this thread.

View 4 Replies

DataSource Controls :: Use Databases Originally Made In Sql Express 2005 - SQL Server 2008?

Apr 20, 2010

is it possible to use databases orignally made in sql express 2005, in SQL server 2008? and is there any method on how to do this?

View 2 Replies

DataSource Controls :: How To Create Multiple Records In A Dataset From Multiple Databases

Mar 7, 2011

I am trying to design my logic to do this but I want to create a dataSet which will have records from several databases, The records all have the same layout.

I am reagin the connection string paths from a table in a database.

I am asking for your help in trying figure out my logic.

Should I use the connectionString builder in conjunction with a loop to Connect, read a record into a dataset Until therer are no more records to be read from my databse table with the database name/paths tables ?

Here is my beginning code which deals with one database:

[Code]....

View 2 Replies

DataSource Controls :: Display Results From Two Separate Tables In Two Separate Databases?

Jan 14, 2010

I have access to two seperate databases (mySQL) located on two servers. I need to get the data, link the tables on a key field and display the results in a datagrid. My challenge is that if the search criteria changes for the display it affects rows returned from on table and should thus automatically affect the linked table and resulting data returned.

what the best approach would be to achieving this? So far I have set up a dataset with a dataadapter and table for each connection and then linked the tables in the dataset. The problem that I'm having is getting the linked resultsets to work.

On my form I have the datagrid with two Objectdatasources one for each dataadapter and i believe that's where I'm going wrong...

View 1 Replies

Forms Data Controls :: Seeing Domains Of Servers Ip On Textbox?

Jun 29, 2010

There is a textbox, a visitor inputs a domain or ip address after that a gridview shows how many domains are there on the ip address.

View 3 Replies

Custom Server Controls :: 'sites On All The Servers Seem To Be Affected?

Nov 3, 2010

I'm hosting a few .net sites, some collapse with this error on an almost daily basis. I've moved the sites between servers, but sites on all the servers seem to be affected, so it is not just a bad install.This problem is acknowledged by MS and they have a fix here:http://support.microsoft.com/kb/975410But they don't provide the fix they talk about.Does anyone have any way to resolve this that does not need Microsoft (since Microsoft clearly aren't bothered to fix it)?

View 1 Replies

Controls :: Convert ASPX Page To PDF File And Save It On Servers Disk?

Feb 22, 2013

i convert my webpage into pdf file in vb.net

i want to save that pdf file in a specific folder in any drive (C: or D:)

how can i give a path in the below coding

Response.Buffer =True
Response.ContentType ="application/pdf"
Response.AddHeader("content-disposition", String.Format("attachment; filename={0}.pdf", Me.psno.Text))
Response.Cache.SetCacheability(HttpCacheability.NoCache)
Dim sw AsNew StringWriter()

[Code].......

View 1 Replies

Databases :: MySQL DataSource Not Find In VWD 2008 Express?

Feb 2, 2010

In Visual Web Developer 2008, creating new sqldatasource connection, I not find ".NET Framework Data Provider for MySQL". I have already installed MySQL Connector/Net 6.2. I could add a reference to MySql.Data. Why!

View 3 Replies







Copyrights 2005-15 www.BigResource.com, All rights reserved