Can't delete table in different schema from Apache Ignite - ignite

I try to drop my tables in Apache ignite.
For example;
drop table if exists city
The code is working for PUBLIC schema but I couldn't delete tables from other schemas.
The error says 'Failed to parse query. Table "PRODUCT" not found;'
Here is the screenshot of my PowerShell?
How can I delete the tables belong the different schemas?

You need to fully qualify it:
drop table "Product".PRODUCT;
You need to do the same thing whenever you reference tables in different schemas, for example with a JOIN.

Related

Best way of importing tables to PostGre from Oracle?

I have done some queries in a read-only (Oracle/SQL developer) dB where I have absolutely no privileges to create temporary tables or anything else. I want to export the tables resulting of my queries into another db (PostGre/pgAdmin) db in order to be able to do other queries on the result.
Is there an easy way to create the columns of my exported tables in the PostGre db using pgAdmin or do I have to create all the columns manually ?
You could install the Oracle Foreign Data Wrapper in your PostgreSQL database and use IMPORT FOREIGN SCHEMA to create foreign tables for your Oracle tables.
Then you can use
CREATE TABLE local_table AS SELECT * FROM foreign_table;
to copy the data.

Deleting objects from SQL Server

In SQL Server Database Engine I have a table named Table A.
I deleted the table using graphical interface, but when I wanted to create a table with same name, the error shows
The object already exists
What is the remedy of this situation?
The following steps should help you track down what is going on and help you create your table:
Right-click on your database and select refresh
Verify that your table does not exist under this database.
If you table is
not shown here, then very likely your table is displayed under the
master database.
To create a table in your selected database,
first select the database and then run your query.
A better
option for number 4, just to be sure you are specifying the correct
database is to run the command use dbname; (where dbname is
the name of your database). Do this on the line above your create table code.

How to create copy of full schema on same database in Redshift

Currently Redshift do not provide privilege to create copy of full schema on same database in Redshift. I followed this(http://docs.aws.amazon.com/redshift/latest/dg/r_CREATE_SCHEMA.html), but did not get any information on my question
Yes, you can use below query to copy your data from one schema to another.
Create table new_schema.table_name as select * from old_schema.table_name.
It sounds like you want to create a copy of all the tables with data. If so then you will have to:
Create the new schema
Retrieve the DDL for all tables in existing schema
Use this view: https://github.com/awslabs/amazon-redshift-utils/blob/master/src/AdminViews/v_generate_tbl_ddl.sql
Modify the DDL to reference the new schema
Run the DDL to create the target tables
Run an INSERT INTO new_schema.new_table SELECT * FROM old_schema.old_table; for each table in the schema.

SQL Server 2005: How to identify all tables referencing a specified table

I have a table which I need to get rid of. But there are several tables in the database referencing this table. Before I remove it, I need to modify the columns in the referencing tables. How can I find out which tables are referencing the table I want to remove?
If they are defined as foreign keys to the database table you can use the command
sp_help TableName
and that will list all of the constraints.

There is already an object named 'tbltable1' in the database

I am trying to insert data from one table to another with same structure,
select * into tbltable1 from tbltable1_Link
I am getting the following error message:
There is already an object named 'tbltable1' in the database.
The SELECT INTO statement creates a new table of the name you provide and populates it with the results of the SELECT statement.
I think you should be using INSERT INTO since the table already exists. If your purpose is in fact to populate a temporary table, then you should provide a table name that does not already exist in the database.
See MSDN for more information on this.
If you are confident that tbltable1 is not required, you can drop the table first.
You may also want to consider using temporary tables...
Select * into ##MyTemporaryTable FROM tblTable1_Link
You can then use the temporary table in this session. (Ending the session should drop the temporary table automatically, if I remember correctly. It's been a while since I've worked with SQL Server).