Working with Oracle Database XE. Create New User Account Using SQL Run Script Files PL/SQL Objects PL/SQL Server Pages



Similar documents
Oracle Database 10g Express

owncloud Configuration and Usage Guide

Fairfield University Using Xythos for File Sharing

ProjectWise Explorer V8i User Manual for Subconsultants & Team Members

To successfully initialize Microsoft Outlook (Outlook) the first time, settings need to be verified.

Avatier Identity Management Suite

User guide. Business

HDAccess Administrators User Manual. Help Desk Authority 9.0

How To Create An Easybelle History Database On A Microsoft Powerbook (Windows)

Working with Office Applications and ProjectWise

USING STUFFIT DELUXE THE STUFFIT START PAGE CREATING ARCHIVES (COMPRESSED FILES)

Using Internet or Windows Explorer to Upload Your Site

5. At the Windows Component panel, select the Internet Information Services (IIS) checkbox, and then hit Next.

OUTLOOK WEB APP (OWA): MAIL

Proofpoint provides the capability for external users to send secure/encrypted s to EBS-RMSCO employees.

Snow Active Directory Discovery

Mapping ITS s File Server Folder to Mosaic Windows to Publish a Website

Using the SB Partners Client Web Portal

NetBrain Enterprise Edition 6.0a NetBrain Server Backup and Failover Setup

Terminal Four. Content Management System. Moderator Access

PaperStream Connect. Setup Guide. Version Copyright Fujitsu

How to Copy A SQL Database SQL Server Express (Making a History Company)

Does the GC have an online document management solution?


Oracle Database Express Edition

SECURE MOBILE ACCESS MODULE USER GUIDE EFT 2013

Using IIS and UltraDev Locally page 1

Technical Support Set-up Procedure

Use your UNNCNetID and password to log in. The first time you login to the system, you may receive the following screen:

Quick Start Guide. Installation and Setup

EDGETECH FTP SITE CUSTOMER & VENDOR ACCESS

IIS, FTP Server and Windows

How to create pop-up menus

STATISTICA VERSION 9 STATISTICA ENTERPRISE INSTALLATION INSTRUCTIONS FOR USE WITH TERMINAL SERVER

Tool Tip. SyAM Management Utilities and Non-Admin Domain Users

Secure Messaging Quick Reference Guide

Montefiore Portal Quick Reference Guide

Content Management System QUICK START GUIDE

Developing SQL and PL/SQL with JDeveloper

Setting up a Scheduled task to upload pupil records to ParentPay

MSSQL quick start guide

User Guide. UserGuide_VersionCS8.1

USC Marshall School of Business ShareFile_With_Outlook_Client_v2.docx 6/12/13 1 of 9

Previewing & Publishing

Transition from Pegasus Mail To Exchange/Outlook 2003

CDOT Workflow ProjectWise Web Access Operations

EBOX Digital Content Management System (CMS) User Guide For Site Owners & Administrators

D2L: An introduction to CONTENT University of Wisconsin-Parkside

TM Online Storage: StorageSync

Sentral servers provide a wide range of services to school networks.

Resource Guide INSTALL AND CONNECT TO CISCO ANYCONNECT VPN CLIENT (FOR WINDOWS COMPUTERS)

GUIDEWIRE. Introduction to Using WebMail. macrobatix. Learn how to: august 2008

Saving work in the CMS Edit an existing page Create a new page Create a side bar section... 4

Using Outlook Web Access

Fax User Guide 07/31/2014 USER GUIDE

BIGPOND ONLINE STORAGE USER GUIDE Issue August 2005

Lab: Data Backup and Recovery in Windows XP

Setting up a database for multi-user access

INFORMATION SYSTEMS SERVICE NETWORKS AND TELECOMMUNICATIONS SECTOR. User Guide for the RightFax Fax Service. Web Utility

College of William and Mary. wmfiles.wm.edu. A Reference and Training Guide

Patient Portal. Accessing the Patient Portal. How to Begin: Enter first and last name, date of birth and create a user name and password.

FTP, IIS, and Firewall Reference and Troubleshooting

Setting Up Your Team-SQL Database for ORACLE 8.05

VCW FTP Microsoft Outlook Add-In Configuration and Implementation

State of Michigan Data Exchange Gateway. Web-Interface Users Guide

BSDI Advanced Fitness & Wellness Software

WS_FTP Professional 12

SecureAware on IIS8 on Windows Server 2008/- 12 R2-64bit

Novo Nordisk Secure File Transfer User Guide

USING MYWEBSQL FIGURE 1: FIRST AUTHENTICATION LAYER (ENTER YOUR REGULAR SIMMONS USERNAME AND PASSWORD)

HR Onboarding Solution

