Tables in a oracle 11g schema are not visible in ArcCatalog (ArcGis) - oracle11g

I created an oracle 11g user (for example user1) using ddl.
I created some tables in the user's schema using ddl.
All tables of user1 have a unique field(objctid).
This oracle instance contains the SDE schema.
But the tables are invisible in ArcCatalog and user1 schema is invisible in ArcCatalog.
If I create a table using ArcCatalog in the user1 schema, then this table is visible in ArcCatalog, but if I create a table using ddl, then this table is invisible in ArcCatalog.
What could be the problem?

Related

Reference another table in ASP.NET without a foreign key or joining tables

I have read-only access to a database. This database has multiple tables with status codes and one other reference table the gives a name for each code. These tables are not linked by a foreign key and I can't alter the database in any way. I'd like to display the status names in my web-app view instead of the numeric status code, is there a way to do this? Using EF Core 6
I tried to join the two tables but it didn't match the model in the View. I don't know how to remedy this situation without creating a new table (which I can't do)

Why won't my table I created in one tablespace show up when I query it from another tablespace?

Both tablespaces are in the same DB so in Oracle SQL Developer, if I login to one tablespace tb1 i can see all the tables in tb2. Because of permissions I was unable to create the table tb2.new_table while logged into tb1. So I logged into tb2 and made tb2.new_table and can query it there. When I log back into tb1 I cannot see the newly created tb2.new_table. I'm just wondering why it's not showing up, I did commit after I made the new table.
My confusion comes as when I was logged into tb1 I was able to add a column to a table in tb2. Any ideas?
You can't log in to a tablespace. And you don't refer to a table by its tablespace (a table can exist in multiple tablespaces or in no tablespace). If you are referring to a table tb2.new_table, that implies that tb2 is the name of a schema, not a tablespace. Tablespaces have nothing to do with permissions, they are simply a collection of physical data files. Schemas do impact permissions.
It appears that you created a new table in schema2 but haven't given user1 permission to do anything with that table. Assuming that is the case, as user2 run the commant
grant select on new_table to user1
and then user1 should be able to
select * from user2.new_table
If you want user1 to be able to insert, update, and/or delete data in new_table, you'd need to grant those permissions as well, i.e.
grant insert, update, delete on new_table to user1

Drop a table originally created with 'unknown tokenizer'?

I have a sqlite3 database. A single table inside this DB can't be dropped, the error message says unknown tokenizer: mm.
I tried it directly with the command DROP TABLE tablename; inside the newest SQLiteSpy v1.9.11 and also within .NET code and the official sqlite NuGet package v 1.0.103.
How can I drop a table where the tokenizer is unknown?
The documentation says:
For each FTS virtual table in a database, three to five real (non-virtual) tables are created to store the underlying data. These real tables are called "shadow tables". The real tables are named "%_content", "%_segdir", "%_segments", "%_stat", and "%_docsize", where "%" is replaced by the name of the FTS virtual table.
So to get rid of that table, drop the shadow tables:
DROP TABLE tablename_content;
DROP TABLE tablename_segdir;
DROP TABLE tablename_segments;
DROP TABLE tablename_stat;
DROP TABLE tablename_docsize;
And then use the (very dangerous) PRAGMA writable_schema to remove the remaining information about this table from the system table:
PRAGMA writable_schema = ON;
DELETE FROM sqlite_master WHERE type = 'table' AND name = 'tablename';
SQLite caches schema information, so then you need to close and re-open the database.

How to restrict DB user to view table data if he has SELECT permission

An Oracle DB user has SELECT permission on all the tables of a DB schema. Can i restrict the user to view the table data.The user should be able to select the table but should not be able to see the data.
This specific requirement is required for user who reviews DB design and generates ALTER script for DB using Oracle Data Modeler 3.3 where he can just see the table design and can compare it with ERD
Can i achieve it using FGAC or RLS?
You can achieve this by granting only references
GRANT references ON schema_a.table TO erd_user;
the erd_user can then use
DESC schema_a.table
to get a definition but not select any data.
This might be preferred to giving the SELECT CATALOGUE where they can see a lot more information that you might like.

Update QSqlTableModel on updation of Sqlite database

I am having one QSqlTableModel which has one Sqlite database table being linked to it.
My database table can be updated via model or directly from other source.
How can i refresh my model to fetch updated data from table whenever that particular table is updated without using select() function.
QSqlTableModel * dbEmployeeModel = new QSqlTableModel(this, db); // db refers Sqlite db connection
dbEmployeeModel->setTable("EMP");
I want my dbEmployeeModel to be updated whenever there is a change in EMP table in database without using dbEmployeeModel->select()

Resources