Query for retrieving GL accounts in AR & AP

Hi,
I need to get the GL accounts for all the customers & suppliers.
Do you know the tables contained this information?
Thank you

Hello
+Dear all,
How could I transfer opening balance for all GL. AR, AP accounts before system go libe ?
Thank you very much,
Kindly regards,
Sylvecast+
Ideally, One journal entry for all GL accounts is advisable. Open a clearing account. Debit all GL balances and credit the clearing account. For credit balances, debit the clearing account and credit the GL accounts.
For open items in AR and AP use LSMW tool, this would take care of the postings to recon accounts also.
For asset balances, depreciation balances use the LSMW tool. For any other balances, ensure credit or debit to the clearing account, like opening stocks etc.
At the end of the process, ensure clearing account is zeroed
Reg
assign points if useful

Similar Messages

  • Query for Price difference account when item is not sold but not on stock

    Hi Experts!
    One of my clients accountant requires a report which will help for what to do with the balance of the price difference account.
    At the and of the year there are some postings on this account, but not every item that hadnt been on stock when A/P Invoice arrived were sold. Some item were waistrel and put into a waistrel warehouse, but not sold.Some item were sent back to the supplier, but not sold.
    Is it possibble to make a query for knowing where to post the balance of the price difference account? Not all should be post to the Cost of goods sold.
    Thank you in advance!

    Hi,
    The query is possible.  However, it is a complicated one. It is also need to involve detailed analysis to your transaction histories.  You may start from OINM table to check.
    Thanks,
    Gordon

  • Hierarchical Query for Chart of Account

    Hellow all
    I have one Table which is for chart of account
    The Column in this Table is
    Acc_id and Acc_name
    I Insert data in This chart of account
    Insert into COA
    values
    *(01,'ASSETS');*
    values
    *(01001,'Current Assets');*
    values
    *(01002,'Fixed Assets');*
    values
    *(010010001,'Banks');*
    values
    *(010010002,'Cash');*
    values
    *(01001000100001,'Metrol Politan Bank');*
    values
    *(01001000100002,'Royal Bank');*
    values
    *(01001000100003,'Stander Charted Bank');*
    values
    *(01001000200001,'Cash in Hand');*
    values
    *(01001000200002,'Patty Cash');*
    That's all my record now i need to create a Hierarchical tree
    Which look like this
    *01- Assets*
    ------010001 Current Assets+
    ----------010010001 Bank+
    --------------01001000100001 Metrol Politan Bank+
    --------------01001000100002 Royal Bank+
    --------------01001000100003 Stander Charted Bank+
    ----------010010002 Cash+
    --------------01001000200001 Cash in Hand+
    --------------01001000200002 Patty Cash+
    ------010002 Fixed Assets+
    ----------010020001 Machinery Assets+
    --------------01002000100001 Needle Machine+
    --------------01002000100002 GGT Machine+
    ----------010020002 Computer Assets+
    --------------01002000200001 Computer Server+
    --------------01002000200002 Computer other+
    Hope you guys understand i need the Hierarchical query for making this kind of Tree
    Regards
    Shahzaib

    In above posts you have solution to your problem but maybe you can think about changeing the design slightly.
    I would suggest using parent_id to find parent account, instead of operations on strings which can be slower in larger tables.
    SQL> create table t14(id int, account_code varchar2(16), account_name varchar2(32), parent_id int)
      2  /
    Table created.
    SQL> insert into t14 values(1,'01','Assets',null);
    1 row created.
    SQL> insert into t14 values(2,'01001','Current Assets',1);
    1 row created.
    SQL> insert into t14 values(3,'01002','Current Assets',1);
    1 row created.
    SQL> commit;
    Commit complete.
    SQL> select * from t14;
            ID ACCOUNT_CODE     ACCOUNT_NAME                      PARENT_ID
             1 01               Assets
             2 01001            Current Assets                            1
             3 01002            Current Assets                            1
    SQL> select lpad(' ',2*(level-1)) || account_code as account_code, account_name
      2  from t14
      3  start with parent_id is null connect by prior id = parent_id
      4  /
    ACCOUNT_CODE                   ACCOUNT_NAME
    01                             Assets
      01001                        Current Assets
      01002                        Current AssetsWith kind regards
    Krystian Zieja

  • How to modify select query for retrieve assets from assets tab and assets in merchandising in 10.1.2?

    Hi All,
          I need to modify the SQL for retrieving assets from assets tab and assets in merchandising in 10.1.2. I found the class for SQLQuery builder, but I want to change the SQL.
          Could you anyone please how to solve this.
    Thanks & Regards,
    Bala

    Hi All,
          I need to modify the SQL for retrieving assets from assets tab and assets in merchandising in 10.1.2. I found the class for SQLQuery builder, but I want to change the SQL.
          Could you anyone please how to solve this.
    Thanks & Regards,
    Bala

  • Query for chart of accounts

    SELECT    T0.DocEntry, T0.DocNum, T0.Series, T0.PostDate, T0.DueDate,
    T0.ItemCode AS Parent,T0.PlannedQty, T0.CmpltQty, T0.RjctQty,
    T1.ItemCode AS CHLD, T1.BaseQTY, T1.PlannedQTY,T1.IssuedQTY,
    T0.CmpltQtyT1.BaseQTY AS Compl_QTY, T0.RjctQtyT1.BaseQTY AS Rej_QTY,
    T2.LastPurPrc as PurPrise, T2.LstEvlPric as EvlPrice,
    T3.LineTotal AS Total,
    T1.IssuedQTY -((T0.CmpltQtyT1.BaseQTY) + (T0.RjctQtyT1.BaseQTY)) As WIP_QTY,
    (T1.IssuedQTY -((T0.CmpltQtyT1.BaseQTY) + (T0.RjctQtyT1.BaseQTY)))* T2.LstEvlPric As WIP_Valuation,
    T0.Comments
    FROM         OWOR T0 INNER JOIN
                          WOR1 T1 ON T0.DocEntry = T1.DocEntry INNER JOIN
                          OITM T2 ON T1.ItemCode = T2.ItemCode INNER JOIN
                          IGE1 T3 ON T1.DocEntry = T3.BaseEntry AND T1.LineNum = T3.BaseLine
    WHERE T0.Status='R'
    The above query returns the cost of production orders that are issued for production.The column WIP_Valuation in the query is equivalent to C/D (L/C) in Account Balance of Chart of Accounts i.e
    Financials -> Chart of accounts ->WIP  -> C/D (LC)
    I have used user defined  accounts.
    But this query does not trace the goods that are returned.So the total received in query is larger than the total of chart of accounts.
    For eg,
    Details                                                                 C/D  (LC)
    Issue for Production                                           1,952.96 INR
    Receipt from Production                                   (1,952.96 INR)
    For the above production order the goods are returned.So 1,952.96 is subtracted.In the query I am not able to subtract 1,952.96.I am considering 1,952.96  in total.What change should be done in the query to neglect the goods that are returned.

    On OJDT/JDT1, you are looking for postings that result from Production Orders, which you can identify by OJDT.TransType = 202 andOJDT.BaseRef is the production order.
    I also do not know exactly how B1 can tell the difference between a Goods Issue and an Issue to Production. You would expect a flag on OIGE, but there does not seem to be one.
    You could try finding the stock movements from the movements records OINM where I think OINM.ApplObj = 202 is a production movement.
    Regards,
    Douglas McDove

  • LDAP Query for particular user account in local Administrators group on All Enabled Computer Accounts

    Need to query on all enabled computer accounts that have a particular user account present in the local Administrators group.
    Ldap query is best, because not all our machines have SCCM client
    Thanks for any help you can provide. Lisa

    Ya, I have 41800+ computer accounts in my directory. I think that option is not feasible :) Thanks for your reply.
    I can use SCCM to do this too, but only for those that the client is running on and which are online. Thanks again.
    Hope is not all lost; a scripting solution is still possible.  The difference is instead of running a central script to pull info from all computers, you let the computers report back to you with the info.
    If I were you, I'd do the following:
    1) Create a file share and adjust the permissions so that "Domain Computers" have "Modify" Permissions.
    2) Create a script similar to the 2nd link I posted above, with a bit of adjustment:  at the end of the script, write the information to the file share created in (1), and name the file
    ComputerName.txt
    3) Use Group Policy Preference Scheduled Task to deploy the script, and make sure it only runs once.
    4) Happily wait for the results to come back :)
    The main benefit of this approach is you're not restricted by the computer connectivity at the moment you run the script.  This is especially true if you have many mobile computers in your environment.  Just wait for a reasonable time (they all need
    to come back to the mother ship once a while don't they?) and the results will show up in the file share you created.
    Cheers.

  • Query For Retrieving Data With Date and grouping

    Hi Guys
    I am having a hard time to figure out the sql query.
    I have a table with data. Below is the illustration.
    date location  item description
    1 jan 14 A  apple desc1
    2 jan 14 A  apple desc2
    3 jan 14 B  apple desc1
    4 jan 14 B  apple desc2
    1 jan 14 A  orange desc1
    2 jan 14 A  orange desc2
    3 jan 14 B  orange desc1
    4 jan 14 B  orange desc2
    My question it how to get the latest date on each location and item along with the description field
    This is the result I want
    date location  item description
    2 jan 14 A  apple desc2
    4 jan 14 B  apple desc2
    2 jan 14 A  orange desc2
    4 jan 14 B  orange desc2
    Thanks.

    provided it a datetime/date field you've for date you can do this
    SELECT [date],location,itemdescription
    FROM
    SELECT [date],location,itemdescription,
    ROW_NUMBER() OVER (PARTITION BY location ORDER BY [date] DESC) AS Rn
    FROM table
    )t
    WHERE Rn = 1
    Please Mark This As Answer if it helps to solve the issue Visakh ---------------------------- http://visakhm.blogspot.com/ https://www.facebook.com/VmBlogs

  • Query For Retrieving Data With Date

    Hi Guys
    I am having a hard time to figure out the sql query.
    I have a table with data. Below is the illustration.
    date location
    item
    1 jan 14 A
    apple
    2 jan 14 A
    apple
    3 jan 14 B
    apple
    4 jan 14 B
    apple
    1 jan 14 A
    orange
    2 jan 14 A
    orange
    3 jan 14 B
    orange
    4 jan 14 B
    orange
    My question it how to get the latest date on each location and item
    This is the result I want
    date location
    item
    2 jan 14 A
    apple
    4 jan 14 B
    apple
    2 jan 14 A
    orange
    4 jan 14 B
    orange
    Thanks.

    Try the below:
    create table #temp (sdate datetime,location char(1),Item varchar(20))
    insert into #temp values('1 jan 14','A','Apple')
    insert into #temp values('2 jan 14','A','Apple')
    insert into #temp values('3 jan 14','B','Apple')
    insert into #temp values('4 jan 14','B','Apple')
    insert into #temp values('1 jan 14','A','Orange')
    insert into #temp values('2 jan 14','A','Orange')
    insert into #temp values('3 jan 14','B','Orange')
    insert into #temp values('4 jan 14','B','Orange')
    ;With cte as
    Select * , Row_Number()Over(partition by location, item order by sdate desc) Rn
    From #Temp
    Select * From cte Where rn=1 Order by Item asc,location asc
    drop table #temp

  • Query for Group by & order by

    Hi all,
    I have a table name as angdata77 having attributes like asigno..
    i want to retrieve data from angdata77 by using both group by & order by clauses.. for total count..
    am using the query as
    select asigno,count(*) from angdata77 group by asigno order by asigno;
    Is there any other query for retrieving the data from angdata77
    Thanks in Advance,
    Venkatesh J.

    885756 wrote:
    Ya it's good.. Performance also good while retrieving data...
    I want to know other Possibilities also sir...There will be no better alternative for this, because this is the most simple and straight forward way to get the output you are looking for..
    Go ahead without any confusion... :)

  • Query to retrieve latest five transactions for each account

    hi,
    I have a table containing transactions of all account holders (this table contains thousands of records). My requirement is to retrieve recent five transactions from the table for all the account holders. Can anyone help me to retrieve the required data.
    Note: Each account holder may have more than one account e.g. savings account, current account etc.
    Regards,
    N Madhavan

    Hi,
    try something like
    select * from (select row_number() over (partition by holders order by transaction_date desc) r, t.* from t) where r<6;
    HTH
    Laurent Schneider
    OCM DBA

  • How to query the opening balance for an specific account for an spec. date

    Hi all,
    for my user query I need to calculate the opening balance for an cash account for an specific date.
    Any ideas, how can I do this?
    Or may be you know a field in an SBO table that already contains information I need...
    Best Regards,
    Inna

    Hi Inna,
    to find the opening balance for an account or a business partner, please see SAP Note [1114253|https://service.sap.com/sap/support/notes/1114253] :
    Symptom
    How to find the opening balance of a business partner or G/L account.
    Other terms
    Account, customer, supplier, vendor, creditor, debitor, start, initial, first, opening balance, business partner, G/L, SAP Business One
    Reason and Prerequisites
    Consulting
    Solution
    There are several possible approaches:
    Approach 1 - Business Partner Opening Balance:
    1. Go to Business Partners -> Business Partner Master Data -> find the Business Partner
    2. Click on the orange link arrow next to the field 'Account Balance' in the header region of the window.
    3. Untick the boxes next to 'Posting date from', 'Display' and 'Display Unreconciled Trans. Only'.
    4. Click on the button 'Refresh'.
    5. Find 'OB' in the column 'Origin', this is the opening balance journal entry.
    Approach 2 - Business Partner Opening Balance:
    1. Go to Business Partners -> Business Partner Master Data.
    2. Click on the orange link arrow next to the field 'Account Balance' in the header region of the window.
    3. Untick the boxes next to 'Posting date from', 'Display' and 'Display Unreconciled Trans. Only'.
    4. Click on the button 'Refresh'.
    5. Double click on the column header 'Posting Date' to find the earliest transaction on the business partner account. This transaction could be opening balance, verify this with the company accountant.
    Approach 3 - G/L Account Opening Balance:
    1. Go to Financials -> Chart of Accounts -> click on the account name once.
    2. Click on the orange link arrow next to the field 'Balance'.
    3. Untick the boxes next to 'Posting date from', 'Display' and 'Display Unreconciled Trans. Only'.
    4. Click on the button 'Refresh'.
    5. Find 'OB' in the column 'Origin', this is the opening balance journal entry.
    Approach 4 - Business Partner and/or G/L Account Opening Balance:
    1. If using SAP Business One 2005 SP01 or earlier, go to Reports -> Query Generator -> click on 'Execute'.
    2. If using SAP Business One 2007 or later, go to Tools -> Queries -> Query Generator -> click on 'Execute'.
    3. Ignore the red system message in the bottom of the screen.
    4. Click on the pencil icon in the top left of the window, the field with 'SELECT *' will change colour to white, then yellow when activated by clicking in the field.
    5. Copy the query below:
               SELECT T0.[TransId], T0.[Debit], T0.[Credit] , T0.[CreatedBy], T0.[TransType] FROM [dbo].[JDT1]  T0 WHERE T0.[TransType] = '-2'  and T0.[ShortName]  = '[%1]'
    6. Click on 'Save' and give the query an appropriate name and select the appropriate category.
    7. Click on 'Execute'.
    8. Click on 'Existing Values'.
    9. Select the G/L account or the Business Partner name from the list and click on 'OK'.
    10. The system message 'Records retrieved by this query #' (# = number of records) will pop up. Click on 'OK'.
    All the best,
    Kerstin

  • I don't know the password for the SMTP account so as to mail photos.  How can I retrieve or change the password?

    I am unable to share photos from the Iphoto program because I don't know the password for the SMTP account.  How can I either retrieve or change that password?  Or is it one I already should know?

    Have you set the general preferences in iPhoto to email using iPhoto? Then change it to email using "Mail". This way iPhoto will use your regular Mail account.

  • What is the query for Accounts Payable Trial Balance (APXTRBAL) in 11.5.10?

    Hi Guys,
    What is the query for Accounts Payable Trial Balance (APXTRBAL) in 11.5.10?
    I have to write an AP Invoice Aging Report in Discoverer to show all unpaid invoices that have been transferred into GL... Business wants it to match one-to-one with the AP Trial Balance standard report...
    Business wants to run the report for any date in a past...
    The report has two parameters:
    As Of Date - the same as As of Date for the AP Trial Report
    Trial Balance Run Date - the date when Trial Balance was run...
    Conditions are:
    TRUNC(Invoice Date) <=TRUNC(NVL(TO_DATE(:As Of Date),SYSDATE))
    TRUNC(NVL(Payment Date,'01-JAN-5000')) > TRUNC(NVL(TO_DATE(:As Of Date),SYSDATE))
    TRUNC(Invoice Creation Date) <= TRUNC(NVL(TO_DATE(:Trial Balance Run Date),SYSDATE))
    Distr Accounting Date <= TRUNC(NVL(TO_DATE(:As Of Date),SYSDATE))
    NVL(Distr Creation Date,Invoice Creation Date) <= TRUNC(NVL(TO_DATE(:Trial Balance Run Date),SYSDATE))
    Show_Flag = 'YES', where:
    Show_Flag = CASE WHEN ( NVL(Cancelled Date,'01-JAN-1901') > NVL(:As Of Date,SYSDATE) AND NVL(Inv Amount Aud,0) = 0 ) THEN 'YES' ELSE ( CASE WHEN NVL(Inv Amount Aud,0) = 0 THEN 'NO' ELSE 'YES' END ) END
    There is a difference between the logic of my report, and the logic of AP Trial Balance...
    Could you please advise what I'm missing?
    Thanks,
    Iana

    What is the query for Accounts Payable Trial Balance (APXTRBAL) in 11.5.10? You can get the code by opening the report in Reports Builder and get the query.
    Or, enable trace/debug as per (FAQ: Common Tracing Techniques within the Oracle Applications 11i/R12 [ID 296559.1]).
    Thanks,
    Hussein

  • Bought a new 4s and need to transfer photos from iCloud to new device. iCloud is giving me an old @me address. I do not have the email or pw  for the iCloud account. How do I retrieve this information? Thanks.

    Bought a new 4s and need to transfer photos from iCloud to new device. iCloud is giving me an old @me address. I do not have the email or pw  for the iCloud account. How do I retrieve this information? Thanks.

    If you need to change the iCloud ID on your new phone you have to go to Settings>iCloud, tap Delete Account, provide the password for the old ID when prompted to turn off Find My iPhone, then sign back in with the ID you wish to use.  If you don't know the password for your old ID, or if it isn't accepted, go to https://appleid.apple.com, click Manage my Apple ID and sign in with your current iCloud ID.  Click edit next to the primary email account, change it back to your old email address and save the change.  Then edit the name of the account to change it back to your old email address.  You can now use your current password to turn off Find My iPhone on your device, even though it prompts you for the password for your old account ID. Then save any photo stream photos that you wish to keep to your camera roll.  When finished go to Settings>iCloud, tap Delete Account and choose Delete from My iDevice when prompted (your iCloud data will still be in iCloud).  Next, go back to https://appleid.apple.com and change your primary email address and iCloud ID name back to the way it was.  Now you can go to Settings>iCloud and sign in with your current iCloud ID and password.

  • Query to retrieve the number of transactions done in every 1 hour for last

    Hi,
    Could anyone help in writing a query to retrieve the number of transactions done in every 1 hour for last month.
    Case:
    I/P
    Cases Timestamp1
    case1 01-01-2008 00:00:01
    case2 01-01-2008 00:01:01
    case3 01-01-2008 01:00:01
    case1 01-01-2008 01:02:01
    case4 01-01-2008 01:10:01
    case5 02-01-2008 02:00:01
    case6 02-01-2008 02:10:01
    case7 02-01-2008 23:00:01
    case.. 31-01-2008 24:00:00
    O/P
    from time to_time cases
    01-01-2008 00:00:00 01-01-2008 01:00:00 2
    01-01-2008 01:00:01 01-01-2008 02:00:00 3
    etc
    Any help really appreciated

    We can do this using analytical functions
    Following is what I did:
    create table timestamp1 (ts date)
    select *from timestamp1
    30/10/2008 15:41:13
    30/10/2008 15:41:05
    30/10/2008 15:40:03
    30/10/2008 14:58:26
    30/10/2008 14:29:45
    30/10/2008 13:17:48
    30/10/2008 08:29:50
    30/10/2008 06:05:51
    30/10/2008 03:41:52
    30/10/2008 02:29:54
    select distinct to_char(ts,'hh24') frmhrs,
    to_char(ts,'hh24')+1 tohrs, count(ts) OVER (order by to_number(to_char(ts,'hh24')) RANGE (1/24) PRECEDING )
    from timestamp1
    where trunc(ts)=trunc(sysdate) -- I added this just to make sure I get for today's data
    order by frmhrs
    FRMHRS     TOHRS     CNT
    02     3     1
    03     4     1
    06     7     1
    08     9     1
    13     14     1
    14     15     2
    15     16     3
    You can customizeas per ur need.

Maybe you are looking for

  • I can't seem to properly open saved Flash (.swf) files with Shockwave in Firefox.

    I have saved .swf flash files on my computer. I can view flash files when part of an internet page, but when I try to open the saved ones on Firefox, it asks me if I want to download them. I have tried to change the settings in the 'options' and 'app

  • Transferring music from an outdated macbook to my iPad

    Well, I finally did it. My new iPad is ahead of my laptop. It won't sync with my laptop, because I don't have the latest version of iTunes, and I cannot get it because my macbook's software does not support it. Is there anyway I can somehow transfer

  • Disc for protection of online attacks will not open and it says it is corruptedl

    When I opened Firefox I got the following message-- URGENT! Your version of Firefox is no longer protected against online attacks. Get the upgrade - it's fast and free! I clicked on the site and downloaded the disc and it would not open

  • How to view an image @ 100% ?

    When I do some editing in iPhoto, especially sharpening, I'd like to see it @100%. There is no indication at what % I'm viewing the image. Is there any way to know that ? When clicking "edit" on the bottom, at what size the image opens? Thanks!

  • FM's to create an invoice without any reference

    Hi, I want to create a billing document in R3 without any reference with sales order or delivery. Are there any FM or procedure to achieve this. If you can send me the sample code it will be really helpful. Regards, sasi