I'm new to this but I just installed Oracle Database 19c and SQL Developer. I am successfully connected to the HR sample schema. I can query against the HR tables such as HR.EMPLOYEES, etc.. However, in the Connections pane, when I expand the tables under this connection, there is a long list of tables starting with AQ$_INTERNET_AGENTS_PRIVS and a big list of other tables, but I can't see any of the HR tables? Where are they? Is this a view setting maybe?
This is for practice/homework. While it still seems to work, I can't figure out what the problem is. Researched here and other locations on the web.
The UI shows you the tables (and other objects) that belong to the schema for the user you have logged into.
So if you login in as HR, you'll see the tables for HR.
Otherwise if you want to see objects belonging to a different schema, navigate to the 'Other Users' node.
Or if you have synonyms in your schema which point to tables in another schema, you can ask SQL Developer to display those
And now when I look at my Tables list for my user that doesn't have any tables..
I talk about this in a bit more detail here.
Related
I created an entity-relationship diagram (logical model) and engineered it to a relational model.
The tables were generated. Now I need to use them from the connection XE as you see in the picture.
The tables I made can only be seen on the data modeler design view in the "Browser", how do I get them on the connection "XE" to generate data dictionary, etc?
There are three possibilities:
you just need to expand the tables item in the tree to see your tables
You are looking in the wrong schema/user - go down to Other Users, and find the schema those tables belong to
The tables do not exist in the current database
If #3 is the issue, you would need to create them, possibly using the information in your Data Model - that is, you can generate the DDL/SQL scripts for those tables.
Then taking those scripts, run them while connected to the appropriate database/schema.
Disclaimer: I'm an Oracle employee and the product manager for these tools.
I am rebuilding a system so instead of using multiple Access and Excel files the business I am working for, uses SSRS for reporting requirements. Most things are coming along great but I have one sticking point.
One of the Access databases has a table within itself rather than replying on the server data, which is there to keep the grade level of staff up to date (as it is a very complex method on how staff go up a grade).
Now I could easily build a new table in the SQL Server, but I do not want management relying on me for updating this particular table. I could also rebuild the Access database to upload the data to the server which is probably what I will do, but what I wanted to ask first is there a way to join to the table in the Access Database from the T-SQL query, as if it was another table in the main database?
Yes. Attach the database file under Server Objects as a Linked Server.
To ease referencing the table in this, create a view in your database that "hides" the needed weird triple-dot syntax, like:
SELECT FIELD1, FIELD2, FIELDN
FROM THELINKEDSERVERNAME...YourTable AS LinkedYourTable
Then use this view to read the table.
I've been asked to modify an Access database by putting the data themselves into a Postgres database while keeping the old Access file as a frontend. So far everything has worked just fine, with every linked table, query and form working just like before when viewed.
The issue is, however, that all of the forms call on MS Access queries which users can insert data into, but after the tables have been migrated into PostgreSQL, those queries no longer allow for data inserts, which means the forms no longer allow for data inserts. I can edit the rows already entered, but I cannot make new rows, and I can insert new rows into the linked tables. This is as a superuser.
I have made Access queries in the past that allowed for data entry to a Postgres database, but I don't have access to those files now, and I can't for the life of me figure out what I did diferently back then.
Highly appreciate any leads. Couldn't find anything on this. Using MS Access 2010 and PostgreSQL 9.1
Solved
Andre pointed out that these MS Access queries must include the primary key to give the option of creating new rows. Once I added the id field to the query, the forms worked like they did before.
The answer, supplied by Andre, is that simple MS Access queries allow for inserts into PostgreSQL if the queries include the primary key of the queried table. Cheers!
I am following a SQL tutorial, it states
Database administrators often use relationship diagrams to help demonstrate how database tables are connected.
However,I tried every corner of mysql workbench but failed to find such a well-organized diagram.
How could I see the database structure as the diagram shows?
Looks like you didn't find the modeling part of MySQL Workbench yet. Walk through the tutorials to reverse engineer a schema and create an EER model from it.
You can customize colors and figure sizes + positions, organize a diagram with layers for better overview and change the notation (crow food etc.). Search for modeling with MySQL Workbench for more tips.
I learned long time ago database structure. But as I see on your picture, the diagram shows columns of tables and the relations between them.
1:N - means from the other table allowed to reference more than 1 records
1:1 - means from the other table allowed to reference only one record.
Example: relation between customers and orders.
The orders can have many customers_id and same customers as well. Because one customer can send more order.
You can find customer_id in order table too.
In the newMips database, the 2 tables user and *_e_user have (almost) the same data. Why? What is the role of each tables?
I guess the answer will help me to understand why the tables role and *_e_role contain different data.
Table user is to manage users of the generator itself.
Table *_e_user is to manage users of generated applications.