473,320 Members | 1,979 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,320 software developers and data experts.

Query Across DBs in MySQL

Hi

I'm new to MySQL and am wanting to be connected to the MySQL server and
query across diffrent db's. To my understanding a different db in MySQL
is the same as a schema in Oracle. Am I correct in this thinking?

What I want is to have one DB called projects which has common tables
such as contact_details, postal_codes, language and so on. Then a
number of other db's for different projects. Then project1 has its own
tables but can also see those in the projects db.

Any help with this would be greatly appriciated.

Thanks
Melissa

Oct 9 '05 #1
3 1860
>I'm new to MySQL and am wanting to be connected to the MySQL server and
query across diffrent db's. To my understanding a different db in MySQL
is the same as a schema in Oracle. Am I correct in this thinking?

What I want is to have one DB called projects which has common tables
such as contact_details, postal_codes, language and so on. Then a
number of other db's for different projects. Then project1 has its own
tables but can also see those in the projects db.


In general, if you can put a table name somewhere in a query, you
can also put databasename.tablename in that place to refer to a
table in a different database. MySQL access permissions still apply
(and checking this might slow things down by a tiny bit, but probably
not by much) so you have to have a login granted access to all of
the tables involved. The MySQL privilege system easily handles
having logins with access to their own database plus (possibly
read-only) access to a common database.

Gordon L. Burditt
Oct 9 '05 #2
Thanks for the help.
I am wanting to do these queries without having to out the db name into
the query sting.

I know that this is possible in oracle. You can grant privledges to
across different schemas.

Thanks

Oct 10 '05 #3
>Thanks for the help.
I am wanting to do these queries without having to out the db name into
the query sting.
How, then, do you intend to specify where the "other" database IS?
I know that this is possible in oracle. You can grant privledges to
across different schemas.


Granting privileges is something different from saying which other
database you want to use.

Gordon L. Burditt
Oct 10 '05 #4

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: nao | last post by:
Hi all! I am aware that this question might involve Javascript and MySQL. So far I haven´t found a suitable solution in JavaScript ng´s - maybe becauese php-programmers are more likely to come...
0
by: Doug Reese | last post by:
hello, i have what seems to me a very common operation i'm performing. i need to find the balance on an invoice. i was not having any problems until the production server was upgraded to mysql...
8
by: Rigga | last post by:
Hi, I am new to mysql and need help on how to join tables. I have a database which contains 4 tables, the main table contains information by date order and the other 3 contain data also in date...
1
by: Dave Crypto | last post by:
Hi there, SUMMARY: 1) When I use phpadmin to export a large database, the file created on my local PC never containes all the tables and information. It seems to max out at about 10mb. 2)...
2
by: Galina | last post by:
Hello I need to get data from 4 Oracle tables and combine them into a temporary table in my application. I get data using a pass-through query dynamically created in code: mySQL = "SELECT...
0
by: taras.di | last post by:
Hi everyone, I've come across an extremely strange problem. The exact same query in both mysql command line client, and mysql query browser gives entirely different results. I was hoping someone...
0
by: PW | last post by:
I am trying to create a crosstab report in ASP. I'm using ASP/VBScript and Access database. I used Access to create the SQL query, then copied the SQL and embedded it in my ASP like this ... ...
10
by: Jerim79 | last post by:
I need to take the output from a query and convert it to lower case. Here is the relevant code: $query="SELECT FNAME, LNAME FROM (table) WHERE FNAME=('$FName') AND LNAME=('$LName')"; $result =...
2
by: DavidPr | last post by:
I have a Bible database and I need help writing the query a little bit of styling. I want to display all the books and chapters (which will be linked to another page -passage.php) that will...
0
by: DolphinDB | last post by:
The formulas of 101 quantitative trading alphas used by WorldQuant were presented in the paper 101 Formulaic Alphas. However, some formulas are complex, leading to challenges in calculation. Take...
0
by: DolphinDB | last post by:
Tired of spending countless mintues downsampling your data? Look no further! In this article, you’ll learn how to efficiently downsample 6.48 billion high-frequency records to 61 million...
0
isladogs
by: isladogs | last post by:
The next Access Europe meeting will be on Wednesday 6 Mar 2024 starting at 18:00 UK time (6PM UTC) and finishing at about 19:15 (7.15PM). In this month's session, we are pleased to welcome back...
0
by: Vimpel783 | last post by:
Hello! Guys, I found this code on the Internet, but I need to modify it a little. It works well, the problem is this: Data is sent from only one cell, in this case B5, but it is necessary that data...
0
by: jfyes | last post by:
As a hardware engineer, after seeing that CEIWEI recently released a new tool for Modbus RTU Over TCP/UDP filtering and monitoring, I actively went to its official website to take a look. It turned...
0
by: ArrayDB | last post by:
The error message I've encountered is; ERROR:root:Error generating model response: exception: access violation writing 0x0000000000005140, which seems to be indicative of an access violation...
0
by: CloudSolutions | last post by:
Introduction: For many beginners and individual users, requiring a credit card and email registration may pose a barrier when starting to use cloud servers. However, some cloud server providers now...
0
by: af34tf | last post by:
Hi Guys, I have a domain whose name is BytesLimited.com, and I want to sell it. Does anyone know about platforms that allow me to list my domain in auction for free. Thank you
0
by: Faith0G | last post by:
I am starting a new it consulting business and it's been a while since I setup a new website. Is wordpress still the best web based software for hosting a 5 page website? The webpages will be...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.