Skip Headers

Oracle® Objects for OLE Developer's Guide
10g Release 1 (10.1)

Part Number B10118-01
Go to Documentation Home
Home
Go to Book List
Book List
Go to Table of Contents
Contents
Go to Master Index
Master Index
Go to Feedback page
Feedback

Accessing Attributes of an Embedded/Value Instance

Individual attributes can be accessed by using a subscript or the name of the attribute. The following example illustrates how to access attribute values of ADDRESS object instance

set OO4OSession = CreateObject("OracleInProcServer.XOraSession")

set hrDb = OO4OSession.OpenDatabase("ExampleDb", "scott/tiger", 0)

set Person = hrDb.CreateDynaset("select * from person", 0&)

set Address = Person.Fields("Addr").Value

msgbox Address.City

msgbox Address.Street

msgbox Address.State

msgbox Address.Zip

This code accesses all of the attribute values:

For I=1 to Address.Count

msgbox Address(I)

Next I