Replace the values in the channels, if a string has a model value

Version: Oracle 10g

Hi all, I have a need for which I am trying to write a proc.
I wanted to know if there is an another easier way to do this.
Please let me know


T_DATE and v_value will have an equal number of values
If the value T_DATE or v_value is = # remove this T_DATE value and the corresponding value
v_value (and vice versa)
Example 1:
-------------
   v_date  
      := 'August, 16, 2010~August, 16, 2010~September, 17, 2010~August, 16, 2010~###';
   v_value   := '###~EFGH~IJKL~MNOP~QRST';
   
   O/P required :
   v_date := 'August, 16, 2010~September, 17, 2010~August, 16, 2010';
   v_value   'EFGH~IJKL~MNOP';
   
Example 2
----------
  
   v_date  
      := 'August, 17, 2010~###~September, 19, 2010~###~August, 21, 2010';
   v_value   := '###~EFGH~###~MNOP~###';
   
 O/P required :
 ---------------
   v_date := NULL;
   v_value   NULL;
Thank you

Hello

new learner wrote:
Version: Oracle 10g

Hi all, I have a need for which I am trying to write a proc.
I wanted to know if there is an another easier way to do this.

Easier than what? Post what you're doing now.

It seems simple enough
Are T_DATE and v_value are IN OUT parameters?
(1) create new variable this_date, this_vlaue, new_date and new_value, NULL string initially.
(2) loop while T_DATE and v_value are not NULL.
(3) use INSTR to find date_pos, the position of the first delimiter in T_DATE.
(4) set this_date: = SUBSTR (T_DATE, date_pos, 1, -1) and then T_DATE: = SUBSTR (T_DATE, date_pos + 1). Watch out for the special case when you are at the last iitem, and there is no delimiter in v_pos.
(5) do the same thing with v_value, this_value, and new_value.
(6) If is neither this_date nor this_value ' #', concatenate them (with a delimiter, if necessary) to new_date and new_pos.
(7) repeat the loop.
(8) Finally, set T_DATE > = new_date and v_value: = new_value.

Tags: Database

