Schedule/ db Query

Hello,
At the moment I'm trying to build a webbased
timesheet/schedule program. However I have a question about how to
get the results ordered on the webpage. What I would like to show
on the webpage is a table with the results for a week. I would like
to use the days as the heads of the columns; mo u we th fr sa su.
For each day I would like to show the employees that are working,
and the time IN and OUT that day. How is this possible? Is it
possible? Some employees work on monday, some every day, some 2x on
differend times in a day...
Also in the weektable I only want to show the results for a
specific department.. Hopefully it is understandable what I mean...
I use the following query:
SELECT c.*, u.*, l.* FROM cal AS c
LEFT JOIN usrs AS u ON c.u_id = u.u_id
LEFT JOIN lo AS l ON l.l_id = u.lo WHERE WEEKOFYEAR('') =
$weeknumber
The I get a couple of rows with results for the employees,
but not how I would like it.. HOw can I display it on the site the
way I want? Or is this only possible when I do a query per
day/column? But then again, another problem; how to show that in a
table then?
Thank you in advance.
Regards,
Kabbi

yes there are few
In 11g you get sql resultset where in 10g only tcResultSet
use below
Connection con=Platform.getOperationalDS().getConnection();
Statement st=con.prepareStatement(query);
ResultSet rs=st.executeQuery();, execute, executeUpdate
you can PreparedStatement also instead of Statement for complex query
use like sql
you can go through below link
OIM Task to reset users password automatically in 11g
Edited by: Nishith Nayan on Feb 23, 2012 7:32 PM