Quick Start Guide for the SupportDesk Web Interface

STATISTICA VERSION 10 STATISTICA ENTERPRISE SERVER INSTALLATION INSTRUCTIONS

Installation Guide v3.0

COMMONWEALTH OF PA OFFICE OF ADMINISTRATION. Human Resource Development Division. SAP LSO-AE Desk Guide 15 T H J A N U A R Y,

BID2WIN Workshop. Advanced Report Writing

Installing a Browser Security Certificate for PowerChute Business Edition Agent

Installation Instruction STATISTICA Enterprise Small Business

Linko Software Express Edition Typical Installation Guide

Millennium Drive. Installation Guide

Setting up the Oracle Warehouse Builder Project. Topics. Overview. Purpose

VP-ASP Shopping Cart Quick Start (Free Version) Guide Version 6.50 March

MICROSTRATEGY 9.3 Supplement Files Setup Transaction Services for Dashboard and App Developers

MySQL Manager. User Guide. July 2012

Acunetix Web Vulnerability Scanner. Getting Started. By Acunetix Ltd.

Outlook Web Access (OWA) with Exchange Server 2007 (Windows version)

WinSCP: Secure File Transfer Using WinSCP for Secure File Transfer on Windows

Reference and Troubleshooting: FTP, IIS, and Firewall Information

Setting Up Database Security with Access 97

Outlook Web Access

REMOTE ACCESS - OUTLOOK WEB APP

Outlook Profile Setup Guide Exchange 2010 Quick Start and Detailed Instructions

STATISTICA VERSION 12 STATISTICA ENTERPRISE SMALL BUSINESS INSTALLATION INSTRUCTIONS

Lab - Data Backup and Recovery in Windows XP

UF Health SharePoint 2010 Introduction to Content Administration

Voice-Over PowerPoint (VOPP) and FTP Instructions for Online Courses (for Windows PC Computers) December 2009

Producing Standards Based Content with ToolBook

BUILDER 3.0 Installation Guide with Microsoft SQL Server 2005 Express Edition January 2008

USC Aiken CMS Manual. A manual on using the basic functions of the dotcms system. Office of Marketing and Community Relations-USC Aiken

Transcription:

Working with Oracle Database XE Create New User Account Using SQL Run Script Files PL/SQL Objects PL/SQL Server Pages Create New User Account Users access Oracle Database 10g Express Edition through database user accounts. Some of these accounts are automatically created as administrative accounts accounts with database administration privileges. You log in with these accounts to create and manage other user accounts, and to maintain database security. The installation process creates an account named SYSTEM. This account is considered an Administrator Account since it has DBA access. To institute Oracle s best practice, a user can create their own Administrator Account and Password, or any other account. Login with SYSTEM account and click the Administration icon arrow. Click the Database Users arrow. Click Create User option from the submenu. In the following screen enter the new user name, password, and assign some privileges (roles). The DBA checkbox provides the account with database administration privileges. Then click the Create button. A new database account has been created. Using SQL In Oracle Database XE, there are many ways to work with the SQL language. 1. Click the arrow attached to the SQL icon in the home page, select the SQL Commands arrow, and choose Enter Command from the associated submenu. In the SQL Command Web page, the screen is horizontally divided in two parts. In the top part enter the SQL or PL/SQL command, and then press the Run button to see the results in the bottom portion of the screen. 2. Click the arrow attached to SQL icon in the home page, select the Query Builder arrow, and choose Create from the associated submenu. In the Query Builder Web page, the left pane will show the tables. Select the table to view its graphical structure in the right pane. Relationships and attribute selection can then be accomplished. Press the Run button to see the results in the bottom portion of the right pane. 1

3. Click the arrow attached to SQL icon in the home page, select the SQL Scripts arrow, and choose Create from the associated submenu. Script Editor screen opens up. Enter the SQL statements and press Run button to execute. 4. SQL Command Line Go to the Start menu, select Programs (or All Programs), select Oracle Database 10g Express Edition program group, and choose Run SQL Command Line. This will open the SQL Editor in a Windows Prompt window. Start the session by connecting to the database using the command: connect userid/password Once the connected message appears, enter the SQL statement following the SQL prompt as in SQL Plus. To end session, enter exit or quit command. Run Script Files Click the SQL icon arrow. Select SQL Scripts arrow. In the associated submenu select the Upload option. Now, click the Browse button to select the script file to be uploaded. Enter the script name and press the Upload button. To run the script file, first click the script name in the next screen, and then once the script contents are displayed press the Run button. (You may be asked to press another Run button). Click the file results icon to see the results of script execution. PL/SQL Objects PL/SQL objects can be procedures, function, package, trigger, including tables, sequences, and so on. To create a PL/SQL object, in the home page, click the Object Browser arrow, select the Create arrow, and choose the nature of operation to perform from the associated submenu. Follow the graphical interface to complete the object. To modify existing PL/SQL object structures, in the home page, click the Object Browser arrow, select the Browse arrow, and choose the nature of operation to perform from the associated submenu. Follow the graphical interface to edit the object. 2

