搜尋此網誌

2013年4月22日 星期一

[Form] 使用Form Bulider 客製程式的前置作業及編譯指令

使用Form客製程式的前置作業及編譯指令

[前置作業]
1. 於本機建立資料夾ORACLE_LIB
2. 下載Oracle ERP的Library, 路徑: $AU_TOP/resource 下所有檔案置於本機資料夾 ORACLE_LIB
3. 下載Menu檔, 路徑: $AU_TOP/resource/US
       FNDMENU.mmx
       FNDMENU.mmb
   置於本機資料夾 ORACLE_LIB
4. 下載TEMPLATE Form, 路徑: $AU_TOP/forms/US
       TEMPLATE.fmb
       APP*.fmb
       APS*.fmb
       FND*.fmb
   置於本機資料夾 ORACLE_LIB
5. 編輯環境變數Patch, 若ORACLE_LIB位於D槽下, 即內容加上 D:\ORACLE_LIB\
6. 執行regedit, 搜尋Forms_Patch, 若ORACLE_LIB位於D槽下, 即內容加上 D:\ORACLE_LIB\

[程式放置處]
$AU_TOP/forms/US

[編譯程式]
(1)連入主機後先下以下指令: cd $AU_TOP/forms/US
(2)執行編譯:
   $ORACLE_HOME/bin/frmcmp_batch module=$AU_TOP/forms/US/XXXINVF007.fmb userid=APPS/APPS output_file=$HOPAX_TOP/forms/US/XXXINVF007.fmx module_type=form batch=NO compile_all=special
   (紅色部份為程式名, 依情況做修改即可)

2013年3月19日 星期二

[SQL] 用PIVOT讓資料呈現類似Excel的樞鈕分析

Oracle 11g的功能, 用PIVOT讓資料呈現類似Excel的樞鈕分析

SELECT TO_CHAR(INVOICE_DATE, 'YYYY/MM') YYMM, INVOICE_CURRENCY_CODE, SUM(INVOICE_AMOUNT) INVOICE_AMOUNT
  FROM AP_INVOICES_ALL
 WHERE TO_CHAR(INVOICE_DATE, 'yyyymm') BETWEEN '201201' AND '201203'
   AND SET_OF_BOOKS_ID = ***
 GROUP BY TO_CHAR(INVOICE_DATE, 'YYYY/MM'), INVOICE_CURRENCY_CODE
 ORDER BY TO_CHAR(INVOICE_DATE, 'YYYY/MM'), INVOICE_CURRENCY_CODE;



[利用PIVOT]
SELECT *
  FROM (
        SELECT TO_CHAR(INVOICE_DATE, 'yyyy/mm') YYMM, INVOICE_CURRENCY_CODE, SUM(INVOICE_AMOUNT) INVOICE_AMOUNT
          FROM AP_INVOICES_ALL
         WHERE TO_CHAR(INVOICE_DATE, 'yyyymm') BETWEEN '201201' AND '201203'
           AND SET_OF_BOOKS_ID = ***
         GROUP BY TO_CHAR(INVOICE_DATE, 'yyyy/mm'), INVOICE_CURRENCY_CODE
       )
PIVOT(SUM(INVOICE_AMOUNT) FOR YYMM IN ('2012/01', '2012/02', '2012/03'))
ORDER BY INVOICE_CURRENCY_CODE;




2013年1月23日 星期三

[AP]AWT(Withholding Tax) 於付款時計算稅額錯誤

Withholding Tax設定
Apply Withholding Tax : At Payment Time

支付一張invoice 金額為 IDR 120,000,000,於付款時產生會計算10% Withholding Tax, 此筆Withholding Tax應為 IDR 12,000,000,但卻跑出IDR 999,999的資料來。

再檢示設定才發現Period Limit設定太小了,算出的Withholding Tax大於上限,系統則以上限做為該筆的Withholding Tax,修改後計算出的Withholding Tax才正確。

2012年10月1日 星期一

[Form]關於Tree的注意事項

最近有機會實際研究Hierarchical Tree,Tree的做法很多種,在網路可搜尋到作法,有個要點要特別注意,就是關於資料的設計上,要讓它能呈現出階層結構。

