Skip to main content

SAL and SQL Functions

Supported SAL functions are available in the PPJ.Runtime.Sal class as static methods. The names are all unchanged, except that the Sal prefix has been removed and it is now the name of the class: SalStrLeft() is now Sal.StrLeft().

Supported SQL functions are exposed by the Sql class in the PPJ SQL namespace.

Sql global variables SqlDatabase, SqlUser and SqlPassword are static fields of the Sql class, with the "Sql" prefix removed. For example, SqlDatabase is ported to Sql.Database.

Renamed functions

For name consistency reasons we have renamed few Sal functions that did not fit any naming pattern or the name did not seem to be complete. Renaming has been performed automatically by Ice Porter conversion tool.

Old nameNew name
SalQueryArrayBoundsSal.ArrayQueryBounds
SalSetArrayBoundsSal.ArraySetBounds
SalFileGetCSal.FileGetChar
SalFilePutCSal.FilePutChar
SalStrFirstCSal.StrFirstChar
SqlPLSQLCommandSql.OraPLSQLCommand

Unsupported functions

Some functions cannot be supported in the .NET environment because of some fundamental differences with Team Developer. Some SAL runtime operations depend on the source environment's execution and windowing model and have no direct PPJ implementation. Review those operations individually rather than attributing every limitation to compilation.

Unsupported functionReplacement
SalMTSGetObjectContextReview the original MTS/COM+ transaction integration; there is no direct mapping listed here.
SalValidateSetThere is no replacement, it can be ignored.
SalContextBreakThere is no replacement.
SalFileOpenExtObsolete compatibility stub; use Sal.FileOpen and redesign any reopen-buffer logic.
SalLogResourceObsolete compatibility stub; use supported diagnostics such as Sal.Log for the intended information.
SalYieldEnableAll Yielding functionality has to be replaced to use one single function: Sal.Yield(target). This is similar to Application.DoEvents(). The new Sal.Yield() function should be placed inside the loop that it's supposed to yield from.
SalYieldQueryState"
SalYieldStartMessages"
SalYieldStopMessages"
SalFontGetSizesThere is no replacement. Review the required font enumeration behavior on the target platform.
SqlConnectTransationThere is no replacement.
SqlConnectUsingCursorThere is no replacement. There is no direct PPJ mapping for this legacy cursor operation; provider-specific cursor features are a separate concern.
SqlDisconnectWithoutCursorThere is no replacement. There is no direct PPJ mapping for this legacy cursor operation; provider-specific cursor features are a separate concern.
SqlSetLongBindDatatypeThere is no replacement. It can be ignored.
SqlExecutionPlanThere is no replacement.
SqlGetCursorThere is no replacement. The SQL/API library is not used by ADO.NET.
SqlGetSqlHandleThere is no replacement.
SqlSetInMessageThere is no replacement in code. The specific ADO.NET driver may support a parameter in the connection string that alters the size of the IN buffer.
SqlSetOutMessageThere is no replacement in code. The specific ADO.NET driver may support a parameter in the connection string that alters the size of the OUT buffer.
SqlXDirectoryThere is no replacement.
SqlOraPLSQLStringBindTypeThere is no replacement. It can be ignored.
SqlGetCmdOrRowsetPtrThere is no replacement.
SqlGetDSOrSessionPtrThere is no replacement.
SqlCloseThere is no replacement. There is no direct PPJ mapping for this legacy cursor operation; provider-specific cursor features are a separate concern.
SqlDropStoredCmdThere is no replacement.
SqlGetRollbackFlagThere is no replacement.
SqlOpenThere is no replacement. There is no direct PPJ mapping for this legacy cursor operation; provider-specific cursor features are a separate concern.
SqlStoreUse Sql Prepare.
SqlGetParameterAllUse Sql.GetParameter.
SqlSetParameterAllUse Sql.SetParameter.
SalActiveXCloseThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveX Create*There is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveX DeleteThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveXGetActiveObjectThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveXGetDataThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveXGetFileNameThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveXInsertObjectDlgThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveXGetProgIDThere is no replacement. The PPJ adapter does not implement this OLE embedding operation.
SalActiveXOLETypeReplace with the value 4 (salOLEControl).

Sal.FormGetParmNum is implemented in the desktop runtime and must not be classified as unsupported. It queries form dimensions or page count through the requested FORM_* parameter; it is not a function-argument inspection API.

ActiveX/OLE Support

The PPJ Framework supports ActiveX controls, not OLE objects through its desktop hosting layer. General OLE document embedding requires a separate integration.

Difference in behavior

One of our first priorities is to maintain the closest possible compatibility with the known behavior of the Team Developer functions and the equivalent PPJ Framework functions.

However, there may be several cases (mostly in extreme situations or unknown combinations of arguments) where the fundamental behavior of the ported functions is different from the original Team Developer functions. There may also be cases where different versions of Team Developer show different behaviors.

Object Oriented transformations

Depending on the personalized settings used in Ice Porter for the generation of the ported project, some Sal functions may have been transformed into Object Oriented calls.

The transformation is applied to all the data-type-related functions. That is all SalStr, SalDate, SalNumber, Sql and File handling functions. When possible, the last receive argument has also been moved to the beginning of the expression and the expression has been changed to an assignment.

For example:

SalStrLeftX(strName, 5, strName)

May have been ported to:

strName = strName.Left(5);

Interpreting the Compatibility List

This list records historical conversion gaps, not an exhaustive API compatibility matrix. Review each unsupported call's purpose before removing it. Calls described as ignorable can still encode a business or platform assumption.

Yielding processes other UI work and can cause reentrancy. Do not insert yields inside partially completed state changes or assume they provide background execution. See Issues & Workarounds.