IR COMPUTE OR QUERY?

IM AM TRYING TO MAKE AN IR REPORT WITH AGING ON OPEN INVOICES. IN ONE COLUMN I HAVE NUMBER OF DAYS PAST DUE. NOW I NEED TO CASE THAT COLUMN IN AN IR AS FOLLOWS:
CASE
WHEN J > 119 THEN 120
WHEN J < 119 AND > 90 THEN 90
WHEN J < 89 AND > 60 THEN 60
WHEN J < 59 AND > 30 THEN 30
WHEN J < 29 THEN 0
END AGING
BUT I CANT USE AND OR BETWEEN IN A COMPUTE. I DID TRY TO PUT IT IN THE COMPUTE AS A DECODE BUT I GET ERRORS:
DECODE ( J , ( J<29 ),J, ( J>29 ),30, ( J>59 ),60, ( J>89 ),90, ( J>119 ),120,J)
ANY HELP WOULD BE GREAT. IM TRYING TO MAKE AN ACCOUNTING APP AND IM OVER MY HEAD.
THANK FOR YOUR TIME LOOKING AT MY POST.

STOP SHOUTING!!!
Is your caps lock stuck?
When posting code on the forum, put {noformat}{noformat} (with the curly brackets and the word code in lowercase) above and below your code like this...
{noformat}{noformat}
SELECT *
FROM emp
{noformat}{noformat}
It will then appear like this, preserving formatting...SELECT *
FROM emp
Makes it easier for everyone to read and people more inclined to help you out.
Anyway, try this... (you should probably add an ELSE clause too, but I don't know your business logic so I left it out.)SELECT MIN(due_date),
TO_DATE(SYSDATE, 'DD-MON-YY') - MIN("DUE_DATE") age,
CASE
WHEN (TO_DATE(SYSDATE, 'DD-MON-YY') - MIN("DUE_DATE")) > 29
THEN
'30'
WHEN (TO_DATE(SYSDATE, 'DD-MON-YY') - MIN("DUE_DATE")) > 59
THEN
'60'
WHEN (TO_DATE(SYSDATE, 'DD-MON-YY') - MIN("DUE_DATE")) > 89
THEN
'90'
WHEN (TO_DATE(SYSDATE, 'DD-MON-YY') - MIN("DUE_DATE")) < 29
THEN
'0'
END
aging
FROM invoices
Cheers
Ben                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                                           

Similar Messages

  • Query is not working properly when statistics are computed (XE 11g Windows 7 32 bits)

    Hi,
    We have an application with a Oracle XE 11.2 database on a Windows 7 32 bits plateform.
    We have a query wich access 4 tables end use a user defined package function.
    When the statistics are computed the query is returning no rows, (with the data in the tables it should return 349 rows).
    When the statistics are deleted (with ANALYZE TABLE xxx DELETE STATISTICS) the query is working fine.
    I tried different statistics calculation methods, and sometimes the query is working, sometimes it is not!
    I don't understand how the statistics caluclation method can change the query results.
    Has anybody already encountered such an issue?
    Regards,
    Yves

    I understand how the statistics are working.
    What i don't undestand is why the number of rows returned is different with or without statistics.
    I tried yesterday to had a hint /*+ RULE */ and with the hint, rows are correctly returned!
    Here is the query:
    SELECT l_activite.copaip, l_activite.nunati, l_activite.numeul, obsoff.dapaul,
                                        obsoff.lai24h / 10 * DECODE (coefat, NULL, 1, 0, 1, coefat / 200) lai24h, obsoff.etfeob, obsoff.tplaco / 10 tplaco,
                                        obsoff.tblaco / 10 tblaco, l_lactoff.nulact, obsoff.dapaul - l_lactoff.dadela + 1 dulact, l_lactoff.dadela,
                                        l_activite.dcenul,
                                        (  obsoff.tblaco
                                         / 10
                                         * (DECODE (obsoff.tblaco, 0, 0, NULL, 0, obsoff.lai24h * DECODE (coefat, NULL, 1, 0, 1, coefat / 200) / 10))
                                        ) mg,
                                        (  obsoff.tplaco
                                         / 10
                                         * (DECODE (obsoff.tplaco, 0, 0, NULL, 0, obsoff.lai24h * DECODE (coefat, NULL, 1, 0, 1, coefat / 200) / 10))
                                        ) mp,
                                        DECODE (obsoff.tblaco, 0, 0, NULL, 0, obsoff.lai24h * DECODE (coefat, NULL, 1, 0, 1, coefat / 200) / 10) lait_mg,
                                        DECODE (obsoff.tplaco, 0, 0, NULL, 0, obsoff.lai24h * DECODE (coefat, NULL, 1, 0, 1, coefat / 200) / 10) lait_mp,
                                        pck_f_valorises.f_present_mul (obsoff.etfeob,
                                                                       obsoff.nulact,
                                                                       (SELECT MAX (l_obsoff.dapaul)
                                                                          FROM l_obsoff
                                                                         WHERE TRIM (l_obsoff.copaip) = TRIM (l_activite.copaip)
                                                                           AND TRIM (l_obsoff.nunati) = TRIM (l_activite.nunati)
                                                                           AND l_obsoff.dapaul < obsoff.dapaul
                                                                           AND l_obsoff.etfeob <> 'T'),
                                                                       obsoff.dapaul,
                                                                       l_lactoff.dadela
                                                                      ) as OK
                                   FROM l_activite, l_obsoff obsoff, l_lactoff, l_passage
                                  WHERE TRIM (l_activite.copaul) = TRIM ('FR')
                                    AND TRIM (l_activite.numeul) = TRIM ('61323017') || '    0'
                                    AND TRIM (l_activite.copaip) = TRIM (obsoff.copaip)
                                    AND TRIM (l_activite.nunati) = TRIM (obsoff.nunati)
                                    AND TRIM (l_activite.copaip) = TRIM (l_lactoff.copaip)
                                    AND TRIM (l_activite.nunati) = TRIM (l_lactoff.nunati)
                                    AND TRIM (l_passage.copaul) = TRIM (l_activite.copaul)
                                    AND TRIM (l_passage.numeul) = TRIM (l_activite.numeul)
                                    AND (   (DECODE (l_activite.dacosu, TO_DATE ('01/01/0001', 'dd/MM/YY'), 'VIDE', NULL, 'VIDE', l_activite.dacosu) = 'VIDE')
                                         OR (l_activite.dacosu >= l_passage.dapaul)
                                    AND l_passage.dapaul = obsoff.dapaul
                                    AND obsoff.nulact = l_lactoff.nulact
                                    AND obsoff.dapaul >= l_activite.dcenul
                                    AND l_passage.dapaul <= to_date('24/04/2013')
                                    AND l_passage.dapaul >= to_date('24/04/2012') - 50
                                    AND pck_f_valorises.f_present_mul (obsoff.etfeob,
                                                                       obsoff.nulact,
                                                                       (SELECT MAX (l_obsoff.dapaul)
                                                                          FROM l_obsoff
                                                                         WHERE TRIM (l_obsoff.copaip) = TRIM (l_activite.copaip)
                                                                           AND TRIM (l_obsoff.nunati) = TRIM (l_activite.nunati)
                                                                           AND l_obsoff.dapaul < obsoff.dapaul
                                                                           AND l_obsoff.etfeob <> 'T'),
                                                                       obsoff.dapaul,
                                                                       l_lactoff.dadela
                                                                      ) = 1
    and the function :
    FUNCTION F_PRESENT_MUL(p_etat IN CHAR,p_nulact IN NUMBER,
    p_derniere_obs_lait IN DATE, p_date_passage IN DATE,p_dadela IN DATE)
    RETURN NUMBER IS
       NAME:       F_PRESENT_MUL
       PURPOSE:    Retourne 1 si présent MUL 0 sinon
       REVISIONS:
       Ver        Date        Author           Description
       1.0        01/12/2006  Mathieu GUIDEL        1. Created this function.
       NOTES:
    BEGIN
       IF p_derniere_obs_lait IS NULL THEN /* vache présente MUL */
        RETURN 1;
       END IF;
       IF p_etat='P' THEN /* vache présente MUL */
       RETURN 1;
       ELSE
        IF p_etat = 'N' THEN /* NC ou FV */
         IF (p_date_passage - p_dadela + 1) <= 7 THEN /* FV */
          IF p_nulact=1 THEN
          RETURN 0;
          ELSE /* considérée comme tarie */
           IF (p_date_passage - p_derniere_obs_lait) < 100 THEN /* derniere obs lait inférieur à 100 jour, présente MUL */
           RETURN 1;
           ELSE /* FV tarie depuis trop longtemps : non présente MUL */
           RETURN 0;
           END IF;
          END IF;
         ELSE /* NC */
         RETURN 1;
         END IF;
        ELSE
         IF p_etat = 'T' THEN /* Tarie */
          IF (p_date_passage - p_derniere_obs_lait) < 100 THEN /* derniere obs lait inférieur à 100 jour, présente MUL */
          RETURN 1;
          ELSE /* tarie depuis trop longtemps : non présente MUL */
          RETURN 0;
          END IF;
          ELSE /* etat différent de P, N, T donc etat = S */
          /*vérification du contrôle précédent non FV*/
          IF (p_derniere_obs_lait - p_dadela + 1) <= 7 THEN /* FV au contrôle précédent*/
          RETURN 0;
          ELSE
            IF (p_date_passage - p_derniere_obs_lait) < 30 THEN /* derniere obs lait ou NC inférieur à 30 jour, présente MUL */
            RETURN 1;
            ELSE /* sortie sans lait depuis trop longtemps : non présente MUL */
            RETURN 0;
            END IF;
          END IF;
         END IF;
        END IF;
       END IF;
    END F_PRESENT_MUL;
    Regards

  • Teradata OBIEE numeric overflow occurred during computation

    Hi Guys,
    I have union of two queries in OBIEE and backend data base is teradata. report and sql generated by query are throwing an error " ][ODBC Teradata Driver][Teradata Database] Numeric overflow occurred during computation"
    same query ran in teradata and there also getting same error.
    report should fetch sime number may be 5 digit but not sure why I'm getting this error.
    Any idea? appreciated
    Thanks
    Jay.

    Hi Jay,
    May be you have these as smallint and the aggregation does not fit in smallint. But knowing your data demographics is the only solution. Run that query in the database and I am sure you will get the same error and change the datatype of those columns.
    Check http://forums.teradata.com/forum/
    Regards,
    Bharath

  • Timing Query Performance in Java

    Hello again everyone,
    I had previously asked a question concerning timing the execution time of an individual thread, and I have been unable to uncover an acceptable answer. So, instead of threads I may use system processes. Some background...
    I am writing a database load-testing application that simulates load via. submitting a set of queries through multiple connections. These multiple connections can be separate threads or processes that run concurrently in order to get a feel for how the database performs under the load of a number of users. My question is does anyone know how to get the actual execution time of a single process. I am afraid that due to the large number of users, the system will be unacceptably slow. Normally I could do something like this ...
    long start = System.getcurrentTimeMillis();
    executeJDBCquery();
    end = System.getcurrentTimeMillis() - start;
    however I am concerned that with a large number of users this will not provide an accurate query execution time since the system will be distrubting its processing power over so many processes. The first suggestion that has raised is to get the query processing time from the RDBMS, however, I can't figure out how this can be done with Oracle 8i. Is there a hidden JDBC method or property that will give server-side execution time for a query, or can anyone suggest a solution that will work with oracle? If anyone knows how to get the actual execution time of a single system process that would be very helpful as well. Thanks for any help that you may be able to give, let me know if I can provide any more details.
    Dan

    Try this:
    Create a new table in Oracle to track the times, such as:
    Create Table time_log (Thread_ID number, Query_ID number,
    start_time number, end_time number);
    On the tables that you are performing the queries on, create before and after statement-level triggers. These triggers would insert a record into the time_log field as required (i.e., the before trigger enters a start time, the after trigger enters an end time).
    To properly keep track of the execution times, you would need a thread_id (possibly pass this as part of the query call) and a table/query_id. This way you would know which thread queried what table.
    For your final timing computations, simply query the time_log table, making the correct calculations.
    One note: the start and end times are numbers, not dates, as the Oracle dates only get down to seconds. You will have to use the DBMS_UTILITY.GET_TIME, which returns the current time in hundreds of a second.
    HTH,
    Sean

  • Don'T repeat item with a LEFT JOIN QUERY

    Hello,
    I would like to know how display the following results:
    *Name*:  John Fox
    *Sales:*  1- LAPTOP
                    2- HARDDRIVE
                    3- COMPUTERHere is my 2 tables: CUSTOMER and SALES
    CUSTOMER
    ID NAME GENDER
    1 John Mayer F
    2 Melissa John F
    3 Julie Black F
    4 Mickael Fox M
    5 John Fox M
    SALES
    ID ID_CUSTOMER TYPE
    1 1 Boat
    2 1 TV
    3 4 CD PLAYER
    4 5 LAPTOP
    5 5 HARDDRIVE
    6 5 COMPUTER
    My QUERY
    SELECT customer.Name as NAME, customer.Gender, sales.TYPE
    from customer
    LEFT JOIN sales
    ON customer.ID = sales.ID_CUSTOMER
    WHERE customer.Name = 'John Fox'The problem: If I use the default template, I have:
    NAME GENDER TYPE
    John Fox M LAPTOP
    John Fox M HARDDRIVE
    John Fox M COMPUTER I don'T want the Name John Fox to be repeated at each row.
    I tried to add: #Name# in the REGION DEFINITION - REGION HEADER but I have this result:
    #NAME#
    NAME GENDER TYPE
    John Fox M LAPTOP
    John Fox M HARDDRIVE
    John Fox M COMPUTER
    So, what can I do to have this result? Change the query???
    Name:  John Fox
    Sales: 1- LAPTOP
           2- HARDDRIVE
            3- COMPUTER               thanks,
         Roseline

    Hi Roseline,
    You can adapt the solution suggested in this post Re: More than 1 records in one cell
    Thanks,
    Manish

  • Wish to find out number of rows returned from query

    hi,
    is it possible to determine how many rows have been returned after a query has been executed?
    thank you.

    It doesn't seem like there is a method to do it for you, [...]There can't be such a method that's guaranteed to work for all databases. Many databases just hand you a cursor with the query results, and you have to walk the cursor to find the complete set. It's even possible for the DB to continue computing the query in the background and just give you a cursor to walk and consume what it has already generated.
    So no, you have to walk the result set (effectively pulling everything over to the client) to count the number of rows..

  • The Power Query ribbon and the Power Pivot ribbon are gone !

    Hello,
    I created in Excel 2013, using Power Query, two large tables (more than 4 000 000 rows) according this principle: << However,
    the query pane that shows up on the side while data is loading lets you disable "load to worksheet". The data will continue to download. Once the download is done, you can click on "Load to Data Model" which will then get the data into
    the underlying xVelocity/data model.>>
    I built two calculated columns in order to create PRimary and Foreign keys for relations.
    I saved the xlsx file several times
    I Closed the xlsx file
    I reopened the xlsx file but, bad news, the
    Power Query ribbon and the Power Pivot ribbon are gone !
    I can check the the data connections are still there.
    What happened? What did I miss ?
    Thanks for your help
    Error message when I refresh connections :

    When I restart the computer, Power
    Query and Power
    Pivot ribbons come back. But if I enter a
    formula, they go away again.
    What could be the solution?

  • Computing 2 cummulated key figures

    Hi All,
    We receive a requirement to develop a report that would able to compute 2 cummulated key figures in BW. I was informed this was not able to be done in the normal BeX query formula as the cummulative values are computed during query execution.
    Example:
    Usages   Loss/Gain       %LOSS/GAIN (=SUM(Usages)*100/SUM(Loss/Gain))
    is there a way to do this in BeX or must this be done during back-end execution.

    Thanks Suman - but i think BeX is not able to handle 2 cummulated key figure values and calculate them in a formula correctly:
    The % Tol - is picking up cummulated values from Usages and Daily Gain/Loss - only way i can think of is to store this in the cube.
    Usages     % Tol     Daily Gain/Loss
    25,713     372             95,666
    32,584     -64.52     -133,278
    31,302     0.35              37,924
    29,915     0.56              362

  • Get last logon time,computer and username together with Powershell

    I have a script which gets the last logon times of each computer in the domain.
    My script:
    $dcs = Get-ADComputer -Filter { OperatingSystem -NotLike '*Server*' } -Properties OperatingSystem
    foreach($dc in $dcs) {
    Get-ADComputer $dc.Name -Properties lastlogontimestamp |
    Select-Object @{n="Computer";e={$_.Name}}, @{Name="Lastlogon"; Expression={[DateTime]::FromFileTime($_.lastLogonTimestamp)}}
    ==================================
    Result:
    Computer Lastlogon
    DC1 6/06/2013 16:38:24
    DC2 6/06/2013 16:30:40
    =============================================I also want to get who/which account made this logon. For example:Computer Lastlogon User
    DC1 6/06/2013 16:38:24 user2
    DC2 6/06/2013 16:30:40 user1

    I also want to get who/which account made this logon. For example:Computer Lastlogon User
    DC1 6/06/2013 16:38:24 user2
    DC2 6/06/2013 16:30:40 user1
    The last logon from aD is the last time the computer account authenticated on AD.  It has nothing to do with a user.
    Get-ADComputer will not return DCs. It will return all workstations.
    To find the last logon for a specific computer just query the computers security log for event 529(XM-2003) or 4672 Get the newest one.
    ¯\_(ツ)_/¯

  • Create export-csv with dynamic (unknown amount) columns

    Hi,
    This is my first post, hopefully I include everything you need.  My code block is at the bottom of my post.....
    I have written a PS script that gives me the info I need, but I would like to format it differently.  Currently I import a CSV with 2 columns - username and print queue name.  The script then takes each username and looks it up in SCCM
    to find the workstations the username has logged into.  I then export to csv - this is where I would like to format it differently.  The export csv has 4 columns username, print queue name, workstation name, and details. 
    username1,printqueue,workstation1,details
    username1,printqueue,workstation2,details
    username2,printqueue,workstation1,details
    username2,printqueue,workstation2,details
    My problem is that if the user logs into 5 workstations I have 5 rows with duplicated username and print queue name.  If my next username logs into 8 workstations I have 8 rows, etc.  I would like to format the export dynamically using as many
    columns (not rows) as need.  For example
    username1, printqueue,workstation1,workstaion2, workstation3
    username2,printqueue,workstation1,workstation2, workstation3,workstation4
    I expect where I have my pscustomobject would be where I could change this - I have tried setting up a count variable and using that in my loop to be able to assign dynamic column name, I have tried using an array but still new to setting that up, maybe
    I just wasn't doing it correctly.  If anyone has any ideas that would be great.
    Thanks, Kevin
    Here is my code:
    #Declare variables
    $now = Get-date
    $date = get-date -uformat "%Y_%m_%d_%I%M%p"
    $Queues = Import-Csv "c:\Users.csv"
    $SiteName="XXX"
    $SCCMServer="your.sccm.server.com"
    $SCCMNameSpace="root\sms\site_$SiteName"
    $CSVPath1 = "c:\PrinterUsersByComputer_$date.CSV"
    #Notify user that script is starting
    Write-Host -ForegroundColor Green "Starting script"
    #Loop through each account and find any workstations from SCCM that the user has logged into
    foreach ($Queue in $Queues){
    $Queue.Username
    $WSs = Get-WmiObject -namespace $SCCMNameSpace -computer $SCCMServer -query "select Name from sms_r_system where LastLogonUserName = '$($queue.username)'" | Select-Object -ExpandProperty Name
    #Check if the workstation variable has data
    if ($WSs){
    foreach ($WS in $WSs) {
    #Check if workstation is ALIVE and if we have access to it to get OS version
    $rtn = (Test-Connection -Cn $WS -BufferSize 16 -Count 1 -Quiet)
    IF ($rtn -match 'True') {
    $OS = Get-WmiObject Win32_OperatingSystem -ComputerName $WS | Select-Object -ExpandProperty Caption -ErrorAction Stop
    #Write to screen device to show progress
    Write-Host -ForegroundColor Green "Computer information found: $WS"
    #Write to log file the username, workstation(s) logged into, and OS version
    [PSCustomObject] [Ordered] @{
    'UserName' = $Queue.Username
    'Print Queue' = $Queue.PrintQueue
    'ComputerName' = $WS
    'Operating System' = $OS
    } | Export-Csv $CSVpath1 -Append -NoTypeInformation

    Ok, just a sec, I'm not sure we are on the same page.  I don't think that isn't what I'm look for. Unless I'm missing something, your code above assume 4 workstation columns for every row.  What if there is 5 or 8.  My current output
    from the full script is this (based on checking if PC is pingable, whether I'm denied the WMI query, etc)
    UserName
    Print Queue
    ComputerName
    Operating System
    User1
    PQ1
    Computer1
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer2
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer3
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer4
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer5
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer6
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer7
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer8
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer9
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer10
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer11
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer12
    Microsoft Windows 7 Enterprise 
    User1
    PQ1
    Computer13
    No device name to query
    User1
    PQ1
    Computer14
    Microsoft Windows 7 Enterprise 
    User2
    PQ2
    Computer15
    Microsoft Windows 7 Enterprise 
    User3
    PQ3
    Computer1
    Microsoft Windows 7 Enterprise 
    User4
    PQ4
    Computer2
    Access denied connecting to device.    No access to it: Computer2
    What I would really like is this, getting rid of the OS name for now:
    User1
    PQ1
    Computer1
    Computer2
    Computer3
    Computer4
    Computer5
    User2
    PQ3
    Computer1
    User3
    PQ13
    Computer1
    Computer2
    I would just like to condense the workstations to columns instead of 1 workstation per row and be able to expand the # of columns required based on the amount of workstations in $WSs -

  • Some appointments are not shown sometimes

    I access a Webaccess server that is in GMT+1 timezone from GMT-5 timezone and have GW set to either GMT-5 explicitly or use workstation's timezone. I did this test on Sunday Feb 26 and couple hours into Monday Feb 27 (GMT-5) - I created an appointment for Feb 26, 11:00-11:59pm from within a week view. As soon as it was created, it was not shown either in week or day views or basic interface, but could only be seen in month view or when searching for appointments. That is just an example, it was not a single occurrence, but I had several test appointments like that. Then I also had appts that were not shown even in month view, but only in search results. Regarding that Feb 26 appt, it could be made seen again in day or week views if a different timezone was chosen in options. Today, Feb 27 at the end of the day, that appointment is seen no problem in day and week views and also in basic interface, so I do not have a reliable way of reproducing the problem. Since the appt was not shown even in basic interface before, I suspect it is a server time computation/database query problem and not browser graphics rendering problem. Also, there used to be a pdf file with Webaccess API that showed how to query calendar with startDate and endDate parameters which can be done in basic interface by manually editing the address field in browser and that part is broken too - Webaccess does not show some appointments after given start date, until the start date is moved up earlier to coincide with start of the day in GMT timezone. All that used to work fine in earlier GW versions. It looks like in GW2012 some big design changes were made and some serious bugs were introduced.

    The missing piece is how ( every other way of accessing the calendar ) sees the apointment. What happens from the Windows client? Does it show the missing appointment created in webaccess?
    Its certainly possible that some boundary condition bug is being exercised. But we need to get this to the point where it can be easily reproduced. I suspect the issue has to do with the time zone being signed differently, e.g. +1 vs -5.
    Webaccess is essentially a rewrite in 2012, this eliminated the GWINTER server component and so there are a lot of positives to this move. All things considered, its been pretty decent.
    -- Bob

  • Health Check in Exchange 2007 Scripting

    Hi All,
    I have been looking around for scripts which would help me perform regularised health checks in my enviornment. After lot of googling i was able to get a script which would meet my requirements. However i have a few challenges involved in extracting some
    more information:
    1. Mailbox Store Size, Free Diskspace percentage for mailbox servers
    2. Remote Mail flow Tests & Mailflow test to every exchange 2007 mailbox servers in org.
    3. Automating Email of collected data (in HTML) to Administrator.
    4. Executing the script Automatically without triggering it from Exchange Management Shell.
    Script Below
    param( [string] $auditlist)
    Function Get-CustomHTML ($Header){
    $Report = @"
    <!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Frameset//EN" "http://www.w3.org/TR/html4/frameset.dtd">
    <html><head><title>$($Header)</title>
    <META http-equiv=Content-Type content='text/html; charset=windows-1252'>
    <meta name="save" content="history">
    <style type="text/css">
    DIV .expando {DISPLAY: block; FONT-WEIGHT: normal; FONT-SIZE: 8pt; RIGHT: 8px; COLOR: #ffffff; FONT-FAMILY: Arial; POSITION: absolute; TEXT-DECORATION: underline}
    TABLE {TABLE-LAYOUT: fixed; FONT-SIZE: 100%; WIDTH: 100%}
    *{margin:0}
    .dspcont { display:none; BORDER-RIGHT: #B1BABF 1px solid; BORDER-TOP: #B1BABF 1px solid; PADDING-LEFT: 16px; FONT-SIZE: 8pt;MARGIN-BOTTOM: -1px; PADDING-BOTTOM: 5px; MARGIN-LEFT: 0px; BORDER-LEFT: #B1BABF 1px solid; WIDTH: 95%; COLOR: #000000; MARGIN-RIGHT:
    0px; PADDING-TOP: 4px; BORDER-BOTTOM: #B1BABF 1px solid; FONT-FAMILY: Tahoma; POSITION: relative; BACKGROUND-COLOR: #f9f9f9}
    .filler {BORDER-RIGHT: medium none; BORDER-TOP: medium none; DISPLAY: block; BACKGROUND: none transparent scroll repeat 0% 0%; MARGIN-BOTTOM: -1px; FONT: 100%/8px Tahoma; MARGIN-LEFT: 43px; BORDER-LEFT: medium none; COLOR: #ffffff; MARGIN-RIGHT: 0px; PADDING-TOP:
    4px; BORDER-BOTTOM: medium none; POSITION: relative}
    .save{behavior:url(#default#savehistory);}
    .dspcont1{ display:none}
    a.dsphead0 {BORDER-RIGHT: #B1BABF 1px solid; PADDING-RIGHT: 5em; BORDER-TOP: #B1BABF 1px solid; DISPLAY: block; PADDING-LEFT: 5px; FONT-WEIGHT: bold; FONT-SIZE: 8pt; MARGIN-BOTTOM: -1px; MARGIN-LEFT: 0px; BORDER-LEFT: #B1BABF 1px solid; CURSOR: hand; COLOR:
    #FFFFFF; MARGIN-RIGHT: 0px; PADDING-TOP: 4px; BORDER-BOTTOM: #B1BABF 1px solid; FONT-FAMILY: Tahoma; POSITION: relative; HEIGHT: 2.25em; WIDTH: 95%; BACKGROUND-COLOR: #CC0000}
    a.dsphead1 {BORDER-RIGHT: #B1BABF 1px solid; PADDING-RIGHT: 5em; BORDER-TOP: #B1BABF 1px solid; DISPLAY: block; PADDING-LEFT: 5px; FONT-WEIGHT: bold; FONT-SIZE: 8pt; MARGIN-BOTTOM: -1px; MARGIN-LEFT: 0px; BORDER-LEFT: #B1BABF 1px solid; CURSOR: hand; COLOR:
    #ffffff; MARGIN-RIGHT: 0px; PADDING-TOP: 4px; BORDER-BOTTOM: #B1BABF 1px solid; FONT-FAMILY: Tahoma; POSITION: relative; HEIGHT: 2.25em; WIDTH: 95%; BACKGROUND-COLOR: #7BA7C7}
    a.dsphead2 {BORDER-RIGHT: #B1BABF 1px solid; PADDING-RIGHT: 5em; BORDER-TOP: #B1BABF 1px solid; DISPLAY: block; PADDING-LEFT: 5px; FONT-WEIGHT: bold; FONT-SIZE: 8pt; MARGIN-BOTTOM: -1px; MARGIN-LEFT: 0px; BORDER-LEFT: #B1BABF 1px solid; CURSOR: hand; COLOR:
    #ffffff; MARGIN-RIGHT: 0px; PADDING-TOP: 4px; BORDER-BOTTOM: #B1BABF 1px solid; FONT-FAMILY: Tahoma; POSITION: relative; HEIGHT: 2.25em; WIDTH: 95%; BACKGROUND-COLOR: #7BA7C7}
    a.dsphead1 span.dspchar{font-family:monospace;font-weight:normal;}
    td {VERTICAL-ALIGN: TOP; FONT-FAMILY: Tahoma}
    th {VERTICAL-ALIGN: TOP; COLOR: #CC0000; TEXT-ALIGN: left}
    BODY {margin-left: 4pt}
    BODY {margin-right: 4pt}
    BODY {margin-top: 6pt}
    </style>
    <script type="text/javascript">
    function dsp(loc){
       if(document.getElementById){
          var foc=loc.firstChild;
          foc=loc.firstChild.innerHTML?
             loc.firstChild:
             loc.firstChild.nextSibling;
          foc.innerHTML=foc.innerHTML=='hide'?'show':'hide';
          foc=loc.parentNode.nextSibling.style?
             loc.parentNode.nextSibling:
             loc.parentNode.nextSibling.nextSibling;
          foc.style.display=foc.style.display=='block'?'none':'block';}} 
    if(!document.getElementById)
       document.write('<style type="text/css">\n'+'.dspcont{display:block;}\n'+ '</style>');
    </script>
    </head>
    <body>
    <b><font face="Arial" size="5">$($Header)</font></b><hr size="8" color="#CC0000">
    <font face="Arial" size="1"><b>Version 1  |M & C | <A HREF='http://mail.exchange.com'>mail.exchange.com</A></b></font><br>
    <font face="Arial" size="1">Report created on $(Get-Date)</font>
    <div class="filler"></div>
    <div class="filler"></div>
    <div class="filler"></div>
    <div class="save">
    Return $Report
    Function Get-CustomHeader0 ($Title){
    $Report = @"
     <div class="dspcont0">
     <h1><a href="javascript:void(0)" class="dsphead0" onclick="dsp(this)">
     <span class="expando">show</span>$($Title)</a></h1>
     <div class="dspcont0">
    Return $Report
    Function Get-CustomHeader ($Num, $Title){
    $Report = @"
     <h2><a href="javascript:void(0)" class="dsphead$($Num)" onclick="dsp(this)">
     <span class="expando">show</span>$($Title)</a></h2>
     <div class="dspcont">
    Return $Report
    Function Get-CustomHeaderClose{
     $Report = @"
      </DIV>
      <div class="filler"></div>
    Return $Report
    Function Get-CustomHeader0Close{
     $Report = @"
      </DIV>
      <div class="filler"></div>
    Return $Report
    Function Get-CustomHTMLClose{
     $Report = @"
    </div>
    </body>
    </html>
    Return $Report
    Function Get-HTMLTable{
     param([array]$Content)
     $HTMLTable = $Content | ConvertTo-Html
     $HTMLTable = $HTMLTable -replace '<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">', ""
     $HTMLTable = $HTMLTable -replace '<html xmlns="http://www.w3.org/1999/xhtml">', ""
     $HTMLTable = $HTMLTable -replace '<head>', ""
     $HTMLTable = $HTMLTable -replace '<title>HTML TABLE</title>', ""
     $HTMLTable = $HTMLTable -replace '&lt;', "<"
     $HTMLTable = $HTMLTable -replace '&gt;', ">"
     $HTMLTable = $HTMLTable -replace '</head><body>', ""
     $HTMLTable = $HTMLTable -replace '</body></html>', ""
     Return $HTMLTable
    Function Get-HTMLLink ($activeURL){
    $Report = @"
    <a href=$activeURL>$activeURL</a>
    Return $Report
    Function Get-Ink ([String]$inData){
    [String]$inclPercentage = @(35..100)
    $positive = ($inclPercentage, 'Success', 'Ready', 'Running', 'OK', 'True', 'Information')
    If ($positive -match $inData)
    $Report = @"
    <font color='#009900'>$inData</font>
    Else
    $Report = @"
    <font color='#FF0000'>$inData</font>
    Return $Report
    Function Get-HTMLBasic ($Detail){
    $Report = @"
    <TABLE>
     <tr>
      <td width='75%'>$($Detail)</td>
     </tr>
    </TABLE>
    Return $Report
    Function Get-HTMLDetail ($Heading, $Detail){
    $Report = @"
    <TABLE>
     <tr>
     <th width='25%'><b>$Heading</b></font></th>
     <td width='75%'>$($Detail)</td>
     </tr>
    </TABLE>
    Return $Report
    $input | foreach {$targets += @($_)}
    If ((Test-Path variable:\targets) -eq $True){
       Write-Host "Server list input detected on pipeline" -ForegroundColor Yellow
    Else{
     if ($auditlist -eq ""){
       Write-Host "No server list specified, getting all Exchange 2007 servers" -ForegroundColor Yellow
       $targets = Get-ExchangeServer | Where-Object {$_.IsExchange2007OrLater -eq $True}
      else
       if ((Test-Path $auditlist) -eq $false)
        Write-Host "Invalid server list specified: $auditlist" -ForegroundColor DarkRed
        exit
       else
        Write-Host "Using Audit list: $auditlist" -ForegroundColor Cyan
        $Targets = Get-Content $auditlist
    $now = Get-Date
    #Custom Expressions
    $latencyMS = @{Name="Latency(MS)";expression={[Math]::Round(([TimeSpan] $_.Latency).TotalMilliSeconds)}}
    $MessageLatencyTime = @{Name="MessageLatencyTime";expression={[Math]::Round(([TimeSpan] $_.Latency).TotalMilliSeconds)}}
    $hotLink = @{Name="URL";expression={Get-HTMLLink ($_.URL)}}
    $colourResult = @{Name="Result";expression={Get-Ink ($_.Result)}}
    $colourStatus = @{Name="Status";expression={Get-Ink ($_.Status)}}
    $colourType = @{Name="Status";expression={Get-Ink ($_.Type)}}
    $newResult = @{Name="Result";expression={If ($_.Result.ToString() -ne 'Success'){Get-Ink ('Failure')} Else {Get-Ink ('Success') }}}
    $fullReport = Get-CustomHTML "Exchange 2007 "
    $fullReport += Get-CustomHTMLClose
    Foreach ($Target in $Targets){
    Write-Host "Collating Detail for $Target" -ForegroundColor Yellow
     Write-Host "..getting basic computer configuration"
     $ComputerSystem = Get-WmiObject -computername $Target Win32_ComputerSystem
     switch ($ComputerSystem.DomainRole){
      0 { $ComputerRole = "Standalone Workstation" }
      1 { $ComputerRole = "Member Workstation" }
      2 { $ComputerRole = "Standalone Server" }
      3 { $ComputerRole = "Member Server" }
      4 { $ComputerRole = "Domain Controller" }
      5 { $ComputerRole = "Domain Controller" }
      default { $ComputerRole = "Information not available" }
     $OperatingSystems = Get-WmiObject -computername $Target Win32_OperatingSystem
     $TimeZone = Get-WmiObject -computername $Target Win32_Timezone
     $Keyboards = Get-WmiObject -computername $Target Win32_Keyboard
     $SchedTasks = Get-WmiObject -computername $Target Win32_ScheduledJob
     $BootINI = $OperatingSystems.SystemDrive + "boot.ini"
     $RecoveryOptions = Get-WmiObject -computername $Target Win32_OSRecoveryConfiguration
     $exServer = Get-ExchangeServer | where {$_.Name -eq "$Target"}
     $exVersion = "Version " + $exServer.AdminDisplayVersion.Major + "." + $exServer.AdminDisplayVersion.Minor + " (Build " + $exServer.AdminDisplayVersion.Build + "." + $exServer.AdminDisplayVersion.Revision + ")"
     switch ($ComputerRole){
      "Member Workstation" { $CompType = "Computer Domain"; break }
      "Domain Controller" { $CompType = "Computer Domain"; break }
      "Member Server" { $CompType = "Computer Domain"; break }
      default { $CompType = "Computer Workgroup"; break }
     $LBTime=$OperatingSystems.ConvertToDateTime($OperatingSystems.Lastbootuptime)
     $MyReport += Get-CustomHeader0  "$Target - Role(s): $($exServer.ServerRole)"
     $MyReport += Get-CustomHeader "2" "Basic Server Information"
      $MyReport += Get-HTMLDetail "Computer Name" ($ComputerSystem.Name)
      $MyReport += Get-HTMLDetail "Computer Role" ($ComputerRole)
      $MyReport += Get-HTMLDetail "Exchange Role(s)" ($exServer.ServerRole)
      $MyReport += Get-HTMLDetail "Last System Boot" ($LBTime)
      $MyReport += Get-CustomHeaderClose
      Write-Host "..getting logical disk configuration"
      $Disks = Get-WmiObject -ComputerName $Target Win32_LogicalDisk
      $MyReport += Get-CustomHeader "2" "Logical Disk Configuration"
       $LogicalDrives = @()
       Foreach ($LDrive in ($Disks | Where {$_.DriveType -eq 3})){
        $Details = "" | Select "Drive Letter", Label, "File System", "Disk Size (GB)", "Disk Free Space", "% Free Space"
        $Details."Drive Letter" = $LDrive.DeviceID
        $Details.Label = $LDrive.VolumeName
        $Details."File System" = $LDrive.FileSystem
        $Details."Disk Size (GB)" = [math]::round(($LDrive.size / 1GB))
        $Details."Disk Free Space" = [math]::round(($LDrive.FreeSpace / 1GB))
        $Details."% Free Space" = Get-Ink ([Math]::Round(($LDrive.FreeSpace /1GB) / ($LDrive.Size / 1GB) * 100))
        $LogicalDrives += $Details
       $MyReport += Get-HTMLTable ($LogicalDrives)
      $MyReport += Get-CustomHeaderClose
      if ($exServer.ServerRole -like "*ClientAccess*")
      {$MyReport += Get-CustomHeader "2" "OWA Connectivity"
       Write-Host "..performing OWA connectivity test"
       $colOWAResults = Test-OwaConnectivity -ClientAccessServer $Target
       $MyReport += Get-HTMLTable ($colOWAResults | select MailboxServer, $hotLink, Scenario, $colourResult, $latencyMS, Error)
       $MyReport += Get-CustomHeaderClose
    Write-Host "..getting queue details"
      if ($exServer.ServerRole -like "*HubTransport*")
      $MyReport += Get-CustomHeader "2" "Queue Information"
      $colQs = Get-Queue -server $Target
      $MyReport += Get-HTMLTable ($colQs | Select-Object NextHopDomain, $colourStatus, MessageCount, NextRetryTime)
      $MyReport += Get-CustomHeaderClose
      Write-Host "..getting mailbox database information"
      $spaceLog=[System.Diagnostics.EventLog]::GetEventLogs($target) | where {($_.LogDisplayName -eq "Application")}
      $db = @{Name="database";Expression={$_.ReplacementStrings[1]}}
      $freeMB = @{Name="MB";Expression={[int]$_.ReplacementStrings[0]}}
      $whiteSpace = $spaceLog.entries | where {($_.TimeWritten -ge $now.AddDays(-1))} | where {($_.EventID -eq "1221")} | select $db,$freeMB
      $ws = @{Name="White Space";expression={}}
      if ($exServer.ServerRole -like "*Mailbox*")
       $MyReport += Get-CustomHeader "2" "Mailbox Stores"
       $colMailboxStores = Get-MailboxDatabase -Server $Target -Status | Sort-Object Name
       $storeTable = @()
       Foreach ($objMailboxStore in $colMailboxStores)
        [string]$totalUsers = (get-mailbox -database $objMailboxStore).count
        [string]$empty = $totalUsers.Length -eq 0
        if ($empty -eq 'True')
         [string]$totalUsers = "0"
        $storeDetails = "" | Select Name, Mounted, "Total Users", "White Space", LastFullBackup
        $storeDetails.Name = $objMailboxStore.Name
        $storeDetails.Mounted = Get-Ink ($objMailboxStore.Mounted)
        $storeDetails."Total Users" = $totalUsers
        $storeDetails."White Space" = (($whitespace | where {$_.database -match $objMailboxStore.Name} | select -last 1).mb)
        $storeDetails.LastFullBackup = $objMailboxStore.LastFullBackup
        $storeTable += $storeDetails
        $MyReport += Get-HTMLTable ($storeTable)
       $MyReport += Get-CustomHeaderClose
       $MyReport += Get-CustomHeader "2" "MAPI Connectivity"
       Write-Host "..performing MAPI connectivity test"
       $colMAPIResults = Test-MAPIConnectivity -Server $Target
        $MyReport += Get-HTMLTable ($colMAPIResults | select Database, $newResult, $latencyMS, Error)
       $MyReport += Get-CustomHeaderClose
       $MyReport += Get-CustomHeader "2" "Mailflow Test"
       Write-Host "..performing Mailflow test"
       $colMailflowResults = Test-Mailflow -Server $Target
        $MyReport += Get-HTMLTable ($colMailflowResults | select TestMailflowResult, $MessageLatencyTime)
       $MyReport += Get-CustomHeaderClose
      Write-Host "..getting Exchange services"
      $ListOfServices = (gwmi -computer $Target -query "select * from win32_service where Name like 'MSExchange%' or Name like 'IIS%' or Name like 'SMTP%' or Name like 'POP%' or Name like 'W3SVC%'")
      $MyReport += Get-CustomHeader "2" "Exchange Services"
       $Services = @()
       Foreach ($Service in $ListOfServices){
        $Details = "" | Select Name,Account,"Start Mode",State,"Expected State"
        $Details.Name = $Service.Caption
        $Details.Account = $Service.Startname
        $Details."Start Mode" = $Service.StartMode
        If ($Service.StartMode -eq "Auto")
          if ($Service.State -eq "Stopped")
           $Details.State = $Service.State
           $Details."Expected State" = Get-Ink ("Unexpected")
         If ($Service.StartMode -eq "Auto")
          if ($Service.State -eq "Running")
           $Details.State = $Service.State
           $Details."Expected State" = Get-Ink ("OK")
         If ($Service.StartMode -eq "Disabled")
          If ($Service.State -eq "Running")
           $Details.State = $Service.State
           $Details."Expected State" = Get-Ink ("Unexpected")
         If ($Service.StartMode -eq "Disabled")
          if ($Service.State -eq "Stopped")
           $Details.State = $Service.State
           $Details."Expected State" = Get-Ink ("OK")
         If ($Service.StartMode -eq "Manual")
          $Details.State = $Service.State
          $Details."Expected State" = Get-Ink ("OK")
         If ($Service.State -eq "Paused")
          $Details.State = $Service.State
          $Details."Expected State" = Get-Ink ("OK")
        $Services += $Details
        $MyReport += Get-HTMLTable ($Services)
       $MyReport += Get-CustomHeaderClose
        $eventLogs=[System.Diagnostics.EventLog]::GetEventLogs($Target) | where {($_.LogDisplayName -eq "Application") -OR ($_.LogDisplayName -eq "System")}
        $warningEvents = @()
        $errorEvents = @()
        $LogSettings = @()
     $MyReport += Get-CustomHTMLClose
     $fullReport += $MyReport
     $MyReport = $null
     $Date = Get-Date
     $Filename = ".\" + "Exchange_Health" + "_" + $date.Hour + $date.Minute + "_" + $Date.Day + "-" + $Date.Month + "-" + $Date.Year + ".htm"
     $fullReport | out-file -encoding ASCII -filepath $Filename
     Write "Audit saved as $Filename"
    Invoke-Item $Filename

    please refer to my scripts below, it should get you started.
    http://www.myexchangeworld.com/2010/03/powershell-disk-space-html-email-report/
    http://www.myexchangeworld.com/2010/07/powershell-script-to-monitor-exchange-server-2010-services-email-report/
    you can customsise this to your needs and add relevant information.
    cheers
    thiyagu
    Thiyagu | MCTS/MCITP - Exchange 2007 | MCSE 2003[Messaging] | http://www.myExchangeWorld.com. This posting is provided "AS IS" with no warranties, and confers no rights.

  • Stored Procedure Call

    Hello!
    My environment: Toplink 9.0.3 / Oracle DBMS 9.2
    I must call a Stored Procedure to compute something.
    The stored procedure has nothing to do with any of my descriptors and has no output parameters. After calling the stored procedure i would refresh some objects in cache.
    The ReadObjectQuery expects output parameters to instantiate an object of the referenced class.
    Example:
    StoredProcedureCall call = new StoredProcedureCall();
    call.setProcedureName("OWNER.KNZ_UTIL.COMPUTE");
    ReadObjectQuery query = new ReadObjectQuery();
    //query.setReferenceClass(?????.class);
    query.setCall(call);
    clientSession.executeQuery(query);
    My question: How can i call a stored procedure, which has no reference class?
    regards
    Harald

    There is a query type called DataReadQuery that doesn't have a descriptor. It will obviously not return objects. Just database rows.
    StoredProcedureCall call = new StoredProcedureCall();
    call.setProcedureName("OWNER.KNZ_UTIL.COMPUTE");
    DataReadQuery query = new DataReadQuery();
    query.setCall(call);
    clientSession.executeQuery(query);
    Hope this helps.
    Peter

  • BT Sports frustration

    "To say i am frustrated would be a huge understatement, i cannot believe the lack of service/ response avaliable from a huge company like BT."
    Here!, here! ..................... I'm not taking the service up when it reverts to full price! All I'm getting, after hours on the fone to Bt.com Sports tekkies (I use that word loosely!), is their broadcast via my freeview TV aerial, but absolutely **bleep** ALL via BT Infinty broadband to my computer. It took a day or so to get their tv service, as they had forgot to switch me on for 6th August (their commited contract date), and we finally got their TV package on the 11 th August.  
    Via the net to my main computer: they query the spec of my Dell computer, however it plays live BBC progs via their desktop i-player @ the drop of a hat, with no stuttering or freezing.
    Whoever is responsible for the release of BT.Com Sports, etc., on "the net", should swing from the highest tree!!!!
    Yes, @ 66 years of age (with plenty of I.T. experience), I am thoroughly disenchanted with BT !!!!!!!!!!!!! 
    I'm also a BT share holder, so I intend to burn the ear of the man/woman @ the top!

    There are some out there getting problems with BT Sport etc that are down to using their own routers that are not compatible with BT's transmission.
    Just be aware that if not using a HH3 or 4 then only a few routers are known to work , eg Billion 7800s and some Drayteks.

  • Burn DVD from Powerpoint

    My teen made a Word 2004 powerpoint presentation, complete with photos and some text, which he needs for a school project. It's pretty snazzy except we can't seem to figure out how to burn a DVD of it. It's readily viewed in QT on the computer.
    Query: How, if possible, can we somehow export this to iMovie or iDVD to burn? Thanks in advance for any suggestions. wd

    This could be a little time-consuming depending on the number of pages but will allow slide by slide control. 
    Open Powerpoint and load the presentation.
    Starting at the beginning display each slide to the full screen
    For each slide take a screen-shot by pressing option, shift and 3 together.
    Close down Powerpoint.
    On the Desktop you will find an image file for each one of the slides you've just taken screen-shots of.
    Open iDVD
    Then follow the instuctions in this article (link) to create a slideshow in iDVD.
    The resulting DVD will play on any player and your offspring can step through the slides using the left and right arrows on the DVD remote control.
    kind regards
    mrtotes

Maybe you are looking for

  • Apple Branded Firewire vs. Generic Firewire

    If I'm using a generic firewire cable to import video, should I expect the video quality to be noticeably lower than if I imported video using an Apple branded firewire cable? I think Apple is charging around $25-30 for a firewire cable and I picked

  • Basic question concernign EJB class

    Hi, I can not understand why a EJB bean class implements methods defined in the remote interface but not 'implements' that interface itself. who 'implements' that remote interface. thanks a lot for your time. Benjamin

  • HT2534 Can't find de option "NONE" on Payment Type... is this tutorial a joke?

    Can't find de option "NONE" on Payment Type... is this tutorial a joke?

  • [Gnome 3.8] Recommended way for upgrade? [SOLVED]

    Hi folks, upgrading Gnome from version 3.6 to 3.8 by using "pacman -Syu" doesn't seem to be the best way to do this. When I gave it a try yesterday, pacman asked me on a lot of packages (Gnome 3.6) if I want to replace them with different packages fr

  • How to run Java codes from ABAP

    Hi Gurus, I have .JAVA & .CLASS files which connect to the website through HTTPS connection and generates the TEXT file at C:\ by obtaining some data from WEB Site. This java files needs SSL certificate Which has been imported in SAP. How can i run t