Determine the compensation period based on the specific date

I'm developing an application in the APEX and need determine the compensation based on an entered date period.  Our pay period is 14 days and pay period 1 begins after the last pay period of the previous year, which started in any day in December (so, for this year, the pay period 1 began January 11, because the last pay period in 2014 began Dec. 28 and went to January 10).  Some years we have 26 pay periods and in a few years, we have 27.  Does anyone have ideas on how to extract the number of pay for something like this using PL/SQL period?

If you store the payperiods inside a table with i.e. four columns startdate, enddate, year and periodnumber. You can easily query on this table.

Kind regards

Mark

Tags: Oracle Development

Similar Questions

  • determine the closest date of you at our days

    Hello all;

    I have a table with the following dates in the table. See code below

    create table t1
    (
           close_date date
    
    
    )
    insert into t1
      (close_date)
    values
      (to_date('22-10-2010', 'DD-MM-YYYY'));
    
    
    insert into t1
      (close_date)
    values
      (to_date('11-11-2010', 'DD-MM-YYYY'));
      
      insert into t1
      (close_date)
    values
      (to_date('29-11-2010', 'DD-MM-YYYY'));
      
      insert into t1
      (close_date)
    values
      (to_date('10-10-2010', 'DD-MM-YYYY'));
    Now, I would like to determine the earliest date you to today. In this example, the answer should be

    29/11/2010

    How can I determine it? Any help is appreciated. Thank you.

    Hello

    Thanks for posting the CREATE TABLE and INSERT statements; It's very useful!

    Here is a variation on the Kendenny solution:

    WITH     got_r_num  AS
    (
         SELECT     close_date
         ,     ROW_NUMBER () OVER ( ORDER BY  ABS (SYSDATE - close_date)
                                      ) AS r_num
         FROM    t1
    )
    SELECT     close_date
    FROM     got_r_num
    WHERE     r_num     = 1
    ;
    

    This can be more effective, and it is certainly more flexible where the requirements change.

  • Determine the specific user permissions for a script

    With a bit of advice from LucD (thanks!), I finished a script simple last night that removes the clones, defines the network cards, takes snapshots, etc to automate a procurement process.

    Initially, I was running the script as a user with limited permissions but frustrating after a few hours, I found that I couldn't see some objects with this user.  I tried (briefly) extend the privileges on the role of the user has been assigned, but I couldn't get the right combination and finally gave up and executed the script as an administrator and it worked.

    I hope that someone will be there to tell me there is a quick and easy to run a Profiler against a script (or look at the server logs) which lists the specific permissions are required when running a script?  I suspect that would save a lot of time on trying to figure out which of the hundreds of privileges must be defined for the user running the script.  If not, I'm going to nuclear dawn somewhat undesirable to administrator.

    Any ideas?  Thank you all!

    The best source for starters is required for routine privileges.

    But take care of is not to create too many roles in your environment.

    For a presentation full privileges (with a short description), you can do

    $authMgr = Get-View AuthorizationManager
    
    $authMgr.Description.Privilege |Select Key,Summary
    
  • Issue by updating the configuration of the specific data of the provider for a virtual portgroup distributed in vcenter 5.5

    Hi all

    We strive to update provider specific data in config spec for a group of distributed virtual ports, we are able to reconfigure the dvportgroup for the first time and data updates are visible in the list of mob (QuerydvsbyUUID). But the second time, if we try to update specific provider we receive error in vcenter below.

    Could not complete the operation due to simultaneous changes by another operation


    The environment we use is as follows:

    Customer vpshere 5.5 ESXi and Vcenter 5.5 5.5.


    We use Vijava to update the specific configuration of the dvportgroup seller (reconfigureDVPortgroup_Task). When we looked this error, we found below thread:

    http://KB.VMware.com/selfservice/microsites/search.do?language=en_US & cmd = displayKC & externalId = 2016329

    But we try to reconfigure the dvportgroup with the root user in VCenter.

    Ask you please let us know if I'm doing something wrong.

    Thank you and best regards,

    Aristides Maximilian


    Found a similar question in the communities,

    https://communities.VMware.com/message/2342966#2342966

    The issue is a bad configversion.

    Using the last ConfigVersion (the real value of the ConfigVersion from the portgroup extraction) in ReconfigurePortgroup_Task worked well.

  • Get all the VMS in givencluster on the specific data store

    Hello

    I need help, filtering of all virtual machines in a given Cluster, which are located on specific data warehouses. I go so far:

    List of all the virtual machines in a given cluster:

    Get-Cluster CLUSTER-TEST | Get - VM

    List all the virtual machines on given data warehouses:

    Get - VM - data store 'TEST-DATA store.

    But when I try to combine these I still have all the virtual machines (also other clusters) on this data store:

    Get-Cluster CLUSTER-TEST | Get - VM - data store 'TEST-DATA store.

    I also found this command:

    Get-Cluster CLUSTER-TEST | Get - VM | % {@{$_ .name = $_.datastoreidlist | %{(get-View-propriété Name-Id $_).}} Name}}}

    It lists data warehouses for all the virtual machines in the given cluster. Now, I need that filter down to a specific data store.

    I need assistance with anyway =)

    With a nested Where clause and some not-so-nice trick PS it seems to work

    $ds = Get-Datastore Test* | %{$_.ExtensionData.MoRef}
    
    Get-Cluster Test-Cluster | Get-VM |
    where {$vm = $_; $ds | where {$vm.DatastoreIdList -contains $_}}
    
  • For the days based on the specific date

    Dear Experts,

    I need help on quick formula.

    Case: -.

    We have entered element value leave_end_date and based on this date, I should be able to get the no. of days.

    For example. If theeave_end_date is August 5, 2015 ' then it should return in 5 days. If 15 August 15, then return 15 days fast formula without creating a custom function.

    I tried this below but impossible to compile the fast formula.

    y = Trunc (to_char (eave_end_date, 'DD' (l)) / * by DEFAULT for y 0 * /

    Your quick response would be much appreciated.

    Thank you.

    Hello 2889916

    Try

    y = TO_NUMBER (to_char (leave_end_date, 'DD'))

    If your salary is monthly... you can also do

    DAYS_BETWEEN (PAY_PROC_PERIOD_END_DATE, leave_end_date) + 1

    There could be some easier ways to do it, based on what you want to achieve.

    See you soon,.

    Vignesh

  • Update of the specific data of the schema in the remote databases.

    I have same application running in places different, each with its own database (gr 10, 2). I want to find solutions to how can I change each database with the data in the other place so that my users of the application can check the status & reports based on data from other sites. There is no physical connectivity between databases in the form of network LAN or WAN.

    The only option, in my view, is to take backup at one location and updated at another location. But the problem is that the names of the diagrams and tables are the same on all sites, that is, the database is designed for Central connectivity to all locations. But after the design of the application, we are forced to use databases distributed without any connectivity between sites.

    We cannot use direct import/export or impdb/expdb because the schema name and the tables are the same in all locations.

    Is it possible to record/track DML statements on my specific sites with timestamp scheme so that these DML can be used as a source of data import. There are a lot of tables in my diagram so I need a solution more widespread rather than write triggers on each table.

    I also checked Oracle Audit and I want some sort of solution so that I can manage without the support of DBA in each location.

    If I reframe your question will be it seems like below:

    User: UserA
    Database: Db1
    Location: Loc1

    User: UserA
    Database: Db1
    Location: Loc2

    You want to synchronize/keep the latest information in databases without:

    1. connectivity.
    2.Import/Export
    3 oracle DBA

    Right?

    If Yes, then
    DML trigger will fill a new table in the two locations, that will all the new values that a user made on one site. Now in the other place, this table will be sent to run a pl/sql block using this table and fill in the data.

    On the other
    What is your question, we need more details.
    End if

    Concerning
    Girish Sharma

  • How do you determine the VI file specification in executable?

    Under LabVIEW 2010, how can I determine a specification of file full of screws that he resides in a built executable file?  I have location of the executable file and I have the location of the screws on the drive when the executable was generated.  I hope that it has a property of LabVIEW that will tell me the specifications for each file in the executable.


  • Customization of the emailing of the alerts based on a specific group of servers?

    Hello

    I'm wondering how to set up electronic mail based on a specific service of Foglight? For example, I know that I can put "SYSADMIN" to an e-mail address and it becomes the email address golbal all alerts are sent to.

    What I want to do, is keep global electronic mail as address, but take a few exclusions and have another set of servers to a diffferent e-mail address e-mail.

    In this example I am using services that I created my groupings. For example, I have a FSM Service called "DHCP servers" I want alll alerts for servers in this group to go to another email address that defined globally in the sysadmin variable e-mail address.

    Here's what I've tried, but alerts are not sent to "[email protected]".

    How to achieve this?

    Thank you

    Tony

    Hello Tony

    This can be done with a service (as far as I know), but my requirements were much simpler.  I had three machines CRM and CRM team wanted to know when CRM Windows services had problems.

    At the end of the day, I used two - general rule of 'The host Services' and a specific rule of 'Hosting CRM Services' rules.

    My "Host Services CRM" rule has the following in the rule definition:

    HostService where monitoredHost.name = "crm1.mycompany.com" or monitoredHost.name = "crmapp01.mycompany.com" or monitoredHost.name = "crmapp02.mycompany.com".

    There is a variable in the Conditions tab, alarms & Actions for registry ("NewAddress").  In the registry, "NewAddress" is essentially "SYSADMIN" from the e-mail address for the CRM team.

    To avoid duplicate emails, 'Host Services' rule has the following in the definition of the rule to exclude CRM systems:

    HostService where monitoredHost.name! = "crm1.mycompany.com" and monitoredHost.name! = "crmapp01.mycompany.com" and monitoredHost.name! = "crmapp02.mycompany.com".

    I'm sure (but does not ) that you can change monitoredHost.name to something like service. Name it extended to a service.  Obviously, it would be preferable to application domain service so that you don't have that one place to update unlike me, but my customizations refer only to three systems with two rules, so it's easy to keep up-to-date.

    I hope this helps for you an overview on how to attempt it.

    Brian

  • Please how can I create a page based on template and save in the specific folder.

    Please, I spent two days trying to solve this problem.  Here's the situation.  I'm trying to create a Web site for our school.  I created a master template which I intend to use as a base for each teacher's webpage.  I also created folders for each teacher, teachers had to send me their weekly updates what duties inlude, photos and downloads.

    Here's the problem: whenever I have to create a page based on the template of the page is created in the root folder.  There is no way to create pages in the files of specific teachers.  I save the page and try to drag to the respective folder.  When I try to save the file, Dreamweaver he re-recorded in the root folder.  If I try to view the html file in the folder of the teacher that the overview does not load.  I have three books of refernce DW, including the Missing Manual and no of them don't address this problem.  Neither is Adobe.

    Surely someone here created a page based on a template and placed in a folder without breaking all the paths.  Why DW does not provide a way to save a page template based in a specific folder.

    Thank you all for responding.  The problem was that I was using DW on my macbook.  To access save as function I finally understood that you must click on the small triangle next to the name. not the Favorites or recent locations triangle.  Lost two days trying to understand cela.  Incredible.

  • Calculate the attribute (entity) Total value based on a specific entity

    I'm writing a calc that will calculate a total based on an attribute (entity) and based on a specific entity. I am currently able to calculate the total value of the attribute by using @SUM (@ATTRIBUTE (attrmembername)). I tried specifying the entity specifi in DIFFICULTY, but it is still calculating the total of the entire dimension, rather based on a specific entity. I would greatly appreciate any suggestions. Thank you!

    Use the @REMOVE function to exclude members that you do not want. The FIX is not your problem. Within the function, when you call @ATTRIBUTE, you get all basic members associated with this attribute.
    So in your @SUM function that you must exclude members you won't be part of the sum.

    Suppose you had a structure where you had a '1' attribute that has been associated with several children of 'A' and 'B', but in your sum function, you want only to the sum of the members who have the '1' attribute, AND are children of "A". If you want to exclude with the attribute members that are under the 'B '.

    @SUM (@REMOVE (@ATTRIBUTE("1"), @CHILDREN ('B'));

  • Determine the version of the OS product key

    It is:

    Can the version [XP, Vista, WIN7, WIN8} of the OS, not the type (as in 32-bit or 64-bit), determined by the product key and if so, where to enter this product key?]

    I arbitrarily chose WIN7 version.

    No, you will need to have the specific edition and version installation files to install and activate using the product key.

    If Windows 7 is already installed and you are sure it's the right edition:

    Click Start, right click on computer

    Click on properties

    Scroll to the bottom of the window

    Click on change product key

    Enter the new product key.

    Click Start, right click on computer

    Click on properties

    Scroll down to Windows activation.

    You will notice it displays a time until Activation but completed. The product ID also indicates that he uses a default key, it is only for the 30-day grace period allowed until you have to activate Windows 7.

    Click the change product key link

    Enter the product key located on the COA sticker that is located downstairs or (sometimes in the battery of your laptop), you can also find it at the top or the side if it's a desktop computer.  It looks something like the following:

    Proceed to enter the product key and click Next

    Wait while Windows is trying to activate.

    If all goes well, less than a minute, you should see this screen.

  • Determine the maximum use of the processor for a virtual computer in the custom user interface

    I want to determine the maximum use of the processor for a virtual computer in the custom user interface.  How can I do this?

    If I use a supermetric, there is no kind of attribute under CPU called "maximum use.

    Certainly, you get points for a long question! Although to be fair, it's probably my fault to feed you so much information to digest at once.

    1. I would say you can do two ways visually. Use the operations > detail view for 'normal ranges' use the upper limit of the normal range as your typical max. You want an absolute peak, add the metric of a graph or observe that highlight high and low watermarks.

    2. There are a lot of ways to display data, but if you want to display a single metric over a period of time, we could use the following widgets [on top of my head]:

    Top - N analysis

    Weather map

    Analysis of distribution of data

    Among these, I think of your desire for a "peak". Who you want real value, which eliminates the weather map. Then, I think that the concept of a 'Summit' and what is the best thing, I think that the 95th percentile... then I came with the widget of data distribution. The decision is ultimately yours given your particular use case.

    3. you can have it apply to several virtual machines - it's just a widget capable of being an independent provider or receiving widget (metrics, DO NOT choose to select resources). Each resource/metric will add to the widget and you can remove them if you like after it is added. You can certainly all the time you visit... It is date and time standard options you have in all the other widgets chart. With the widget data distribution, you want as much time as possible to get an accurate histogram of the cycles of workload.

    4. This is similar to the question above. You can certainly add parameters of individual resource or a DM that summarizes or AVG groups of resources. And as above, the delay is configurable, along with the other graph widgets.

    5. it's part of Q4 - you can sumN or avgN up to any number of resources with a SM, then discovers that SM in the widget of data distribution. When I said container, I mean an application, group resource pool... all that acts as a container parent within the vCOps.

    6. that's correct, SMs calc using data collected last points... aka single period of time. When you are referring to the longest period, I gave you a few examples of the attributes that are composed of several periods of time which are calculated and created by the adapter for VMware vCenter behvaior. In this case, you have the GVA 15 min CPU 1.5; These specific simple mobile GVA can be specific OR a copy using SMs. Next, you will have the chance is to find a way to distribute what you need through a widget [at that time].

    7. the distribution of data is not for export, it is for Visual functions. If you want the data in CSV, just use a typical chart of metrics and export to a csv and calc your own pics, avg, 95th, whatever.

    8. This is a bit of a mix of all your questions, put in place.

    You are right, if you added those 3 VMs, then calc was the 95th of the AVG. Like Q7, you would not export the data of the distribution of data because the raw data points are not - you do not pass the metric to a metric graphics standard and export via csv.

    Take advantage of...

  • Determine the GLU selected on the calculated extended attribute

    The computation of the results based on values with different units of measurement (UDM), how can I know the unit of measure defined on a calculated digital extended attribute? For example, to get the values target in inches, if I calculate volume length * width * height will produce a value in cubic inches. If the extended attribute GLU has cubic feet, then I need to covert the returned results in inches cubic to cubic feet. The question is, I can determine the unit of measurement for the digital extended attribute computed in the calculation script so that I can calculate the value of the correct unit of MEASURE, or do I have to use a custom calculation class?

    The calculated environmental assessment can have a specified unit of MEASUREMENT, which means that if your calculated EA is Volume, configure you it with a specific unit of MEASURE (for example, cubic feet). Therefore, your JScript can ask values EA of the length, the width and height to return to the unit of MEASURE you need (feet)

    length of var @ GetCellInMyRowByColumnID ('LENGTH'). Value.GetNumericValue ("pi");
    var height @ GetCellInMyRowByColumnID ('HEIGHT'). Value.GetNumericValue ("pi");
    var width @ GetCellInMyRowByColumnID ('WIDTH'). Value.GetNumericValue ("pi");

  • Determine the only original installed OS

    We have approximately 31 HP notebook computers that are running Windows XP. I know that many of them have been downgraded from Windows 7 purchase. I am trying to determine which machines are licensed for Windows 7 to upgade the OS on them. The problem is, many of them are on our remote sites in other States, so I am unable to view the stickers on the laptop to see the original OEM operating system. Is there a way I can find this information remotely without appeal of each user and ask him to look at the thumbnail? I have the serial number for all machines. Can I get him somehow with that?

    Ender174

    Welcome to the Community Forum of HP.

    Ideas

    I suggest that you might find information on the original purchase of equipment orders.   If the PDS do not have the information, recipes and the documentation that comes with it can list the operating system installed as well as relevant software delivered with the order.

    If you purchased the HP computers, once again using the original op for orders, and if the information you are looking for are not on the actual order form, then you might be able to contact HP and get information from HP.  I suspect that HP keeps records of this type for a long time, even if it may take some digging if the records are on paper and not digital.  The smile.

    Contact telephone support HP - USA-

    HP technical support / Customer Service phone numbers - some English Speaking countries

    ===========================================================================

    If you have the product number (s) for laptops, you can look up the support of each notebook page.  Assuming that there is a Page of specification for the laptop, it can indicate the origin of operation installed on the specification as well as other installed software Page.

    HP drivers & downloads

    Enter the laptop information > Troubleshooting tab > Product Information

    Click on the Thumbs - Up Kudos to show that you appreciate the help.

    Click on accept as Solution when the answer is a good solution or workaround!

    Although I strive to reflect best practices of HP, I do not work for HP.

Maybe you are looking for

  • Cannot install on Vista Home edition OS MS Charts

    Installed Microsoft.net framework 3.5 SP1. Tried to install MS and continuousy cards received the fatal error "MS. NET Framework 3 has stopped working". AVG Unistalled and reinstalled the files but still have the same error. Troubled tour and got err

  • How to remove/disable liquid acer home if the country is not supported for update app

    Hello Recently ordered (imported) the Acer Liquid zest 4G. Beach is very good, but I want to disable the Control Panel Home Acer Liquid. I read the solution is to update the application, but the app is not not in my country how can I get around this

  • Error: "printer does not" (105-100003)

    Original title: PRINTING from MY COMPUTER I INSTALLED A NEW KODAK PRINTER. HAD THEWIFI TO WORK, BUT IT WON'T PRINT FROM MY COMPUTER. I GET THE ERROR CODE: Error: "printer does not" (105-100003) WHAT I will DO, I DONOT UNDERSTAND DIRECTIONS Help me

  • BlackBerry smartphones disable rich content and Images online

    How can I disable the rich images of content and online on my personal BB? You will need to strip emails transferred to BB from my personal email account. Help!

  • My copy of Windows 7 Pro is real?

    I just got burned by what I'm pretty sure is a false copy of Win 7 Home Premium.  This has led me to question the forest of Win 7 Pro 64 (OEM), I have installed on my newer PC. The disk in question has a white screen with black letters.  It also has