比較下面的2組資料就能知道何者更能呈現出Hierarchical Tree的結構來。
ID
NAME
1
A
2
B
3
C
4
D
5
E
ID
NAME
MANAGER ID
1
A

2
B
1
3
C

4
D
3
5
E
3


2012年9月30日 星期日

[Report]Oracle EBS客製報表讀取圖檔

Step:
1.create a Formula Column, ex: CF_PICTURE
2.set the property : Read from File => Yes
                              File Format => Image
3.CF_PICTURE's PL/SQL Formula returns the full path of image file
4.put a field on the layout, its source => CF_PICTURE
5.put the image file and report in the same folder

2012年8月13日 星期一

[AR][Setting] 進DB修改Flexfield造成錯誤訊息

前陣子發生件事,在AR設定時使用Flexfield來設定Country(路徑為:Receivables Responsibility-> Setup-> Financials-> Flexfields-> Key-> Values),設定人A將Hong Kong設成Hong Kon,後來被B同事發現有錯,通常Flexfield的Value一經設定後就不能修改,所以B同事便進入DB內將Hong Kon update成Hong Kong。
後來USER反應在AR的Transactions->Transactions內查詢資料時都會出現下圖的訊息,

經過協助才找到原來RA_TERRITORIES裡也存有相關資料而且存的是Name(或稱Code)而非ID,因該table的資料沒一起修改,造成查詢時都出現訊息。

所以,千萬不要自行至DB修改資料,你永遠不會知道是否修改完全,是否會造成另一隻程式出現訊息。

2012年8月8日 星期三

[AP] Why "View journal entries" display nothing?

近日user對於某張被cancel 的 Invoice於Create Accounting後,View journal entries但無任何Subledger Journal Entry 的detail資料顯示感到疑惑。

依以下步驟檢示設定,並配合Oracle Support的解釋,就能了解為何 "View journal entries"看不到journal lines 的資料。

a)      Subledger Accounting Options
GL Responsibility->Setup->Accounting Setup Manager->Accounting Setups
1) Choose the ledger
2) Click on "Update Accounting Options"
3) Scroll to “Subledger Accounting Options” in the Primary Ledger section
4) Click on Update Icon
5) Click on “Update Accounting Options” Icon against the Application to be setup(Example: Payables)
6) Field: General Ledger Journal Entry Summarization
Ans:General Ledger Journal Entry Summarization= Group by GL Date
b)      Journal Line Types
Payables Responsibility->Setup->Accounting Setups-> Subledger Accounting Setup->Accounting Methods Builder->Journal Entry Setups-> Journal Line Types
1) Application to be setup(Example: Payables)
2) Field: Transfer to GL
Ans:Transfer to GL= ‘Summary’
c)      Profile : "SLA: Show Zero Amount Journal Lines"
System administrator Responsibility->Profile->System
1) Enter Application : Payables
2) Responsibility: Your responsibility(Example: Payables)
3) Profile : "SLA: Show Zero Amount Journal Lines"
4) Click Find
Ans:SLA: Show Zero Amount Journal Lines=> Site level = ‘No’

Oracle Support's Explanation & Solutions
1. "SLA: Show Zero Amount Journal Lines" is control if you can view the journal lines with 0 amount.

Here in your case , you set it at Site level to No, which means once the journal lines with 0 amount, you cannot view it in page.

2.You also has below setups:
General Ledger Journal Entry Summarization :Group by GL Date
Transfer to GL : Summary

Which means the journal lines transferred will be in summary mode which means , your journal lines will be summarized together grouped by GL Date.

So in your case , as the invoice lines has been discarded, and the GL date is all the same, so when you create accounting, the journal lines summarized by the GL date will has the total amount with 0.
And as your 1 setup, the 0 amount journal line will not be displayed.

That is why you can not view the journal lines for this invoice.
===
So for your confirmation, you can set the "SLA: Show Zero Amount Journal Lines" to Yes and see if you can view journal with 0 amount.
Or transfer to GL in details.