Show balances only at the first row in Discoverer.

I have a discoverer report based on Oracle GL module. I'm reporting the balances @ segment1,2&3 which gives Journal date, Begining balance , Journal amount and Ending balances. I'm able to pull in all the data. But the user wants enters the parameter as From period, To period and the segment1,2&3. Here is the data which is showing in my report currently.
segment info 1-2-3 journal name Journal Date Begin Balance journal Amount Ending Balance
931-11-11 abcd 09-SEP-2009 21,492,527.51 ; -506,290.00 23,875,304.30
931-11-11 abcd 09-SEP-2009 21,492,527.51 ; 1,996,600.00 23,875,304.30
931-11-11 abcd 30-NOV-2009 22,982,837.51 ; 333.58 25,365,614.30
931-11-11 abcd 30-NOV-2009 22,982,837.51 ; -2,600,200.00 25,365,614.30
931-11-11 abcd 30-NOV-2009 22,982,837.51 ; -166.79 25,365,614.30
931-11-11 abcd 31-DEC-2009 23,373,134.30 ; -495,865.00 25,755,911.09
931-11-11 abcd 31-DEC-2009 23,373,134.30 ; 998,035.00 25,755,911.09
Users desired output is like this:
segment info 1-2-3 journal name Journal Date Begin Balance journal Amount Ending Balance
931-11-11 abcd 09-SEP-2009 *21,492,527.51* -506,290.00
931-11-11 abcd 09-SEP-2009 1,996,600.00
931-11-11 abcd 30-NOV-2009 333.58
931-11-11 abcd 30-NOV-2009 -2,600,200.00
931-11-11 abcd 30-NOV-2009 -166.79
931-11-11 abcd 31-DEC-2009 -495,865.00
931-11-11 abcd 31-DEC-2009 998,035.00 25,755,911.09
user wants see the beginning balance only @ the first period. He is not interested in showing up at each and every line.
Then ending balance is sum of the begining balance which is at the first line and sum of all the journal amount which should show up at the last line.
I don't know how to show begining only at the first period and ending balance at the last row. Please help!!!
Edited by: PA1B on Feb 18, 2010 11:54 AM
Edited by: PA1B on Feb 18, 2010 11:57 AM

Maybe you would come up with a custom folder that unions the GL Balance table to the GL JE Lines table? You would have to union a begiining balance entry to the JE detail. Not sure you would need an ending balance record. The beginning balance entry would have the first day of the month as its journal date value as part of the union coding, and journal name NULL. So that hopefully it will sort out as the first entry for the period. Though even that still provides an issue with crossing over multliple periods. You would have to add conditions that say that select the NULL journal name entry only if the journal date = the begin period begin date. Or as part of the union process you could create a new column with a flag for balance (Y for the beginning balance table records and N for the detail JE lines records) and use that new column for editing along with the begin date of the selected date range. Just trying to toss out some ideas here. I myself have never had to do sometihng like this, so I don't have a proven method to accomplish this. But think back to what happens when you join tables with SQL. You are getting a record today with begin balance, je detail line amount, and end balance, because you are joining gl balances to je detail. What you really want, I think is an SQL result that gives you the first result row being the beginning balance of the account of the user selected From Period, and then the following SQL row results are the detail JE rows. That way you only get the beginning balance to print one time, at the beginning, in the SAME column as the je detail amount, and you can then do a sum at the end of the account to sum up the Discoverer report detail rows that would give you an ending balance, again showing just one time for each account in the report. So you have to ask yourself this question - if I was writing this SQL myself (forget about Discoverer for the moment), how would I write it myself, manually, to get the desired result? Once you know how to code it manually, then that should give you a clue on how to set it up in Discovererer. Hope this helps a bit. Another thought - rather than use Discoverer, maybe look at the Oracle Finanacial Statement generator to handle this? Or maybe come up with some kind of materialized view (that might help performance, since GL detail lines table can get pretty darn large)? Keep in mind with a materialized view you get a non-current view of the data, so that won't work if you absolutely need to query over what is currently in the Oracle base tables. But if this is a once a month thing, you could refresh the materialized view after the period is closed and then the users can run the Discoverer report.
Good luck.
John Dickey

