prime.javabarcode.com | ||
ASP.NET PDF Viewer using C#, VB/NETSo far, I have discussed P/Invoke metadata and thunks only from a performance point of view. If you call managed functions in a context that is not performance critical, you probably prefer convenience over performance. C++/CLI interoperability already provides a lot of convenience you only need normal function declarations to call a managed function from native code. However, depending on the argument types of the target method, it is still possible that you have to write some code yourself to marshal managed types to native argument types manually. In the following code sample, the managed class System:Environment is used to get the name of the user that executes the current thread. To pass the content of the managed string returned by Environment::UserName to a function like MessageBoxA, which expects a native null-terminated ANSI code string, the managed string must be marshaled first. Therefore, Marshal::StringToCoTaskMemAnsi is called. To clean up the native string returned by Marshal::StringToCoTaskMemAnsi, the helper function Marshal::FreeCoTaskMem is used: // ManualMarshaling.cpp // build with "CL /clr ManualMarshaling.cpp" #include <windows.h> #pragma comment(lib, "user32.lib") using namespace System; using namespace System::Runtime::InteropServices; int main() { String^ strUserName = Environment::UserName; IntPtr iptrUserName = Marshal::StringToCoTaskMemAnsi(strUserName); const char* szUserName = static_cast<const char*>(iptrUserName.ToPointer()); MessageBoxA(NULL, szUserName, "Current User", 0); Marshal::FreeCoTaskMem(iptrUserName); } barcode wizard excel, barcode generator in excel 2007 free download, barcode activex control for excel free download, convert text to barcode in excel 2013, barcode excel 2010 gratis, barcode font for excel 2010, download barcode font for excel 2010, using barcode in excel 2010, how to install barcode font in excel 2010, barcode add-in for word and excel 2010,This chapter introduced you to the main features of SQL*Plus and iSQL*Plus, which continue to be heavily used interfaces for day-to-day DBA work, even if you use the OEM Database Control as the main DBA tool for administering databases. For several reasons, including redundancy, several of the regular SQL*Plus commands do not work in the iSQL*Plus environment. The following are some of the important commands that you can t use in the iSQL*Plus environment: APPEND, DELETE, CHANGE, EDIT, INPUT, EXIT, QUIT, GET, HOST, SAVE, SPOOL, STORE, FLUSH, NEWPAGE, PAUSE, SQLPROMPT, TAB, TERMOUT, TRIMOUT, and TRIMSPOOL. Although you may be disappointed to see that so many of your old standby SQL*Plus commands are unavailable, the iSQL*Plus environment does give you a better display and capabilities for web reporting, which compensates for the drawbacks. This slight modification of the earlier example eliminates the need for a temporary file. Instead of redirecting a file into the back of the loop, we start a here-document and feed it the data we want to process through the loop. A here-document is where the shell reads input from the current source until it reaches the matching tag alone on a single line, in this case EOF. This solution works in the same way as a real file with both bash and pdksh. The following sections show four methods for reading input one line at a time. With each method, I explain what variables are available within the code for each of the four shells (bash, ksh, pdksh, and Bourne sh). ne of your most common tasks as a DBA is loading data from external sources. Although you normally do this when you first populate a database, you frequently need to load data into various tables throughout the life of a production database. Traditionally, DBAs have used the SQL*Loader utility to load data from flat files into the Oracle database tables. Although SQL*Loader has always been an important tool for loading data into Oracle databases, Oracle also provides another way to load tables: using the external tables feature. External tables use SQL*Loader functionality and let you perform complex transformations on data before loading it into the database. Not only can you load data into your database, but with Oracle Database 10g, you can also unload data into external files. You can then use these files to load data into other Oracle databases. In many cases, especially in data warehouses, you need to transform the data you load. Oracle provides several means of performing data transformation within the database, including SQL and PL/SQL techniques. Additionally, Oracle Database 10g introduces the powerful MODEL clause, which enables you to create sophisticated multidimensional arrays and conduct complex interrow and interarray calculations, using simple SQL. Oracle provides a useful data replication feature called Oracle Streams, which lets you propagate changes from one database to another. You can use the Streams feature for various purposes, including the maintenance of a standby database. This chapter covers all of these topics related to loading and transforming data. First, it provides an overview of the extraction, transformation, and loading process.
|