attach.makket.com

.NET/ASP.NET/C#/VB.NET PDF Document SDK

The DBA_FREE_SPACE view tells you how much free space you have in the database at any given moment. You can use the query in Listing 23-15 to find out how much free space you have in your tablespaces. Note that space belonging to a table that you dropped, and is in the Recycle Bin, shows up as free space in this view. However, you can t use it for any other object. You get the space back only after you permanently remove the item with the ALTER TABLE . . . PURGE statement. Listing 23-15. Querying the DBA_FREE_SPACE View SQL> SELECT tablespace_name, SUM(bytes) 2 FROM DBA_FREE_SPACE 3* GROUP BY tablespace_name; TABLESPACE_NAME SUM(BYTES) ------------------------------ ---------CWMLITE 11141120 DRSYS 10813440 EXAMPLE 262144 INDX 26148864 ODM 11206656 SYSTEM 4325376 TOOLS 4128768 UNDOTBS1 202047488 USERS 26148864 XDB 196608 10 rows selected. SQL>

free barcode generator excel 2013, free 2d barcode generator excel, create barcode in excel 2010 free, barcode excel vba free, free download barcode font excel, barcodes excel 2010 free, how to create a barcode in excel 2007, free online barcode generator excel, barcode add in for excel free, excel barcode font free,

As you re aware, the Oracle database contains several kinds of segments: table, index, undo, and so on. The DBA_SEGMENTS view provides you with detailed information on the various segments in the database, as seen in the example in Listing 23-16. Listing 23-16. Querying the DBA_SEGMENTS View SQL> 2 3 4 5 6 7 8 9* SELECT tablespace_name, segment_name, segment_type, extents, /*Number of extents in the segment*/ blocks, /*Number of db blocks in the segment*/ bytes /*Number of bytes in the segment*/ FROM dba_segments WHERE owner = 'HR'; SEGMENT_NAME SEGMENT_TYPE EXTENTS BLOCKS BYTES ------------ ------------- ------- ------ -----REGIONS TABLE 1 8 65,536 LOCATIONS TABLE 1 8 65,536 DEPARTMENTS TABLE 1 8 65,536 JOBS TABLE 1 8 65,536 EMPLOYEES TABLE 1 8 65,536 JOB_HISTORY TABLE 1 8 65,536 REG_ID_PK INDEX 1 8 65,536

EXAMPLE COUNTRY_PK EXAMPLE LOC_ID_PK EXAMPLE DEPT_ID_PK EXAMPLE DEPT_LOC_IX . . . 25 rows selected. SQL>

1 1 1 1

The first example represents a string comparison and the second an integer test. The quotation marks are required only for an explicit string. Quotation marks around the name of a string variable are not required. It is wise, however, to always quote your string variables to gracefully handle an undefined variable or white space within the string. A comparison involving an unquoted, undefined string variable in the bash shell will return a unary operator expected error, whereas ksh will return an argument expected message. A comparison involving an unquoted string that contains white space will result in a too many arguments error in bash and an unknown operator in ksh. All of these errors are related to the test command finding that there are too few or too many arguments in the comparison too few because an unquoted null

} } }; } // namespace msclr The auto_handle template implements a special constructor that expects a T^ parameter. auto_handle( T^ _handle ) : m_handle( _handle ) { } In the sample code just shown, this constructor is used to initialize a new auto_handle from the FileStream^ tracking handle returned by the function GetFile. msclr::auto_handle<FileStream> fs = GetFile(); Once you have created an auto_handle, you will likely want to operate on the wrapped tracking handle. To obtain the wrapped tracking handle from an auto_handle, you can call the get function: { msclr::auto_handle<FileStream> ah = GetFile(); FileStream^ fs = ah.get(); long long fileLength = fs->Length; } Using the handle returned from get can be dangerous. When the auto_handle destructor is executed before you access the wrapped object via the handle returned by get, you will likely access a disposed object. The auto_handle template overloads the member selection operator (operator ->), which allows you to access members of the wrapped object. Instead of calling get to receive the wrapped tracking handle, as in the preceding code, you could also write this more simple code: { msclr::auto_handle<FileStream> fs = GetFile(); long long fileLength = fs->Length; } Not only is this code more elegant, but using the member selection operator also reduces the risk of accessing a disposed object. If you call get to store the wrapped tracking handle in a variable that is defined in another scope than the auto_handle variable, it is possible that the tracking handle will be used after the auto_handle is destroyed. In contrast to that, the member selection operator can only be used while the auto_handle variable is in scope.

8 8 8 8

65,536 65,536 65,536 65,536

   Copyright 2020.