Similar Questions

  • move a channel? replace the channel of the color by another way?

    -actually a double question, two closely related themes. In an RGB image, I have to move all the pixels of a channel (as I suggest a whole layer) using the move tool (selection of the channel in the channel Panel). Which is impossible. (First two questions: why this is impossible and how I make it possible?). And as a solution, I thought that I could duplicate the channel, move its contents (which is possible) and use it to replace the original (call a new one as the old one, of course). But no! Cannot do it either. If I do, instead of the RGB channels, red, green, blue, red copy, I get, Magenta, yellow, red. I don't really understand, and can't find anything about it.

    I would be grateful for any source or the same explanation.

    You should be able to move channels if the image is flattened.

    Even without flattening the image, you should be able to copy and paste

    a duplicate or new channel to an existing channel.

    MTSTUNER

  • replaced the original HD, PC guy has no partition, damaged BONES now, how do I reinstall the OS?

    Compaq Presario SR1511NX desktop PC

    Windows XP preinstalled, no software disc.

    I did all of the recovery disks, pc tools disk, over such implementation suggested by the Troubleshooting Guide.

    (A neighbor) PC Repair guy replaced the hard drive, it did not include a drive partitioned and first attempt (mirror) as he called it, the old drive with the OS on the replacement drive is not ended, he had to try a second time, he seems to be ok, but got progressively worse and recently acted as he hada virus or more , all scans were clean, and now every attempt to "fix" it killed instead. I tried the recovery disks, but wasn't smart enough to know that they would not work on a different hard drive. Can I wipe the hard drive and reinstall the XP operating system, all my files were backed up before the hard drive replacement. How to re - install OS with no disc?

    QUOTE: "I tried the recovery disks, but wasn't smart enough to know that they would not work on another hard drive."

    This is not true. But the hard disk must be the same size (GB) or more.

    How do you come to this conclusion?

    This link will guide you in the proper procedure with these discs

  • I would like to replace the noisy fans HP m9360f with quieter models upgraded.

    I've lived more loud noise of my Pavilion m9360f fan lately and am interested in replacing the processor fan and case fan as well.  Unfortunately I can't find any references or suggestions for improvements (here these new fans to be as quiet as possible). Honestly, I don't know yet what sizes the m9360f requires.

    Can you advise what direction I need to go?  I appreciate everything that you can provide.

    kcmac,

    Processor fan and case fan should be 80 mm (3.25 ") and 92mm (3.6") respectively. The measures are.

    Here's how to check: http://db.sanyodenki.co.jp/product_db_e/coolingfan/dcfan/dc_fan_detail.php?master_id=1993

    Audible noise is deemed be 21dB. The problem with low noise fans is their lower speed (RPM).

    Determining CFM has been the most difficult issue. Try Googling "5188-3722 CFM" (rear case fan is a #5188-3722), and you'll find it varies, but 40 CFM seems common response.

    Now install this to control the ROTATION speed: http://www.cpuid.com/downloads/hwmonitor/1.19-setup.exe

    Then save the idle and max RPM under load is heavy.

  • DRM function to replace the comma in a string

    Hello

    I'm new to the DRM. I have a requirement to replace insérent in a string with the semicolon (-). Is it all built in function to achieve.

    For example -.

    input string is s1, s2, s3

    Output string should be s1, s2, s3.

    I tried to use the ReplaceStr function. This works well for replacing any other, but for the comma, it does not work.

    Appreciate your help.

    It works for me with the formula below to do a global search of replacement that uses properties to store the string the comma (s) must withdraw and a global property to contain the decimal point itself:

    ReplaceStr (PropValue (Custom.String), (Custom.Comma) PropValue,, T)

    You've been do not add commas directly in the formula contained in the definition of the property you have? That would by way too many parameters in the function when the formula is analyzed for you would end up with something like ' DRM-25620: number of parameters for the function "ReplaceStr" invalid. " 4 expected, found 5. »

    Concerning

    Craig

  • How to replace the icons of bookmark that has disappeared in the last update?

    After the latest update of Firefox today, I noticed that all the favicons of websites disappeared from my favorites. Very annoying. Were there no fix for this bug? Or, if not, is it possible to revert to the previous version? Thank you.

    Hi sjed.

    You should take a look at this article which discusses some of the problems with the latest version of Firefox.

    There is some information here that should help you solve your problem. Fortunately, this is a very easy solution.

    Hope this helps!

  • Replace the MLB MacBook Pro. End 2012 model

    Sitting quietly: my MacBook Pro died in front of me. Ouch.

    Has paid a visit to my local Apple store. It seems that it was a defective MLB. Dear - a £500 repair bill!

    .... I decided against him... a new was perhaps in order. But I can't afford it.

    Came home, did my research and found this:

    Failures of widespread graphics 2011 MacBook Pro finally addressed by Apple repair program

    Went immediately on the phone to Apple Care and they agreed to mine qould qualify.

    So back to my local Apple store. Five days later, fixed. Free of charge!

    I am happy.

    I'm so happy to hear that you guessed it sorted. Apple are not always easy to find information:

    Without my Red Oval link looks like he's hiding! Old retirees here have long recommended that anyone who has seen the validation of the repair Extension program has to print and take with them to the Apple Store or FSAA, because no all employees/agents appear to be fully informed about these programs.

  • Replacing the USB HP Officejet 6500 has

    My konked out wireless and I plugged a USB cable on my 6500 has.  My other half stumbles on the cord, and now I can't print.  I checked the printer and the USB connection was loose.  Is it possible to repair this, OR I have to go to the sales page and order another printer?

    Thank you!  I thought kind of printer was toast, but wil try your suggestions.  Thanks again for your response.

  • Need to repair Satellite A300D to replace the wireless network adapter.

    I would like to replace the wireless card as it has performance very...
    in need of repair. Laptop sent away is not an option because of there where we live.
    You want to assign the card then internal dongle for Wi - Fi...

    > need to repair

    Unfortunately, I don't think that someone can present repair here, because it is a user forum. But you can visit irisvista.com to see other models Toshiba how to disassemble.

  • Search and replace the string formatting

    Hello

    I try to do a search and replace the formatting of a string.

    In the example, I'm looking for the string 'SUCCESSFUL', but it must also begin by usbflash and some number + PASSED.

    I can't get the format to have a number between 1 and 99. The number of replacements should add up to 6 in this case. I tried with \d for any number, and I also tried [1-99].

    Make a right-click on the function search and replace the string.  There is an option to use regular Expressions.  Then give it a try.

    EDIT: You need to set the entry replace all to TRUE.

  • Replace the text values

    Hello.

    I have problem with replacement of values in text strings and I can't find a solution.

    I have two or three channels filled with only 2 values: OK and NOK. How can I replace these values with for example 1 for OK and 0 for NOK?

    This replacement is necessary for drawing a chart. I can't draw the chart because the tiara do not accept the values of text like a ladder with the current values.

    Thanks in advance :-)

    Hello Domin,

    replaces a substring in a text with another text can be done with VBS 'Replace' function

    The execution of a function on an entire channel can be made using ChnCalculate.

    Combine the two and you get:

    ("ChnCalculate ("ch ()"" statistics text"" "") = Replace (ch ("' statistics text" "" '), '' value' ', "" LLL"") ")

    It is a channel in the DIAdem example data set. The above command executes the command "Replace" for each value of the text string "text of statistics". He replaces each occurrence of 'value' by 'LLL '.

    Hope this helps

    Andreas

  • How to replace the units of a channel using scripts % 3F

    Hello

    I have a few questions about the manipulation of the channel property 'unit' by scripts.

    Case 1: If the unit in the chain is not specified in the properties, what command should be used to add the inside unit?

    Case 2: When I create using the string ' Call.Root.ChannelGroups (1). Channels.Add ("name", DataTypeFloat64, 1)', empty space of unity being, what other command can be used which was available to the units to the breast?

    Case 3: Consider that I have channel (channel A) with the already defined unit (x), how can I replace the unit with another (y)? (Units of x and there belong to different physical quantities, so the ChnUnitConvert)

    Pls let me know if you nee details on the same.

    Kind regards

    Fazil Shah.

    Hi Fazil,

    The key word for SCRIPT DIAdem units is "unit_string". If you open the SCRIPT and open the channel property list you can select the property unit and drag & drop it in the SCRIPT Editor. This creates the code of script for the property.

    Case 1
    You have the options of towing: a quallified assignment complete or a channel object variable (if you have more settings for the channel of the second alternative is better)

    Data.Root.ChannelGroups (1). Channels ("mychannel"). Properties ("unit_string"). Value = "MyUnit.

    or

    Dim oChn
    Set oChn = Data.Root.ChannelGroups (x). Channels ("mychannel")
    oChn.Properties ("unit_string"). Value = "MyUnit.

    case 2
    You must add the unit after the creation of the channel

    Set oChn = Data.Root.ChannelGroups (x). Channels.Add ("MyChannel", DataTypeChnFloat64)
    oChn.Properties ("unit_string"). Value = "MyUnit.

    case 3
    It's the same as case 1 or if you do not want to use an already existing channel device, it can look like this

    oChnA.Properties ("unit_string"). Value = oChnB.Properties ("unit_string"). Value

    I hope that answers your questions

    Greetings

    Walter

  • If I replace the control with another why DAQmx create channel once complain a false claim?

    I tried to replace the frequency by another control in the example found here complete PWM:

    http://www.NI.com/white-paper/2991/en

    However, I get the following error message:

    Possible reasons:

    Requested value is not supported for this property value. The value of the property may be invalid because it is in conflict with another property.

    Property: CO. Pulse.Freq
    Required value: 0.000000
    Valid values begin with: 22.300000e - 309
    Valid values ending with: 20.0e6

    Channel name: Dev1/ctr0

    Task name: _unnamedTask<10>

    My wiring diagram looks like this:

    If I cancel my change (i.e. I have remove the frequency control knob and turn it over to the control of the example, it works perfectly.)  I get the waveform is displayed in the oscilloscope.

    My goal is to simply use a frequency and duty cycle control knob.  How can I achieve this?

    There are two things to do.

    What I think you did now changes the scale of the handle.

    You will also need to change the values that are allowed to enter. You will do on the data entry tab in the dialog button properti.

    Uncheck the 'use default', the Minimum value limits and Maximum identical to your balance.

    Value "Response to value out of range" Coerce to both Minimum and Maximum.

    I hope this helps.
    Let me know if you have more problems.

  • Calculations using values in the channels

    Is there a way to make simple calculations (addition/subtraction) of single values selected channels?   New user DIAdem, so I'm not at all familiar with the scripts.  Looks like it should be a simple command, and I'm right on it.

    Thank you

    Shannon

    Hello Shannon,.

    It seems to me that you do not want to add two or more 'cells' (to use the jargon of Excel) together.

    DIAdem manages data such as channels, not individual cells. If the approach to add two cells in DIAdem works like this:

    The variable SMC allows you to access a 'cell' in a channel, using the following sequence parameters:

    ChD (X, Y)

    where X is the line number of the table of channel, and Y is the name of the channel (column) or the number of the cell you want to access.

    For example, this expression here calculates the result of adding the value of line 2 of the channel called "Temperature_1" and the channel called "Temperature_2" of the example data set that takes over at the start of tiara. In this case, R1 is a real internal DIAdem variable that stores a single value.

    R1 = SEC (2, Ch("[4]/Temperature_1")) + SMC (2, Ch("[4]/Temperature_2"))

    The calculation above can be entered in the "Calculator" which is available in MODE of DIAdem and DIAdem analysis in the toolbar.

    I hope it's useful, please let us know if you have additional questions.

    Otmar

  • Formula to find the value of the channel

    Hi all

    Support: Dat file containing the value of time and acceleration. Now, there are only two Channels.  Channel 1 is time. Channel 2's acceleration.

    Step 1: Create more than two channels. Channel 3 and channel 4

    Step 2: go to the analysis and acceleration channel research where its value is reached xxxxxxxx 1.

    Step 3: where it has reached 1. XXXXXXXX in the process of accelerating from this point in the channel 3 and 4, paste all the values STD. STD values in the attached excel file.

    How can I do this? What is the formula or the script to do this?

    Thanks in advance.

    Hi Rash.patel,

    You didn't yet tell me where to find the Excel file, so I assumed it would be in the same folder as the VBScript script.  I used the DIAdem Excel Import Wizard to create an *.stp file that can be passed as parameter in the ExcelImport() command to load these curves 2 envelopes by program.  I also added a file dialog box, then you can select the *. DAT to deal with file.

    I think that's

    Brad Turpin

    Tiara Product Support Engineer
    National Instruments

Maybe you are looking for

  • iCloud email

    HI :-) HI :-) I watched my email last night, and I scrolled down to old emails of storage iCloud. I noticed that emails from storage had long between them, and they were all different. Some had 2 days between them, some had a week/weeks, and some had

  • How can I block a site that keeps changing my Java?

    I want to ban a site that keeps wanting to change my program Java in Java 'Oracle' to something else. Is there a way to block specific sites in Firefox? I am running Windows 8.1 on a Toshiba laptop and have Firefox 25.0.1 Mozilla 26-1.0

  • Deactivation of the system 5341473

    Can anyone please help me I need the administrator password of my computer hp laptop Windows 8 disable the code system that appears is 53414173

  • lost / my Admin user password, please help!

    How can I register in my Admin user? I just changed the password to the password and forgot it now. Can anyone help, please.

  • How to uninstall a program fragment

    Uninstalled a program update to update an empty shell exists in the control panel that will not remove or uninstall it retains the new installation uipdate because I don't have the ability to delete I now can't install the new assistance program