What's the best way to extract data (a substring) from a string?

Hi,
I have a field being returned from a function call and the data looks like this:
sfaqwe4|89uuuroeoi0|kjg3j90493  (It's data...pipe...data...pipe...data)
What is the best technique to use to extract the middle set of data between the two pipes?
Is the any prewritten method to separate the data, or do I have to loop thru the field looking for the pipes, etc.?
Thanks for your help,
Andy

<<Copy paste from http://careerabap.blogspot.com/2009_08_01_archive.html - user notified, points removed>>
Hi,
The WRITE statement is what we use to substring a field. The syntax is as follows:
WRITE fieldname+starting_position(field_length) to variable
The fieldname is the source (or input). The plus sign precedes the starting position of the substring.  The first position in the string is 0. Immediately after (no space) comes the length of the substring you are going to use. You can also substring the variable that you are writing the string to (the target).
You can also use function module 'STRING_SPLIT_AT_POSITION'.
Best Regards,
Edited by: nihad omerbegovic on Dec 14, 2009 3:03 PM
Edited by: Matt on Dec 20, 2009 4:13 PM

Similar Messages

  • What is the best way to extract all my information from my macbook pro?

    i wanna extract all my info, put it into an external hard drive and erase it from my mac.

    If you plan on buying a apple laptop you have two options. You can use time machine or pull the data off of it directly and put it onto the external. I advise the second choice. This way you do not have stuff that you dont need filling up the space on your new drive. Get your applications, music, documents, photos, videos and perhaps downloads and desktop; Put all of these on your external. And then reinstall osx onto your drive.
    *** If buying a windows machine next check the format of the drive in disk utility. You will need a program called Paragon NTFS to format the drive window compatibility. You have to pay for the free version but can download a trail version for free.
    http://www.paragon-software.com/home/ntfs-mac/
    Did i leave anything unanswered?

  • What is the best way to transfer data from a PC to an iMac?

    What is the best way to transfer data from a PC to an iMac?

    If you know how to set up a computer-to-computer Ethernet network, then you can give that a try, but a hard drive will be faster than Ethernet unless you don't have a lot to transfer.
    Mac OS X 10.6 Help- Creating a computer-to-computer network

  • What is the best way to transfer my iphoto library from old imac to new imac. both have iphoto 9.2.1

    What is the best way to transfer my iphoto library from current imac to my new imac.  Both imacs have iphoto 9.2.1
    os on old imac is 10.6.8.   os on new imac is 10.7.2.   I want the albums  and events to stay intact.  I have 4500 photos and 79 videos. 14.9 gb. looking for some advice here. Thanks so much.

    Connect the two Macs together (network, firewire target mode, etc) and drag the iPhoto library intact as a single entity from the old Mac to the pictures folder of the new Mac - launch iPhoto on the new mac and it will open the library and convert it as needed and you will be ready move forward.
    LN

  • What is the best way to create a database schema from XML

    What is the best way to create a database schema from XML?
    i have  a complex XML file that I want to create a database from and consistently import new XML files of the same schema type. Currently I have started off by mapping the XSD into Excel and using Mysql for Excel to push into MySQL.
    There must be a more .net microsoft solution for this but I cannot locate the topic and tools by searching. What are the best tools and way to manage this?
    Taking my C# further

    Hi Saythj,
    When mentioning "a database schema from XML", do you mean the
    XML Schema Collections? If that is what you mean, when trying to import XML files of the same schema type, you may take the below approach.
    Create an XML Schema Collection basing on your complex XML, you can find
    many generating tools online to do that.
    Create a Table with the above created schema typed XML column as below.
    CREATE TABLE youTable( Col1 int, Col2 xml (yourXMLSchemaCollection))
    Load your XML files and try to insert the xml content into the table above from C# or some other approaches. The XMLs that can't pass the validation fail inserting into that table.
    If you have any question, feel free to let me know.
    Eric Zhang
    TechNet Community Support

  • What is the best way to call a pageflow action from JavaScript?

    What is the best way to call a pageflow action from JavaScript?
    Thanks,
    John

    John,
    How would I do this from a grid??? Unfortunately there are no JavaScript attributes
    on any of the grid tags that I can see.
    Thanks,
    John
    "John H" <[email protected]> wrote:
    >
    Thanks John!
    "John Rohrlich" <[email protected]> wrote:
    John,
    If you want to put up a confirm dialog before calling an action from
    an
    anchor it is done as follows.
    Here is an example from code of mine that deletes a customer order,if
    the
    user confirms the delete. I pass the order id as a parameter.
    - john
    Here is the JavaScript -
    function confirmDelete() {
    if(confirm('Continue with order delete?'))
    return true;
    else
    return false;
    Here is a sample anchor tag -
    <netui:anchor action="requestToDeleteOrder" onClick="return
    confirmDelete(); return false;">
    Delete
    <netui:parameter name="orderId" value="{container.item.orderId}"/>
    </netui:anchor>
    "John H" <[email protected]> wrote in message
    news:402138f5$[email protected]..
    Thanks for the replies. I figured it was going to require buildingmy own
    url
    to call the action. I had hoped there was an easier way to do it.Rich,
    the
    reason I want to do this is because I want to call the JavaScript
    function
    confirm()
    when a user clicks on a link (in a repeater/grid) to drop a record,I only
    want
    to call the drop action if the user confirms the drop. Maybe thereis a
    better
    way to do what I am trying to do??? I really appreciate any help
    you
    guys
    can
    give me on this, I am pretty new to this sort of stuff.
    Thanks,
    John
    "Rich Kucera" <[email protected]> wrote:
    "John H" <[email protected]> wrote:
    What is the best way to call a pageflow action from JavaScript?
    Thanks,
    JohnTry figuring out the URL to the pageflow action, create a hidden
    form
    in the
    page, then use JS to submit the form. Why would you want to though,
    isn't
    the server going to want to send you to the next page?

  • What's the best way to import my itune library from iMac to macbook air?

    what's the best way to import my itunes library from my imac to my macbook air?

    Use Migration Assistant to copy your entire user folder from old computer to new computer.
    -> http://support.apple.com/kb/HT4889

  • Using the new iPad, what's the best way to watch video files (away from home) which are stored on a NAS (WD My Book Live)? Any help would be appreciated!

    Using the new iPad, what’s the best way to watch video files (away from home) which are stored on a NAS (WD My Book Live)?  Any help would be appreciated!

    Before you go, move the files to I tunes and sync them down.  There is no viable way to stream from your nas drive to the pad.

  • What is the best way to save data from GPIB Device in a file?

    HI!
    I have a Keithley SourceMeter and want to save readings in a File along with settings on the front panel and timestamps plus several other infos. What is the best way to do this? Which file type? Any recommendations or hints could help me?
    Thanks

    Hi Andy,
    There are 3 main file formats that you can consider writing your data out to in LabVIEW:
    ASCII
    Binary
    Datalog
    ASCII
    ASCII files are useful because every operating system and almost every application can read/write ASCII format files. Use ASCII files when:
    Other users or applications will need to access the data file.
    You will not need to perform random access file I/O
    File I/O speed is not crucial
    Disk space is not crucial
    Examples within LabVIEW Example Finder: Fundamentals >> File Input and Output >> Write to Text File.vi and Read from Text File.vi
    Binary
    Binary byte stream files are more specific to data storage and retrieval. Use b
    inary files when:
    File I/O will remain in LabVIEW only -- no other applications will be needing to write/read that file. There is no standard formatting for binary files and thus other applications or operating systems may be unable to read the file.
    Files are smaller than ASCII files
    Easier and faster random access to data
    Examples within LabVIEW Example Finder: Fundamentals >> File Input and Output >> Write Binary File.vi and Read Binary File.vi
    Datalog
    When to use datalog:
    If you need to record data with a mixture of types, it can be cumbersome to convert everything to ASCII or to keep track of the binary formatting.
    Datalog format is binary and internal to LabVIEW, so again only use this format if no other applications or operating systems will be needing to perform file I/O on the file.
    Examples within LabVIEW Example Finder: Fundamentals >> File Input and Output >> Write Datalog File
    Example.vi and Read Datalog File Example.vi
    Good luck!
    Kileen C.
    Applications Engineer
    National Instruments

  • What is the best way to get data to a user interface?

    Hi,
    I'm using labview 6i. I have an application with a handful of "core" vi's that actually run my application, doing the data acquisition, analysis, and control. I am currently using these same vi's for my user interface. I also have a number of vi's that contain menu's for configuring the "core" vi's. My questions is, what is the best way to seperate the "core" vi's from the user interface vi's. Global's, data socket, control references, others?
    Thanks for the help.

    Hi Sal,
    I have been a strong advocate of control refnums ever since LV 6i hit the streets. I recomend you look into using them to provide this conectivity.
    You could accomplish this by using a variation on the following.
    In your UI, create refnums for each of the controls or indicators that must be monitored or updated. Pass the appropriate refnums to each of the "core.i's" at program init time. Inside each of the core.vi's, use property nodes to read the control's values when appropriate and similarly for display purposes. (Note: Not all boolean mechanical actions are compatible with this technique. In those case you will have to explicitly write false values after find the control to be true or vise versa).
    By using this technique, you can keep the UI diagrams clea
    n. Depending on your app. the UI diagram could consist of the init's I mentioned above, and a while loop that watches if it's time to exit.
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • What is the best way to retrive data from a Global Variable?

    Here is what I want to do,
    I have several PC's that run different types of tests. I want to use a global variable, running on a single PC, that acts like a sever that can be accessed by the other PC's in my lab. This Global variable will store the hostnames of the different PC's that are currently running each test, along with a description of the test.  Then, a user can access this Global variable to read the different values and select the PC and connect to it's desktop using Remote Desktop in Windows.
    Is it possible to write data to the Global variable that is running on the single PC?
    What is the best way to do this? Does anyone have a sample VI?
    What is the best way to then read the data from the Global variable?
    (I will probably use an array\cluster to store the hostnames.) 

    Another pre-LV8 idea...
    A functional global can be accessed using VI-Server and called using "call by reference".
    This approach harnesses the TCP functionality built into the VI-Server to manage the conncetion.
    This can be pretty quick and (if the functional global is written correctly) will support buffered- mixed data types. (Try to do that with the Shared Variable  ).
    Just another idea,
    Ben
    Ben Rayner
    I am currently active on.. MainStream Preppers
    Rayner's Ridge is under construction

  • What is the best way to audit data

    What is the best way to audit actual changes in the data, that is, to be able to see each insert, update, delete on a given row, when it happened, who did it, and what the row looked like before and after the change?
    Currently, we have implemented our own auditing infrastructure where we generate standard triggers and an audit table to store OLD (values at the beginning of the Before Row timing point) and NEW (values at the beginning of the After Row timing point) values for every change.
    I'm questioning this strategy because of the performance impact it has (significant, to say the least) and because it's something that a developer (confession, I'm the developer) came up with, rather than something a database administrator came up with. I've looked into Oracle Auditing, but this doesn't seem like we'd be able to go back and see what a row looked like at a given point in time. I've also looked at Flashbacks, but this seems like it would require a monumental amount of storage just to be able to go back a week, much less the years we currently keep this data.
    Thanks,
    Matt Knowles
    Edited by: mattknowles on Jan 10, 2011 8:40 AM

    mattknowles wrote:
    What is the best way to audit actual changes in the data, that is, to be able to see each insert, update, delete on a given row, when it happened, who did it, and what the row looked like before and after the change?
    Currently, we have implemented our own auditing infrastructure where we generate standard triggers and an audit table to store OLD (values at the beginning of the Before Row timing point) and NEW (values at the beginning of the After Row timing point) values for every change.You can either:
    1. Implement your own custom auditing (as you currently do)
    2. Flashback Data Archive (11g). Requires license.
    3. Version enable your tables with Workspace Manager.
    >
    I'm questioning this strategy because of the performance impact it has (significant, to say the least) and because it's something that a developer (confession, I'm the developer) came up with, rather than something a database administrator came up with. I've looked into Oracle Auditing, but this doesn't seem like we'd be able to go back and see what a row looked like at a given point in time. I've also looked at Flashbacks, but this seems like it would require a monumental amount of storage just to be able to go back a week, much less the years we currently keep this data.
    Unfortunately, auditing data always takes lots of space. You must also consider performance, as custom triggers and Workspace Manager will perform much slower than FDA if there is heavy DML on the table.

  • Replacing MacBook Pro's optical drive with SSD. What is the best way to migrate data?

    I have a time machine backup on external drive.
    I would like to:
    1. clean install Lion on the new SSD (120 GB)
    2. restore apps from my backup on the SSD
    3. keep only data on the existing HDD
    My questions:
    What is the best way to make it?
    Can I just keep the existing system on my non-SSD HDD, and after having Lion on SSD keep just data and delete the system libraries? Or is it better to format the whole disk and restore data from time machine backup (so it is not fragmented...).
    Thanks for any tips in advance!
    Antonin

    OK, thanks a lot.
    And after reformatting the old HDD can I - can I tell Time Machine where to recover my folders (apps --> SSD, data --> old HDD)?
    I mean when Time Machine starts recovering my 450 GB of files onto 120 GB SSD will it ask me to decide what put where?

  • What is the best way to move data from one array to another

    I'm going to be moving data from one array to a larger array on the same RAID but different controller. (I have some extra extra drives I'm also going to be installing Retrospect so I can't just restore from a backup.)
    The RAID has 450GB of production files, fonts etc.
    What is the best way to move the data over?
    I saw that someone had suggested using ditto. Would that be better than MacMV?
    I also own Bru LE so I could use that.
    Any advice would be appreciated.
    Thanks,
    Paul

    Ditto is a great option -- probably the best.
    ditto -rsrc src_folder /Volumes/targetvolume/targetfolder

  • What is the best way to import and export footage from the 5D Mark II?

    Hello,
    I've just finished shooting what I am considering to be my directorial masterpiece.  Shot it on the Canon 5D (1080p, 24fps), and the footage looks amazing.  Now I am ready to start editing and have been using premiere lately, but I have yet to figure out the proper pipeline.  I want to know the best way to retain resolution before I delve into this project.
    My questions:
    1)  What is the best way to start a new project and import the footage without having to render whilst editing, so as to retain all resolution and originality of the source footage?
    2)  What is the best way/ codec/ format to export this same footage once editing is complete so as to retain that crisp 1080p for which the 5D is so recognized?
    3)  What is the best way/ codec/ format to import and export/ render between premiere and after effects?  I am speaking mostly of vfx and color correction.  I also have some 30fps footage that I intend to slow down in AE and then import into premiere.
    I know this is pretty broad, but as a solo filmmaker I really need someone's guidance.  I rarely ever finish my films with the same, crisp look as the footage.  I need pipeline help, and really appreciate it!

    ascreenwriter wrote:
    Hello,
    I've just finished shooting what I am considering to be my directorial masterpiece.  Shot it on the Canon 5D (1080p, 24fps), and the footage looks amazing.  Now I am ready to start editing and have been using premiere lately, but I have yet to figure out the proper pipeline.  I want to know the best way to retain resolution before I delve into this project.
    My questions:
    1)  What is the best way to start a new project and import the footage without having to render whilst editing, so as to retain all resolution and originality of the source footage?
    2)  What is the best way/ codec/ format to export this same footage once editing is complete so as to retain that crisp 1080p for which the 5D is so recognized?
    3)  What is the best way/ codec/ format to import and export/ render between premiere and after effects?  I am speaking mostly of vfx and color correction.  I also have some 30fps footage that I intend to slow down in AE and then import into premiere.
    I know this is pretty broad, but as a solo filmmaker I really need someone's guidance.  I rarely ever finish my films with the same, crisp look as the footage.  I need pipeline help, and really appreciate it!
    1. Follow the advice above. Also use the Media Browser to import the footage in case you have spanned media files. Import files with the Media Browser.
    2. It largely depends on what you wish to ouput to: Blu-ray, web, etc. This FAQ gives the best answer: What are the best export settings?
    3. Use the Replace with Adobe After Effects Composition function.

Maybe you are looking for

  • Email alias not not receiving emails

    My friends and family are getting email bounce backs from my iCloud email alias. Help?

  • Font book crashes on launch, can't use MS Office

    Hi there, I have a problem which started with MS office not opening. As soon as I tried to open a Word document, it would close saying that it has encountered a problem and needs to close. After a spot of googling I discovered that this might be a pr

  • How do i get areo support

    I've got a new 15" LED mac book pro. It's the low end. 15.4" core2duo intel 2.4ghz. 4gb ram. 250gb hard drive. nvidia non 3d accelerated and then the 3d accelerated video chip. I forget the model of the nvidia chip. I want to run windows vista or XP

  • Who deleted a query

    Hi all, A query has been deleted from the production system , how do I know who has deleted the query and other details. thanks

  • I can't set up my account

    i have a wesite as my mail server and mail won't connect. i'm not sure what it is that i'm doing wrong