Computers & Internet Logo

Related Topics:

Posted on Jul 22, 2009
Answered by a Fixya Expert

Trustworthy Expert Solutions

At Fixya.com, our trusted experts are meticulously vetted and possess extensive experience in their respective fields. Backed by a community of knowledgeable professionals, our platform ensures that the solutions provided are thoroughly researched and validated.

View Our Top Experts

How to connect two different database in two servers from one ser

Hello Guys
I want to connect two databases at the same time but it looks like the java is only picking up the second database.

One database is on my localhost and the other one is on server, I want to transfer the data from my localhost database to the database on the server. I have also tried passing the 4th argument to the mysql_connect function but I can't get it to work.

  • Tom
    Tom May 11, 2010

    Are you needing to simply move the data from one DB to the other once? Or synchronize the data? Or during transaction processing update both databases?

×

1 Answer

Fahad I MEMON

Level 2:

An expert who has achieved level 2 by getting 100 points

MVP:

An expert that got 5 achievements.

Vice President:

An expert whose answer got voted for 100 times.

Sniper:

An expert who has posted more than 50 answers, of which 90% or more were rated as helpful.

  • Expert 129 Answers
  • Posted on Jul 30, 2009
Fahad I MEMON
Expert
Level 2:

An expert who has achieved level 2 by getting 100 points

MVP:

An expert that got 5 achievements.

Vice President:

An expert whose answer got voted for 100 times.

Sniper:

An expert who has posted more than 50 answers, of which 90% or more were rated as helpful.

Joined: Mar 23, 2009
Answers
129
Questions
0
Helped
68477
Points
429

You have to get data from the local database store it in the variale and then pass this value to server database connection. hope it will help you
Thanks

Add Your Answer

×

Uploading: 0%

my-video-file.mp4

Complete. Click "Add" to insert your video. Add

×

Loading...
Loading...

Related Questions:

0helpful
3answers

How to recover SQL Server Database file formate?

After you connect to the appropriate instance of the SQL Server Database Engine, in Object Explorer, click the server name to expand the server tree. Tweakbox How To Use
1helpful
2answers

Attach a database without the corrupted log file

There might be other options out there. This is something that worked for me once but there are no guarantees that it will work at all times.

Stop SQL Server instance -> Copy MDF and LDF files to another location -> Delete original MDF and LDF files -> Start SQL Server instance again -> Create new database with exact same name and file names -> Stop SQL Server -> overwrite newly created MDF and LDF.

After this your database should be back online. If it is then go ahead and put it into EMERGANCY mode and SINGLE USER mode.

Finally go ahead and execute DBCC CHECKDB like this

DBCC CHECKDB (databaseName, REPAIR_ALLOW_DATA_LOSS) WITH NO_INFOMSGS

More information you can dig out from resources directly connected with SQL Server databases and database corruption in MS SQL Server any version...
http://itknowledgeexchange.techtarget.com/itanswers/how-to-restore-mdf-file-as-bakcup-databe/
https://www.repairtoolbox.com/sqlserverrepair.html SQL Server Repair Toolbox
1helpful
2answers

Repair database without being attached SQL 2005

Use SQL Server Repair Kit. A convenient, reliable and ultimately efficient MS SQL database repair tool for system administrators, developers and database experts. Best in class performance and outstanding usability for users with and without experience.

Read more: http://www.mssqlserver.repair/
1helpful
3answers

Recover data from corrupt .mdf and .ldf files.

You can find more information here:
http://www.filerepairforum.com/forum/microsoft/microsoft-aa/sql-server/569-i-have-a-problem-how-do-i-fix-a-corrupted-database-file

Open your SQL Server Management Studio console. This application shortcut is available in the SQL Server directory in the Windows Start button.
· Enter the system administrator user name and password. SQL Server's administrator user name is "sa." This account is required for privileges to restore the database. If your restoring on a host provider server, use the administrator user name and password they supplied for your account.
·Right-click your database name and select "Attach." In the new window that opens, click the "Add" button to open a dialog box.
·Select your MDF file and press the "Ok" button. It may take several minutes to restore the database if it is a large file. Once the process is finished, browse your tables to verify the data. The database is now restored.
If nothing helped try to use:SQL Server Fix Toolbox
http://www.fixsqldatabase.com/
0helpful
6answers

Any Powerful SQL repair tool with new features

SQL database Recovery Software remove errors from corrupted SQL server database and allow to recover your all database of SQL Server Recovery tool support with all the MS SQL server version and MS windows.

Visit more here:- SQL Database Recovery Software SQL Recovery Tool
1helpful
1answer

Syncing client with server - Restaurant Pro Express

Your getting a connection successful because your looking at the localhost. The server would be the network name of your server. And the password is case sensitive and is pcAmer1ca. (Note the number 1, not an i)
0helpful
5answers

How get sql data backup

there is facility in enterprise manager to take back of database!
Not finding what you are looking for?

1,135 views

Ask a Question

Usually answered in minutes!

Top Sun Computers & Internet Experts

Rob Hill
Rob Hill

Level 3 Expert

1480 Answers

k24674

Level 3 Expert

8093 Answers

Sean Wright
Sean Wright

Level 3 Expert

2045 Answers

Are you a Sun Computer and Internet Expert? Answer questions, earn points and help others

Answer questions

Manuals & User Guides

Loading...