TAILIEUCHUNG - Oracle Unleashed- P22

Oracle Unleashed- P22: When I first started using Oracle many years ago, it was possible to know the database and the tools available. With the rash of recent releases of different options for the database and the spate of new tools, only people who wear their underpants over their trousers will be able to know everything there is to know about the Oracle products. | The methods of the Database object are used to retrieve results apply SQL transactions and call stored procedures. In most cases the application should declare one Database object globally. The primary means of retrieving results from an ODBC data source is the Snapshot object. The Snapshot object is created using the CreateSnapshot method of the Database object. The CreateSnapshot method takes two arguments a SQL SELECT statement and a numeric constant used to control processing of the SQL. Unless the application needs to be portable to different RDBMSs this numeric constant should be set to DB_SQLPASSTHROUGH 64 which sends the statement directly to the server for processing. This mode allows the developer to use the native syntax of the RDBMS and prevents the local Microsoft Access engine from attempting to parse and process the SQL. The following code fragment provides a simple example of the use of the CreateSnapshot method Dim dsContacts As Snapshot Set dsContacts SELECT a. first_name FROM individual a phone b WHERE ORDER BY 1 2 DB_SQLPASSTHROUGH The example assumes that the Database object has already connected to the data source. Note that if DB_SQLPASSTHROUGH is not specified a syntax error results because the local Access engine attempts to parse the SQL and does not recognize the outer join syntax. After applying the SQL and creating the result set there are numerous methods that can be applied to position the record pointer in the cursor. The MoveFirst MoveLast MoveNext and MovePrevious methods are the most commonly used and their purposes should be self-explanatory. Visual Basic provides the additional method FindFirst to position the record pointer at the first record matching specific criteria. For example assuming that the record pointer is positioned at the first record the following line would find the first individual with the last name Smith based on the result set returned by .

TỪ KHÓA LIÊN QUAN
Đã phát hiện trình chặn quảng cáo AdBlock
Trang web này phụ thuộc vào doanh thu từ số lần hiển thị quảng cáo để tồn tại. Vui lòng tắt trình chặn quảng cáo của bạn hoặc tạm dừng tính năng chặn quảng cáo cho trang web này.