-1
私は直前に同じようなポストを参照しましたが、同じORA & PLS
エラー提供されたソリューションを使用して解決してください。PLSQL - PLS-00103:次のいずれかを予期しているときにシンボル "end-of-file"が検出されました:begin function pragma procedure
このコードは、テーブルPRODUCT_MASTER
から最小&の製品コードを得るように構成されています。
nohupをSQLPLUSのID/PWDの@ extract_pmf.sql 1 500001 &
マイコード:
- :そして、そこから私は、以下のサンプルのように(&最大最小)バッチによって、これらすべてのデータを取得するためにsqlplus
を実行します
SET ECHO ON TIME ON TIMING ON SERVEROUTPUT ON
SPOOL EXTRACT_PMF.LOG
DECLARE PROCEDURE EXTRACT_PMF(P_MIN IN INTEGER, P_MAX IN INTEGER) AS
CURSOR C_SQL IS
SELECT
PD_PRODUCT.SA_SRV_AREA_CODE,
PD_PRODUCT.CO_CTRY_CODE,
PD_PRODUCT.UM_UNIT_OF_MEASURE,
PD_PRODUCT.US_UNIT_OF_MEAS_SYSTEM,
PD_PRODUCT.PD_TYPE,
PD_PRODUCT.PD_DESCRIPTION,
PD_PRODUCT.PD_PART_NUMBER,
PD_PRODUCT.PD_TARF_CODE,
PD_PRODUCT.PD_EXCISE_CODE,
TO_CHAR(PD_PRODUCT.PD_CRTD_DATE,'MM/DD/YYYY') CRTD_DATE,
PL_PROD_IN_A_LANGUAGE.LA_LANG_CODE,
PL_PROD_IN_A_LANGUAGE.PL_PROD_DESCRIPTION,
CU_CUSTOMER.CU_CUST_IMPT_ID,
A.PS_STU as STU1,
A.UM_UNIT_OF_MEASURE as UOM1,
B.PS_STU as STU2,
B.UM_UNIT_OF_MEASURE as UOM2,
C.PS_STU as STU3,
C.UM_UNIT_OF_MEASURE as UOM3,
D.PS_STU as STU4,
D.UM_UNIT_OF_MEASURE as UOM4,
E.PS_STU as STU5,
E.UM_UNIT_OF_MEASURE as UOM5,
F.PS_STU as STU6,
F.UM_UNIT_OF_MEASURE as UOM6,
G.PS_STU as STU7,
G.UM_UNIT_OF_MEASURE as UOM7,
H.PS_STU as STU8,
H.UM_UNIT_OF_MEASURE as UOM8,
I.PS_STU as STU9,
I.UM_UNIT_OF_MEASURE as UOM9,
J.PS_STU as STU10,
J.UM_UNIT_OF_MEASURE as UOM10,
PD_PRODUCT.PD_ECCN
FROM
PD_PRODUCT
LEFT OUTER JOIN PL_PROD_IN_A_LANGUAGE ON PD_PRODUCT.PD_PROD_CODE = PL_PROD_IN_A_LANGUAGE.PD_PROD_CODE
LEFT OUTER JOIN CP_CUST_PRODUCT ON CP_CUST_PRODUCT.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE
LEFT OUTER JOIN CU_CUSTOMER ON CU_CUSTOMER.CU_CUST_IDENTIFIER = CP_CUST_PRODUCT.CU_CUST_IDENTIFIER
AND CU_CUSTOMER.CU_DELETE_IND <> 'Y'
LEFT JOIN PS_PRODUCT_STU A ON A.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND A.PD_STU_IDENTIFIER = 1
LEFT JOIN PS_PRODUCT_STU B ON B.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND B.PD_STU_IDENTIFIER = 2
LEFT JOIN PS_PRODUCT_STU C ON C.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND C.PD_STU_IDENTIFIER = 3
LEFT JOIN PS_PRODUCT_STU D ON D.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND D.PD_STU_IDENTIFIER = 4
LEFT JOIN PS_PRODUCT_STU E ON E.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND E.PD_STU_IDENTIFIER = 5
LEFT JOIN PS_PRODUCT_STU F ON F.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND F.PD_STU_IDENTIFIER = 6
LEFT JOIN PS_PRODUCT_STU G ON G.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND G.PD_STU_IDENTIFIER = 7
LEFT JOIN PS_PRODUCT_STU H ON H.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND H.PD_STU_IDENTIFIER = 8
LEFT JOIN PS_PRODUCT_STU I ON I.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND I.PD_STU_IDENTIFIER = 9
LEFT JOIN PS_PRODUCT_STU J ON J.PD_PROD_CODE = PD_PRODUCT.PD_PROD_CODE AND J.PD_STU_IDENTIFIER = 10
LEFT OUTER JOIN AC_ACCOUNT ON CU_CUSTOMER.CU_CUST_IDENTIFIER = AC_ACCOUNT.CU_CUST_IDENTIFIER
WHERE PD_PRODUCT.PD_PROD_CODE IN (SELECT PD_PROD_CODE FROM PD_PRODUCT WHERE CO_CTRY_CODE = 'SG')
AND PD.PRODUCT.PD_PROD_CODE BETWEEN P_MIN AND P_MAX
AND PD_PRODUCT.PD_DELETE_IND <> 'Y';
BEGIN
EXTRACT_PMF(&1, &2);
END EXTRACT_PMF;
/
EXIT
エラーログ:1行目
ERROR:ORA-06550:行38、列0:PLS-00103:遭遇 SYM次のいずれかが必要な場合は、「ファイルの終わり」を表示してください。 関数プラグマプロシージャ
おかげAleksej、私は出力にDBMS_OUTPUTを含むことにより、フィールドを更新やったが、残念ながらそれはポスト以下のように出ていませんでした。助言してもらえますか? – Eizu
はコードを簡素化します。 1つのフィールドで簡単なクエリを開始し、何が起こるかを確認してください – Aleksej