In sql server 2012 i'm using
USE myDatabase;
GO
SELECT *
FROM sys.objects
WHERE type = 'U';
Is it possible to do the same in syBase ?
In order to get a list of all tables in the current database, you can filter the sysobjects table by type = ‘U’ e.g.:
select convert(varchar(30),o.name) AS table_name
from sysobjects o
where type = 'U'
order by table_name
Further Reference
Here is an example of getting all table names in MSSQL
or SQL Server database
:
USE test; //SELECT DATABASE
SELECT table_name FROM information_schema.tables WHERE table_type = 'base table'
or you can use sys.tables to get all table names from selected database as shown in following SQL query
USE test; //SELECT DATABASE
SELECT * FROM sys.tables
That's all on how to find all table names from database in SQL Server.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With