ODBC Driver for Sage 300

Build 23.0.8839

データのクエリ

接続 後、SQL ステートメントを実行して結果を取得できます。

SELECT プロシージャ

odbc_exec を使用してクエリを実行できます。これにより、結果を読むために使用できるリソースが返されます。

$stmt = odbc_exec($cnx, "SELECT InvoiceUniquifier, ApprovedLimit FROM OEInvoices WHERE Allowpartialshipments = 'Yes'");

結果の反復処理

odbc_fetch_array を使用して次の行を配列としてフェッチできます。

while ($row = odbc_fetch_array($stmt)) {
    echo "InvoiceUniquifier = ", $row["InvoiceUniquifier"], "\n";
    echo "ApprovedLimit = ", $row["ApprovedLimit"], "\n";
}

Copyright (c) 2024 CData Software, Inc. - All rights reserved.
Build 23.0.8839