Similar Messages

  • Error message "Error when scheduling the query(JOB_CLOSE)".

    Hi all,
    While using query extractor (rscrm_bapi) I am getting error message "Error when scheduling the query(JOB_CLOSE)".
    Could you please find what this error is?
    Thanks,
    Uday.

    Hi Uday,
    This problem can occur if you changed the query definition.
    In this case the query definition would be inconsistent with the existing extract structure.
    Certain Meta information is maintained with each extract defined using the RSCRM_BAPI. If the definition of the query is changed and you need to use the same extract table then you need to delete the extract using the report RSCRMBW_DEL_ALL_EXTRACTS selecting the extract you want
    to delete.
    After this you could use the same table name for any further extract that you need to create.
    One caution is that the extract table should not be deleted through any other transaction before you run the report.
    Rgds,
    Colum

  • Schedule a Query with Type "File"

    Hi All,
    We're currently facing an issue when a user schedules the query and selects the Type as "File" and DOES NOT enter the Output Destination. Though the message log says that the report has been successfully published, no report has been published. Message Monitor also does not show a Sub Contract.
    To work around this scenario, we requested the Users to enter the UNC path while running. That also has not resolved the issue, as I can see the file physically located in that UNC path provided during the run, but it is neither visible in the View/Log Trace nor is it available in the Report Manager. I also don't see any Sub Contracts for PSRF ... The report manager seems to be working fine, as all other reports are being posted.
    We're on PT 8.47.11...
    Thought of raising it here prior to creating an SR..
    Any help would be appreciated!!
    Thank You
    Prashant

    If the output type is File then the report will not be posted to the report repository. If the file is not being written to the UNC path, and you have configured your process scheduler as a Windows service, make sure the BEA ProcMGR service is not running as the Local System account. Change the service properties to log on as a specific user account and make sure the user has permissions to write to the UNC path.

  • How to schedule refresh query in webi?

    Dear Experts,
    I'm facing problem on how to set schedule refresh query and disable refresh function for End User in WEBI. The problem is that each time of refreshing query it'll take long time and I just don't want end user to endure this painful waiting. I used universe connection in IDT.
    Please give me some suggestions or ideas to deal with this problem.
    Best regards,
    Chenna Yon

    Dear Gill Leo,
    I would like to thank for your help.
    My problem was fixed.
    Best regards,
    Chenna Yon

  • Scheduling Bex Query

    I've been reading the docs. on the reporting agent and I'm still not understanding how to set this up. My goal is to populate the Global Cache with query data.
    I have developed several Bex Queries with 2 selection variables. I have also created a variant for these.
    How can I schedule this query to run each morning possibly after the nightly loads are completed.
    Thanks
    Richard

    Hi,
    Basically under Reporting Agent --> you have to create 'Scheduling Package' for your web template with one given setting.
    Then this can be included in the Process chain for daily scheduling.Use the Process type "Precalculation of Web Templates" and provide your scheduling package.
    The start time will be the start time of the start process.
    Please see below,
    http://help.sap.com/saphelp_nw04/helpdata/en/9e/9f653ade969f4de10000000a114084/content.htm
    Thank you
    Arun

  • Schedule adhoc query

    We want to use Personal ids to record work permits. In this infotype you can enter a valid to date.
    Can we create an adhoc query which can select all data where the valid to date is within the next 90 days ?
    Can we schedule this adhoc query so that it runs nightly and sends the report to a given email address?

    Hi,
    For this you have to use background job processing and workflow..
    Regards,
    Kapil Kaushal

  • Materialized views - schedule, indexes, query rewrite, etc.

    I'm trying to get the hang of materialized views and need some help . . .
    running Oracle 10gR2
    I created a materialized view as follows:
    CREATE MATERIALIZED VIEW "MY_SCHEMA"."USERS"
    AS
    SELECT * FROM "USERS"@PRODUCTION -- to copy the USERS table from my production database to this database
    Worked fine. So far so good. Then, I altered it to schedule the refresh:
    ALTER MATERIALIZED VIEW "MY_SCHEMA"."USERS" REFRESH FORCE START WITH SYSDATE NEXT TRUNC(SYSDATE + 1) + 4/24
    -- to schedule a refresh immediately (SYSDATE) and every morning thereafter at 4:00 am (I think)
    then, I wanted to enable query rewrite, so I issued the following command:
    ALTER MATERIALIZED VIEW "MY_SCHEMA"."USERS" ENABLE QUERY REWRITE;
    and I got the
    ALTER MATERIALIZED VIEW succeeded.
    message for both of those commands (I'm doing this in SQL Developer).
    Then, I edit the materialized view in SQL Developer, click on the 'SQL' tab, and get the following:
    CREATE MATERIALIZED VIEW "MY_SCHEMA"."USERS"
    ORGANIZATION HEAP PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255 NOCOMPRESS LOGGING
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "TBLSPC_PHIGH"
    BUILD IMMEDIATE
    USING INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255
    STORAGE(INITIAL 65536 NEXT 1048576 MINEXTENTS 1 MAXEXTENTS 2147483645
    PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1 BUFFER_POOL DEFAULT)
    TABLESPACE "TBLSPC_PHIGH"
    REFRESH FORCE ON DEMAND START WITH sysdate+0 NEXT TRUNC(SYSDATE + 1) + 4/24
    WITH PRIMARY KEY USING DEFAULT LOCAL ROLLBACK SEGMENT
    DISABLE QUERY REWRITE
    AS SELECT "USERS"."User" "User","USERS"."Logon" "Logon","USERS"."Name" "Name","USERS"."Password"
    "Password","USERS"."Level" "Level","USERS"."Producer" "Producer","USERS"."Deleted" "Deleted","USERS"."ClaimDoctor"
    "ClaimDoctor","USERS"."UserType" "UserType","USERS"."Locked" "Locked","USERS"."Scheduler"
    "Scheduler","USERS"."RestrictDays" "RestrictDays","USERS"."First" "First","USERS"."DisableAutoChart"
    "DisableAutoChart","USERS"."MaxChartOut" "MaxChartOut","USERS"."MaxHoursOut" "MaxHoursOut","USERS"."EffDate"
    "EffDate","USERS"."ExpDate" "ExpDate","USERS"."SwipeLogon" "SwipeLogon","USERS"."SwipePassword"
    "SwipePassword","USERS"."PwdLastChanged" "PwdLastChanged","USERS"."Audit" "Audit","USERS"."IsInstructor"
    "IsInstructor" FROM "USERS"@PRODUCTION.REGRESS.RDBMS.DEV.US.ORACLE.COM "USERS";
    The problems I've encountered so far:
    1) I created this two days ago and changed the value of one column in one row in the 'source' USERS table
    (USERS@PRODUCTION) as a test case. So far, that change has not propagated over to my materialized view even though
    it has had two chances to do so (yesterday morning at 4:00 am and this morning at 4:00 am).
    2) I enabled QUERY REWRITE. Why does it still show DISABLE?
    3) The primary key of the table came over (as far as I can tell) because it shows in SQL Developer. However, the
    indexed columns are no longer indexed. Do I need to recreate those indexes manually and will they persist?
    4) As you have guessed, I have just taken the plunge into materialized views, and have not been able to find
    anything on the Web along the lines of 'Materialized Views for Dummies'. So, any and all advice/suggestions/help
    will be welcome.
    Thanks,
    Carl

    The Refresh would be executed by a job submitted in the background.
    Query USER_JOBS (or DBA_JOBS) to see if a job has been submitted and if it has been running (you'd be able to see LAST_DATE, LAST_SEC and NEXT_DATE and NEXT_SEC). \
    If the Refresh job has been failing the FAILURES count would be incremented. If there are 16 consecutive failures, the job is marked BROKEN. (if a job fails, Oracle retries it automatically and keeps retrying till it is BROKEN). If the job has been failing you would get messages in the database instance alert log file and trace files.
    If the Refresh job has not been running check the parameter value for JOB_QUEUE_PROCESSES -- a value of 0 would not run in jobs in the USER_JOBS/DBA_JOBS view. Ask the DBA to increase set this parameter to at least 1.
    Hemant K Chitale
    http://hemantoracledba.blogspot.com

  • Schedule sql query

    Dear all,
    I need to schedule some queries (audit related) running at certain time of the day. I can do this using unix shell script.
    can this be done using oracle scheduler - just running a simple sql query and not using pl/sql block
    for ex: 4.1.     select * from dba_stmt_audit_opts where audit_option like '%TABLE'
    kind regards
    thanks
    SL

    You can not schedule a select statement using dbms scheduler. It should be either pl/sql block or os script.
    Edited by: oracle.beginner on Apr 15, 2010 5:23 AM

  • Schedule a Query Refresh

    Hi ,
    In BW 3.1 is there anyway to schedule a job refresh a workbook automatically in the background . Can reporting agent be used to acheive this functionality ? I also would like to access the refreshed query from the document store and send it as an email attachment . I know that 3.1 does not support information breoadcasting , but can it be achieved programmatically ?
    Any document links that provided more details on this would be appreciated .
    Thanks

    This is the point-of entry for reporting agent in general:
    http://help.sap.com/saphelp_nw04/helpdata/en/28/734d3caa70ea6fe10000000a114084/frameset.htm
    For the precalcullation of HTML-reports:
    http://help.sap.com/saphelp_nw04/helpdata/en/9e/9f653ade969f4de10000000a114084/frameset.htm

  • Scheduling BW Query to store data as CSV file on server

    Good Morning,
    I have a user requirement to schedule a BW query using the Reporting Agent but to store the results in CSV format on a shared network drive rather than printing out the contents. Is this possible? I'm using BW 3.0
    Many thanks in advance.
    Mike

    Hi Mike,
    Refer thez link below regarding Openhub
    http://help.sap.com/saphelp_nw04/helpdata/en/ce/c2463c6796e61ce10000000a114084/frameset.htm
    · BW Open Hub (ppt)
    https://websmp204.sap-ag.de/~sapidb/011000358700002201112003
    · BW Open Hub - Transcript (doc)
    https://websmp204.sap-ag.de/~sapidb/011000358700002320152003
    How to guide on RSCRM_BAPI
    http://help.sap.com/saphelp_nw04/helpdata/en/49/7e960481916448b20134d471d36a6b/frameset.htm
    https://forums.sdn.sap.com/click.jspa?searchID=3318270&messageID=3626098
    hope it helps

  • Schedule Line Query

    Hi All,
    I have come across a unique situation at this moment of time.
    The issue is with Schedule Line Determination -> In one of the many faulty sales orders { due to which period closing has stopped - mismatch of data} the schedule line category is getting determined eventhough the assignment {Item Category + MRP type} is missing in schedule line determination in SPRO !!!! The only problem is not the schedule line category.. but there are @ 7 line items in sales order {free issues} and there is one Z-table which would determine the movement type in these free issue depending upon Sales area + WBS + Order Reason.. out of these 7 line items only for one item movement type 973 {free issues} is getting determined which is right... but for others 601 is getting determined... which is weired !!!
    Any one has some idea about this strange thing ???
    Await your valuable comments
    Hrishi

    Hi,
    The old orders can't be deleted as they are lot in numbers and already posted to FI.
    Now, I have simulated the case with same line items and one interesting thing which I've observed is as below:
    - Created SO with order reason which is NOT there in the Z-table { didn't press enter yet}
    - Entered only one line item with quantity
    - Pressed enter
    - Went to see the schedule line {sch. line category CP got determined} -> procurement to see the movemet type
    - The movement type is 601 which is getting picked up from CP
    - Then changed the order reason to the one which is THERE in the Z-table
    - Entered second line item with quantity
    - Then pressed on ENTER
    - I got below error message
    > Item 000010: Movement type conflict with order reason.
    >Message no. ZV01003
    >Diagnosis
    >During entry of 'free issues', if there is an entry in table ZVFREEISSUES for the sales area and order >reason, the schedule line movement type is redetermined by a user-exit.
    >If the order reason is changed after items have been entered, the user-exit cannot overwrite with the >correct movement type from ZVFREEISSUES.  In this case a warning message is output.
    >Procedure
    >Ensure that the order reason is entered BEFORE creating any items. Delete and recreate any items >that were entered before the order reason was last changed.
    - Now when I cancelled the error message, surprisingly I was able to create the order !!!
    - When I went to see the order I could see that two line items are having different movement types !!!
    - So, I believe this is where the probelm lies now which needs to be checked with an ABAP guy which I am doing now.
    Now, I am closing this thread and I'd like to thank all of the members who were involved in this issue for lot many days...
    I will post the route cause in this thread itself once it gets figured out which may be useful for everyone if in future someone else faces this kind of problem...
    Thanks again for all of us...
    Have a great day ahead to you all.
    Hrishi
    Edited by: Hrishikesh Bhalwankar on Dec 9, 2008 12:25 PM

  • Schedule fields query

    Hi guys,
    Can someone tell me where the values for the custom fields in the Microsoft Project Professional 2010 schedule are stored in database? Which table in Project Server 2010 stores the values for fields in the schedule?
    I want to read these values and use them in some custom application.
    I just discovered that the table that contains the names of all the custom fields used in the schedule is MSP_WEB_VIEW_FIELDS table in Draft and Reporting databases. But the question is which table actually stores the values for these fields?
    Thanks.
    Regards
    Kwazi

    Hi Kwazi,
    The following user views include custom field data that the RDB extracts from the column pool tables
    MSP_EpmAssignment_UserView
    MSP_EpmProject_UserView
    MSP_EpmResource_UserView
    MSP_EpmTask_UserView
    MSP_TimesheetLine_UserViewCF
    This
    article should answer your question about finding custom fields in the reporting DB.
    Note that multi-value custom fields are managed differently: you will have a specific view for each Multiple Choice Custom Field named MSPCFPRJ_<CustomFieldName>_AssociationView.
    Hope this helps,

  • OIM Schedule task query

    Hi
    I have installed two separate weblogic servers (non-cluster) and installed OIM 9101 on them with same Oracle Database. This system does not include any other servers. I am planning to use a hardware load balancer on top of these two OIM Weblogic servers.
    I have deployed EBS trusted source recon connector. This connector has a recon schedule task which run at every 6 hrs. It was working fine on single node OIM weblogic pair. Now I have two weblogic servers with corresponding OIM servers. I wonder how the schedule task will work now. which OIM will have the priority ??
    any idea about this..

    Disable schedule task in one of the servers, so that it does not account for running schedule purposes. Go to xellerate/config/xlConfig.xml
    You can find the scheduler section and change the StartOnDeployment parameter to false. SO that this server never runs the scheduler.
    Suren- The database is same ! ! !
    Thanks
    Sunny

  • Work scheduling view query

    even though i have made settings in customisation i am unable to get work scheduling view while creating material master can you explain me why?

    Hi
    Have you maintained  in SPRO->Logistics-Genral->Material Master->Basic settings->Define atributes of material types
    workscheduling view for the new material type.
    please check and come back.
    Regards,
    srihari.M
    Edited by: Srihari.M on Apr 21, 2011 6:52 AM

  • Job Schedule (SM36)  query

    I have a requirement:
    I want to process something (Send a mail to the user) once a job is finished / cancelled / Errored.
    I think one way of doing this is create a new step in the job and process it depending on the status of earlier step (But I doubt whether this can be achieved).
    Is there a way of doing conditional exceution of any step (i.e The execution of a step  depends on the success/ failure of earlier steps)
    Is there a better way of achieving this?
    Thanks
    Amit Jain

    Thanks for your replies,
    To be specific.. I have 30 jobs and if any of the 30 job errors (Status: Cancelled), a mail needs to be sent.
    Some options I think of is:
    1> create 30 new jobs which depends on the status of original 30 jobs and my job triggers only if the corresponding original job errors (Is there a way to accomplish this and how?)
    2> Create an additional step in each 30 original job. This step should execute (which sends an email) if and only if any of the above steps has errored.
    Can this be accomplished and how?
    Thanks
    Amit Jain

Maybe you are looking for

  • Migrating HD Express to MacPro

    This is my first post to this forum, so forgive me if this topic has been covered previously (could not find answer in archive). I have Final Cut Express HD running on a Powerbook G4. When I migrate this machine to my new MacPro, will FC Express HD s

  • Mktime error in awk on Snow Leopard

    Is mktime not working in Snow Leopard awk (version 20070501)?  I get the error: "awk: calling undefined function mktime" when I run a Bash script with: "awk '{run=$1; start_time=mktime($2" "$3" "$4" "$5" "$6" "$7)}".  It worked on other boxes, but I

  • Webcam 3 driver in vista

    Hi, i have an old creative webcam called "webcam 3" and i'm trying to make it work on vista. is it possible? Thanks.

  • Adobe Illustrator CS4 Auto Trace

    Hey everyone. I'm trying to convert some BMP or JPEGs into a nice vector. I've been reading around and it seems like auto trace is the function I want however I'm unable to find that tool in Illustrator. Can anyone help guide me to where this tool mi

  • RV220W Wireless Guest Network

    I have two RV220W (one is the main router and the other is acting like an access point). The main one [192.168.1.1] is located in our server room so wireless signal from there is very limited. The access point [192.168.1.2] is in the main reception a