Presentation is loading. Please wait.

Presentation is loading. Please wait.

Enterprise manager Using the Enterprise manager. Purpose of the Enterprise Manager To design tables To populate / update tables To draw diagrams of tables.

Similar presentations


Presentation on theme: "Enterprise manager Using the Enterprise manager. Purpose of the Enterprise Manager To design tables To populate / update tables To draw diagrams of tables."— Presentation transcript:

1 Enterprise manager Using the Enterprise manager

2 Purpose of the Enterprise Manager To design tables To populate / update tables To draw diagrams of tables To create –Stored Procedures –Views –User privileges

3 Opening the Enterprise Manager Choose the Enterprise Manager from the Start menu. Connect as for the Query Analyser Open the databases folder and find your database. Register your server by clicking this icon.

4 Enterprise manager screen

5 Expand your database…

6 Before you set up tables…

7 After you set up tables…

8 Table view The tables that you set up are User tables. The tables that are there for system administration are System tables. Sometimes it is useful to be able to see what tables are there and what is in them. To see what is in the tables, right click on the table and click ‘open table’.

9 To draw a diagram…

10 Diagrams folder

11 To add a new one Right click in the diagram window!

12 The tables in your database are listed on the left. Click the ones you want on the diagram and Add them. Click Next and Finish. The diagram is generated.

13 Stored Procedures Make an SQL statement into a stored Procedure

14 Example Query Select categoryName, cast(ProductName as char(12))as Product, cast(([order details].unitPrice*Quantity)-Discount as decimal(10,2)) as income from categories join products on categories.categoryid = products.categoryid join [order details] on products.productid = [order details].productid

15 Right click Stored Procedure Choose Add New Procedure

16 Change the [Procedure Name] to one of your own choosing. Paste or type in the SQL from the query. Click Check Syntax

17 Stored Procedure Window This one is called ProductSalesByCategory

18 Stored Click OK. The procedure is now stored. This is what the browser will now show.

19 To Run in the Query Analyser You do not have write privilege to Northwind. Try to set up a stored procedure in your own database.


Download ppt "Enterprise manager Using the Enterprise manager. Purpose of the Enterprise Manager To design tables To populate / update tables To draw diagrams of tables."

Similar presentations


Ads by Google