Run PL/SQL Programs To run a PL/SQL program like procedure, function, or package use the SQL Command page or SQL Command Line. To run a procedure create an anonymous block containing the procedure name as follows. procedure-name; For example, to run a procedure supplier_check, the anonymous block is: supplier_check; To run or test a function create an anonymous block containing a variable and have the function assigned to this variable as follows: Declare Variable datatype; Variable := function-name; dbms_output.put_line(variable); For example to test a function count_suppliers with one input parameter, the anonymous block is: Declare count_out number; count_out := count_suppliers(100); dbms_output.put_line(count_out); Of course, another way to test the above function is: dbms_output.put_line(count_suppliers(100)); 3

PL/SQL Server Pages Compose the PL/SQL server page in any HTML editor, and then run loadpsp command from the Windows command prompt window. Use the xe connect string. For example, loadpsp -replace -user userid/password@xe drive&path\??.psp Once the PSP has been loaded, it can be viewed/edited as a PL/SQL procedure object through the Object Browser option of the home page. To view the loaded PSP through the browser, a database access descriptor (DAD) has to be created. Database Access Descriptor (DAD) Setup The administration of Database Access Descriptors (DADs) is performed using the DBMS_EPG package. This package has procedures to create DAD, delete DAD, allow authorized access, and so on. Programs in this package can be run from the SQL Command Line. The CREATE_DAD procedure is used to create a DAD. It requires two parameters one for DAD name, and the other for associated virtual path. For example create a DAD named classpsp and its associated virtual path as follows: DBMS_EPG.create_dad('classpsp','/classpsp/*'); Now to access a PSP from the browser, the URL will be http://host:port/classpsp/userid.psp-procedurename The browser will prompt for userid password. The AUTHORIZE_DAD procedure is used to enable direct access to the specified user schema without the browser prompt for userid and password. For example, allow the classpsp DAD access to a user sam account as follows: DBMS_EPG.authorize_dad('classpsp','SAM'); The authorization can be reversed using the DEAUTHORIZE_DAD procedure as follows: DBMS_EPG.deauthorize_dad('classpsp','SAM'); 4

The DROP_DAD is used to remove an unwanted DAD. For example, drop the classpsp DAD as follows: DBMS_EPG.drop_dad('classpsp'); To enable viewing of images in a PSP through the browser create a Web (virtual) folder and then access those images through absolute path specifications. The Web (virtual) folder name as well as file names are case sensitive. Create a Web (virtual) folder 1. Go to My Network Places and start the "Add Network Place Wizard." 2. Select "Choose another network location", then 3. Click "Next" and follow the Wizard's prompts. 4. When prompted for an "Internet or network address", enter the URL http://127.0.0.1:8080/ to open Oracle XE home folder. Continue to follow the Wizard's prompts. The system will prompt for username and password. Enter the SYSTEM username and its corresponding password. Towards the end of wizard, enter a name to identify this Web (virtual) folder, eg. WEBSPACE. 5

5. Once the Wizard is finished,. your "My Network Places" window will contain a Web folder WEBSPACE. To access your WEBSPACE folder initially the system may prompt for DBA type username and password. 6. Now, within the home Web (virtual) folder, create a subfolder. Move files from hard drive to this new subfolder, and then access them directly through the browser or PSP procedure. For example, create a subfolder pspweb1, and paste an image file HalfDome.jpg in it. To access this image file from the browser enter the URL http://127.0.0.1:8080/pspweb1/halfdome.jpg. To access this image file from the pspweb1 subfolder within a PSP procedure, the absolute path will be /pspweb1/halfdome.jpg. If another subfolder pspclass1 is created inside pspweb1, and the image file HalfDome.jpg is pasted inside it, then to access the image from the browser, the URL is http://127.0.0.1:8080/pspweb1/pspclass1/halfdome.jpg. Now, to access this image file from the pspclass1 subfolder within a PSP procedure, the absolute path will be /pspweb1/pspclass1/halfdome.jpg. A sample PSP procedure with access to an image file in a Web (virtual) folder is as follows: create or replace PROCEDURE helloworld AS BEGIN NULL; htp.prn('<!doctype HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN"> '); htp.prn(' '); htp.prn(' <html> <head> <title>hello</title> </head> <body bgcolor="#ffffff"> <img src="/pspweb1/pspclass1/halfdome.jpg"> <p>hello World</p> </body> </html>'); END; 6

7