Similar Messages

  • Showing data for the first row only

    Oracle Experts ,
    Below is my table in oracle.I wnat show Company ID only for the first row of each company. Table 2 is my output .
    Company Country Company ID
    BARCALAYS UK 1
    BARCALAYS USA 1
    BARCALAYS Australia 1
    Kingfisher UK 2
    Kingfisher INDIA 2
    Kingfisher INDIA 2
    Output Table 2 :
    Company Country Company ID
    BARCALAYS UK 1
    BARCALAYS USA Null
    BARCALAYS Australia Null
    Kingfisher UK 2
    Kingfisher INDIA Null
    Kingfisher INDIA Null
    Please give me a sql query.
    Many thanks in advance .
    Regards,
    Dirasa

    based on if a particular country is appearing twice for the same company and company_id wether to show the company_id for that country or not you may use any of the below queries :)
    /* Will show compan_ID twice if the country is repeated */
      with x as (
          select 'Foo' company_name, 'UK' country, 1 company_id from dual
          union all
          select 'Foo', 'USA', 1 from dual
          union ALL
           select 'Foo', 'USA', 1 from dual
           UNION ALL
          select 'Foo', 'AUS', 1 from dual
          union ALL
        select 'Foo', 'AUS', 1 from dual
          union all     
          select 'Bar', 'UK', 2 from dual
          union all
         select 'Bar', 'USA', 2 from dual
         union all
         select 'Bar', 'India', 2 from dual
    SELECT company_name,country,CASE WHEN rn=1 THEN company_id ELSE NULL END company_id
       FROM (SELECT
       company_name,company_id,country,rank()over(PARTITION BY company_name,company_id ORDER BY country) rn
        FROM x)
    /* Will NOT show compan_ID twice even if the country is repeated */   
      with x as (
          select 'Foo' company_name, 'UK' country, 1 company_id from dual
          union all
          select 'Foo', 'USA', 1 from dual
          union all
          select 'Foo', 'AUS', 1 from dual
          union ALL
        select 'Foo', 'AUS', 1 from dual
          union all     
                 select 'Foo', 'USA', 1 from dual
           UNION ALL
          select 'Bar', 'UK', 2 from dual
          union all
         select 'Bar', 'USA', 2 from dual
         union all
         select 'Bar', 'India', 2 from dual
    SELECT company_name,country,CASE WHEN rn=1 THEN company_id ELSE NULL END company_id
       FROM (SELECT
       company_name,company_id,country,row_number()over(PARTITION BY company_name,company_id ORDER BY country) rn
        FROM x)
    /* Will show compan_ID twice if the country is repeated */
      with x as (
          select 'Foo' company_name, 'UK' country, 1 company_id from dual
          union all
          select 'Foo', 'USA', 1 from dual
          union ALL
           select 'Foo', 'USA', 1 from dual
           UNION ALL     
          select 'Foo', 'AUS', 1 from dual
          union ALL
        select 'Foo', 'AUS', 1 from dual
          union all     
          select 'Bar', 'UK', 2 from dual
          union all
         select 'Bar', 'USA', 2 from dual
         union all
         select 'Bar', 'India', 2 from dual
    SELECT company_name,country,CASE WHEN rn=1 THEN company_id ELSE NULL END company_id
       FROM (SELECT
       company_name,company_id,country,dense_rank()over(PARTITION BY company_name,company_id ORDER BY country) rn
        FROM x)
                    Cheers!!!
    Bhushan

  • Lock the first row in an ordered table

    Hi,
    I have a table (TD_EVENTOS). I want to lock the row with te minimun value of a column (a timestamp called hora_evento) and some requirements of other columns. Then i build a cursor like this:
    CURSOR c is select * from td_eventos where (...) order by hora_evento for update skip locked;
    And then I make a fetch into this cursor and I get the row (locked) that I want. But i need the speedest way, and making that cursor it orders all rown in the table (when I only want the first row without lock) and when that table has 6000 or 7000 rows it wastes around 130 ms. My solution is to add to the WHERE a AND rownum < 50, and it only orders 50 rows (in 10 ms), but it orders 50 aleatory rows, and that`s not what I want.
    Any solution faster?
    Thanks!

    Sorry that wasn't clear of me and could be misleading. I didn't mean Oracle would have to do a full table scan, another access path such as an appropriate index scan would do. I was trying to get across that to do any kind of order or min or max, all records have to be investigated. Since the fact that you don't know a row is locked until you try to lock it, you clearly can't filter on it (it's not a data attribute).
    Apologies for any confusion my earlier post might have caused.
    The suggestion about using a sorted hash cluster still stands though, they are designed for FIFO queues.
    Which reminds me - SKIP LOCKED is in fact undocumented but everybody knows that Oracle use it internally for doing AQ. Since it's undocumented, you don't know how it works, when it will work, when it won't and of course Oracle can turn around and say "we don't support this".

  • Infopath submit button only works for the first row in a repeating table‏

    Hi, I have a InfoPath Email submit button issue I could not figure out. I have a master/detail repeating table in my form, and one of fields is "EmailAddress" which shows customer's email address. I created a submit button and put the "EmailAddress"
    field to "TO" object. When I tested it, the submit button only would return the first row of emailaddress from the repeating table, but not the rest of it..
    What I want is when I highlighted a customer, and click the submit button, the current customer's email address would show up in "TO" list. I did some research and saw some suggestions about using current() function. So I put current() in the front,
    like this:
    current()/dfs:dataFields/d:vw_HZLeadLists/@EmailAddress
    Still not working..Just return the first record of emailaddress from master repeating table... Does anyone know what's going on here? Thanks a lot!

    Hello,
    Use double eval to get all rows values. See my reply for more information in below thread:
    eval(eval(EmailAddress, 'concat(ToField, ";")'), "..")
    http://social.technet.microsoft.com/Forums/sharepoint/en-US/cc22aeb7-351f-45a7-8a4c-94132c3e0db2/eval-semicolon-function-issue?forum=sharepointcustomizationprevious
    Hope it could help
    Hemendra:Yesterday is just a memory,Tomorrow we may never see
    Please remember to mark the replies as answers if they help and unmark them if they provide no help

  • af:table, only the first row of the table is effect

    Hi experts,
    I have an issue about using the <af:table, needs your help:
    1.The default selected line is the first line of the table(This should be ok).
    2.Only the first line can react to my manipulate, such as select one line and click delete button.
    3.While choosing the other line-->click the command button, the page will be refreshed and the selected one will turned to the first line. (Now the selected row, will be the first row). And will do nothing ,and has no action with the command button.
    I have an page OVS_Server.jspx, parts of it is :
    <af:table value="#{backVS.serverList}"
    var="row" rows="20"
    emptyText="#{globalRes['ovs.site.noRows']}"
    binding="#{backing_app_broker_OVS_Server.serverListTable}"
    id="serverListTable" width="100%"
    partialTriggers="poll1 commandButton_refresh commandButton_searchServer"
    selectionListener="#{backing_app_broker_OVS_Server.onSelect}">
    <f:facet name="selection">
    <af:tableSelectOne text="#{globalRes['ovs.site.selectAnd']}" autoSubmit="true"
    id="tableSelectOne" required="false">
    <af:commandButton text="#{globalRes['ovs.site.server.poweroff']}"
    id="commandButton_powerOff"
    action="#{backing_app_broker_OVS_Server.powerOffAction}"
    partialTriggers="tableSelectOne"
    disabled="#{backing_app_broker_OVS_Server.unreachableServer}"
    />
    <af:commandButton text="#{globalRes['ovs.site.edit']}"
    id="commandButton_edit"
    action="#{backing_app_broker_OVS_Server.editAction}"
    />
    <af:commandButton text="#{globalRes['ovs.site.delete']}"
    id="commandButton_delete"
    action="#{backing_app_broker_OVS_Server.deleteAction}"
    />
    </f:facet>
    <af:column sortProperty="ip" sortable="true"
    headerText="#{globalRes['ovs.site.serverHost2']}"
    id="column_ip">
    <af:commandLink text="#{row.ip}"
    id="commandLink_ip"
    shortDesc="#{globalRes['ovs.site.viewUpdateDetails']}"
    action="#{backing_app_broker_OVS_Server.viewAction}"
    immediate="true"/>
    </af:column>
    <af:column sortProperty="serverName" sortable="true"
    headerText="#{globalRes['ovs.site.serverName']}"
    id="column_serverName">
    <af:outputText value="#{row.serverName}"/>
    </af:column>
    </af:table>
    One JavaBean OVS_Server.java,and part of it is :
    public class OVS_Server {
    private CoreTable serverListTable;
    private VirtualServer selectedServer;
    public void onSelect(SelectionEvent selectionEvent) {
    selectedServer = (VirtualServer)serverListTable.getSelectedRowData();
    public String deleteAction(){
    if (selectedServer!=null) {
    deleteServerOper.execute();
    return "deleteServer";
    Would anyone show some lights on it?
    Thank you very much.

    Thank you for your reply!
    But the example you mentioned also has the issue like one of the comments :
    "Hi, on selecting the first row it displays the correct value, when navigating to another row still it displays the old value and not fetching the new selected row, actually I can see this on your sample screen shots... is there any way we can fix??"
    Is there any resolution?

  • How do I set only the first row of a DataGrid as the selected row?

    I have a "Go" button on a search form that fetches data into an already data bound grid.  After the data is fetched, I want to make the first row in the Datagrid the selected row, as if the user clicked on it.  If the result set is empty, I don't want the code to crash.  (I only want one row to be able to be selected at a time)
                protected function btnGo_clickHandler(event:MouseEvent):void
                    getSBJsResult.token = baa_data_svc.getSBJs(cmbSrch.text);
                    grdSBJs. //  ?????  What goes here to select the first row?

    This should do it.
    If this post answered your question or helped, please mark it as such.
    if(myDataGrid.dataProvider.length > 0){
      myDataGrid.selectedIndex = 0;

  • I uploaded 3 audiobooks from iTunes to my iPhone 5 with the latest ios7 on it. Each of them only plays the first 15 mins of the playback and then silence, the bar shows the book is still playing but no sound, any ideas? Thanks

    I uploaded 3 audiobooks from iTunes to my iPhone 5 with the latest ios7 on it. Each of them only plays the first 15 mins of the playback and then silence, the bar shows the book is still playing but no sound, any ideas? Thanks

    What happens when playing the same books in iTunes. Is there sound after 15 min?
    If also silent in iTunes, check the info tab where you can see the item is an audiobook, etc. Check the volume bar, this normally is on the zero point.
    When an audio book is really low in audio, I tend to move this to the plus side (+1=max), but for some strange reason this bar was at -1 in some books I had and they also seemed to play in absolute silence.

  • Pie Chart Only Displays the Data of the First Row of the Table

    Hi Experts,
    I have a problem that the pie chart will not change when click on a second row or other rows on the table. It only displays the data of the first row of the table. How can I set up to make it reflect on any rows when I click the table? Please help, and I would very appreciate that.
    Thanks,
    -Don

    Thanks a lot for your response. I have realized that the pie chart behaves that way, so I just use the filter to see the specific data that I want. Also, you can drag the row and drop it right at the first row to see the data in the pie chart.

  • Get only the first row for duplicate data

    Hello,
    I have the following situation...
    I have a table called employees with column (re, name, function) where "re" is the primary key.
    I have to import data inside this table using an xml file, the problem is that some employees can be repeated inside this xml, that means, I'll have repeated "re"'s, and this columns is primary key of my table.
    To workaround, I've created a table called employees_tmp that has the same structed as employees, but without the constraint of primary key, on this way I can import the xml data inside the table employees_tmp.
    What I need now is copy the data from employees_tmp to employess, but for the cases where "re" is repeated, I just want to copy the first row found.
    Just an example:
    EMPLOYEES_TMP
    RE NAME FUNCTION
    0987 GABRIEL ANALYST
    0987 GABRIEL MANAGER
    0978 RANIERI ANALYST
    0875 RICHARD VICE-PRESIDENT
    I want to copy the data to make employees looks like
    EMPLOYEES
    RE NAME FUNCTION
    0987 GABRIEL ANALYST
    0978 RANIERI ANALYST
    0875 RICHARD VICE-PRESIDENT
    How could I do this?
    I really appreciate any help.
    Thanks

    Try,
    SELECT re, NAME, FUNCTION
      FROM (SELECT re,
                   NAME,
                   FUNCTION,
                   ROW_NUMBER () OVER (PARTITION BY re ORDER BY NAME) rn
              FROM employees_tmp)
    WHERE rn = 1G.

  • How to clear a cursor list without clearing the first row??

    Hi all, good to see ya ...
    I'm having this problem , that i'm using the first row ín a cursor list as a cursor in another graph. The rest of the rows are used as test sets i can add. So  when finnish with the tests if some was set, i have to delete or clear the cursorlist(but only the tests and not the first wich is the pointcursor) byy using the graphs cursor list proberty node ' Crsr.List '  and initialising it as showed in picture 1.
    Picture 2 shows the cursor list with some test and the cursor name (point cursor) and properties at  top. These properties are directly copied to another graph cursor list also at the top and there the point cursor is used as the cursor. The tests are also copied to the other graph cursor list, but when deleting the tests by 'clear button' all data are cleared also the point cursor. That is my problem.
    so the question is, how can i clear a cursor list without clearing the first raw and its proberties. any suggestions would be much help for me.
    Regards
    Zamzam 
    HFZ
    Attachments:
    Cursor Palette Front panel.JPG ‏25 KB
    cursor paletteA.JPG ‏66 KB
    Cursor paletteB.JPG ‏77 KB

    Zamzam
    The cursor list is just an array so you can delete the elements that you don't want.
    David
    Message Edited by David Crawford on 06-15-2006 12:46 PM
    Attachments:
    Delete Cursors.jpg ‏8 KB

  • DetailStamp facet iteration stops on the first row.

    Using Jdeveloper 10.1.3.2 using <f: facet name="detailStamp" I am having difficulty getting the iteration working correctly.
    I have placed a related child table to the parent table in the detailStamp. When I run the page I get a Master-Detail table that shows the related child rows of the first row in all the rows of the master table. I have tried the "ADF Developers Users Guide" methodolgy in Chapter 7 section 7.5.2 to use the table's varible to access the correct row accocated to the Master table.
    Steve-

    I read this once and I am not sure why it didn't click the first time I read it. But I believe the answer to my question is in the "Branch Rule Accessor of the Edit Rule page of the Tree Binding Editor. Which reads as follows:
    Branch Rule Accessor: If you are defining the rule for the main table, select the accessor method that returns the detail collection that you want to appear in the inline detail table. The list displays only the accessor methods that return the detail collections for the master collection you selected for the rule. If you are defining the rule for the inline table, select <none>, because you cannot embed a table inside the inline table.
    For more information see the
    "Application Development Framework Developer's Guide"
    Thanks Shay I am going to use the treeTable!
    Message was edited by:
    Steve Hogan

  • Getting the first row of a result set

    I need to get the first row returned from a select query that looks like this:
    SELECT DISTINCT parm1 FROM table1 WHERE parm1 > 10 ORDER BY parm1
    Can someone please show me how to do this?
    Alex

    Because you're only getting one row you don't need to bother with a DISTINCT clause. You'll need to order your data first and then nab the first row from that result set.
    SELECT parm1
      FROM (SELECT   parm1
                FROM table1
               WHERE parm1 > 10
            ORDER BY parm1)
    WHERE ROWNUM <= 1;

  • How do I create a 1d array that takes a single calculation and insert the result into the first row and then the next calculation the next time the loop passes that point and puts the results in thsecond row and so on until the loop is exited.

    The attached file is work inprogress, with some dummy data sp that I can test it out without having to connect to equipment.
    The second tab is the one that I am having the problem with. the output array from the replace element appears to be starting at the index position of 1 rather than 0 but that is ok it is still show that the new data is placed in incrementing element locations. However the main array that I am trying to build that is suppose to take each new calculation and place it in the next index(row) does not ap
    pear to be working or at least I am not getting any indication on the inidcator.
    Basically what I am attempting to do is is gather some pulses from adevice for a minute, place the results for a calculation, so that it displays then do the same again the next minute, but put these result in the next row and so on until the specifiied time has expired and the loop exits. I need to have all results displayed and keep building the array(display until, the end of the test)Eventually I will have to include a min max section that displays the min and max values calculated, but that should be easy with the min max function.Actually I thought this should have been easy but, I gues I can not see the forest through the trees. Can any one help to slear this up for me.
    Attachments:
    regulation_tester_7_loops.vi ‏244 KB

    I didn't really have time to dig in and understand your program in depth,
    but I have a few tips for you that might things a bit easier:
    - You use local variables excessively which really complicates things. Try
    not to use them and it will make your life easier.
    - If you flowchart the design (very similar to a dataflow diagram, keep in
    mind!) you want to gather data, calculate a value from that data, store the
    calculation in an array, and loop while the time is in a certain range. So
    theres really not much need for a sequence as long as you get rid of the
    local variables (sequences also complicate things)
    - You loop again if timepassed+1 is still less than some constant. Rather
    than messing with locals it seems so much easier to use a shiftregister (if
    absolutely necessary) or in this case base it upon the number of iterations
    of the loop. In this case it looks like "time passed" is the same thing as
    the number of loop iterations, but I didn't check closely. There's an i
    terminal in your whileloop to read for the number of iterations.
    - After having simplified your design by eliminating unnecessary sequence
    and local variables, you should be able to draw out the labview diagram.
    Don't try to use the "insert into array" vis since theres no need. Each
    iteration of your loop calculates a number which goes into the next position
    of the array right? Pass your result outside the loop, and enable indexing
    on the terminal so Labview automatically generates the array for you. If
    your calculation is a function of previous data, then use a shift register
    to keep previous values around.
    I wish you luck. Post again if you have any questions. Without a more
    detailed understanding of your task at hand it's kind of hard to post actual
    code suggestions for you.
    -joey
    "nelsons" wrote in message
    news:[email protected]...
    > how do I create a 1d array that takes a single calculation and insert
    > the result into the first row and then the next calculation the next
    > time the loop passes that point and puts the results in thsecond row
    > and so on until the loop is exited.
    >
    > The attached file is work inprogress, with some dummy data sp that I
    > can test it out without having to connect to equipment.
    > The second tab is the one that I am having the problem with. the
    > output array from the replace element appears to be starting at the
    > index position of 1 rather than 0 but that is ok it is still show that
    > the new data is placed in incrementing element locations. However the
    > main array that I am trying to build that is suppose to take each new
    > calculation and place it in the next index(row) does not appear to be
    > working or at least I am not getting any indication on the inidcator.
    >
    > Basically what I am attempting to do is is gather some pulses from
    > adevice for a minute, place the results for a calculation, so that it
    > displays then do the same again the next minute, but put these result
    > in the next row and so on until the specifiied time has expired and
    > the loop exits. I need to have all results displayed and keep building
    > the array(display until, the end of the test)Eventually I will have to
    > include a min max section that displays the min and max values
    > calculated, but that should be easy with the min max function.Actually
    > I thought this should have been easy but, I gues I can not see the
    > forest through the trees. Can any one help to slear this up for me.

  • Getting the first row for each group

    Hi Everyone,
    I have a query which returns a number of rows, all of which are valid. What I need to do is to get the first row for each group and work with those records.
    For example ...
    client flight startairport destairport stops
    A fl123 LGW BKK 2
    A fl124 LHR BKK 5
    B fl432 LGW XYZ 7
    B fl432 MAN ABC 8
    .... etc.
    I would need to return one row for Client A and one row for Client B (etc.) but find that I can't use the MIN function because it would return the MIN value for each column (i.e. mix up the rows). I also can use the rownum=1 because this would only return one row rather than one row per group (i.e. per client).
    I have been investigating and most postings seem to say that it needs a second query to look up the first row for each grouping. This is a solution which would not really be practical because my query is already quite complex and incorporating duplicate subqueries would just make the whole thing much to cumbersome.
    So what I really new is a "MIN by group" or a "TOP by group" or a "ROWNUM=1 by group" function.
    Can anyone help me with this? I'm sure that there must be a command to handle this.
    Regards and any thanks,
    Alan Searle
    Cologne, Germany

    Something like this:
    select *
    from (
       select table1.*
       row_number() over (partition by col1, col2 order by col3, col4) rn
       from table1
    where rn = 1In the "partition by" clause you place what you normally would "group by".
    In the "order by" clause you define which will have row_number = 1.
    Edit:
    PS. The [url http://download.oracle.com/docs/cd/E11882_01/server.112/e17118/functions004.htm#i81407]docs have more examples on using analytical functions ;-)
    Edited by: Kim Berg Hansen on Sep 16, 2011 10:46 AM

  • Printer will only print the first document then will do nothing.

    I am running a dell system with windows 7 pro 64 bit.
    I just got an HP LaserJet Pro 400 m401n printer.
    I downloaded the most current drivers for windows and updated the printer from the HP website.
    The printer will let me print the first document after the computer is restarted. Sometimes I can print a second document if I print it back to back with little to no time between printing the first document. If more than a few minutes passes and I try to
    print again the program im using to print enters a "not responding" state and goes into recovery mode. This happens with notepad, excel, word, or even printing directly from the internet.
    I can open the printer properties and see the document just sitting with "spooling" out beside it. I assumed it was a printer spooling problem and tried going to the Services.msc and checking the printer spooler. Ive started it and stopped it several
    times. Ive also gone into %WINDIR%\system32\spool\printers and deleted all files in this folder. This does not help. It still gets hung at spooling.
    Next I just went to printer property and turned the spooling off completely, by having it send the document directly to the printer. Again the exact same problem but instead of getting hung in "spooling" it now just hangs "printing".
    I have also gone to the printer properties on the ports tab to see if disabling the bidirectional support was enabled as per a google search result showing a potential solution. But im connecting the printer directly to the computer via a usb port so that
    option is not even available.
    The only thing that allows me to print again is doing a restart on my computer, then again I can only print the first document sent. Restarting the printer itself does nothing.

    Hi James,
    Did this printer work correctly before ?
    To verify whether it is related to the printer ,please plug it in another machine to have a check if it is possible.
    Considering it is a USB device ,plug in  with another port to have a check or try to update the USB controller driver or reinstall the USB controller driver to have a check.
    Please check whether the Event Viewer contains  errors or warnings related to this issue .
    I found a similar symptom in the HP forum ,the solution in it may be helpful:
    HP LaserJet Pro 400 M401dne print only one page (document)
    (720 Views)
    http://h30499.www3.hp.com/t5/Printers-LaserJet/HP-LaserJet-Pro-400-M401dne-print-only-one-page-document/td-p/6456104#.VK5gLHkfrwo
    You may need to look for help from the HP forum at the same time .
    Best regards

Maybe you are looking for