How to split a big file into several small files using XI

Hi,
Is there any way to split a huge file into small files using XI.
Thanks
Mukesh

There is a how to guide for using file adapters, an "sdn search" will get you the document.
Based on that , read a file into XI, Use strings to store the file content and do the split
here is some code to get you started
===========
Pseudocode:
===========
// This can be passed in - however many output files to which the source is split
numOutputFiles = 5;
// Create the same number of filehandles as numOutputFiles specifies
open file1, file2, file3, file4, file5;
// Create an Array to hold the references to those filehandles
Array[5] fileHandles = {file1, file2, file3, file5, file5};
// Initialize a loop counter
int loopCounter = 0;
// a temporary holder to "point" the output stream to the correct output file
File currentOutputFile = null;
// loop through your input file
while (sourceFile.nextLine != null)
loopCounter++;
if (loopCounter == (numOutputFiles +1) // you've reached 5, loop back
loopCounter = 1;
currentOutputFile = fileHandles[loopCounter]; // gets the output file at that index of the array
currentOutputFile.write(sourceFile.nextLine);
regards
krishna

Similar Messages

  • Compressing large file into several small files

    what can i use to compress a 5gb file in several smaller files, and that will easy rejoined at a later date?
    thanks

    Hi, Simon.
    Actually, what it sounds like you want to do is take a large file and break it up into several compressed files that can later be rejoined.
    Two ideas for you:
    1. Put a copy of the file in a folder of its own, then create a disk image of that folder. You can then create a segmented disk image using the segment verb of the hditutil command in Terminal. Disk Utility provides a graphical user interface (GUI) to some of the functions in hdiutil, but unfortunately not the segment verb, so you have to use hditutil in Terminal to segment a disk image.
    2. If you have StuffIt Deluxe, you can create a segmented archive. This takes one large StuffIt archive and breaks it into smaller segments of a size you define.2.1. You first make a StuffIt archive of the large file, then use StuffIt's Segment function to break this into segments.
    2.2. Copying all the segments back to your hard drive and Unstuffing the first segment (which is readily identifiable) will unpack all the segments and recreate the original, large file.I'm not sure if StufIt Standard Edition supports creating segmented archives, but I know StuffIt Deluxe does as I have that product.
    Good luck!
    Dr. Smoke
    Author: Troubleshooting Mac® OS X

  • Source code organization: How to divide large JavaScript files into several smaller JavaScript files?

    Hello,
    some of my JavaScripts have become considerably large over time. What I would like to do is to split a single (large) JavaScript source file into several smaller source files plus an additional JavaScript file containing code or directives to recombine the split files.
    In other words, I would like to organize my JavaScript source code into re-usable modules.
    Although I searched the Acrobat JavaScript developer documentation and did a lot of Web searching, I still have no idea...
    whether the Acrobat JavaScript scripting environment itself does provide a code structuring mechanism
    how to properly organize large Acrobat JavaScripts in general.
    Any help would be greatly appreciated! Thanks a lot in advance!
    Sebastian

    Document-level scripts are not accessible to other documents/scripts, so they're not a good option.
    Folder-level scripts, on the other hand, are accessible to all other documents/scripts. So if you have a general function that creates a 3D annotation, for example, you can place it in a folder-level script and then call it from other scripts (you will probably need to provide it a handle for the document and properties of the annotation).
    One thing to be aware of, though, is that the folder-level scripts are loaded alphabetically, so don't put a reference in script aaa.js to something that loads in zzz.js, or you will get an error message when you open Acrobat. (this is not a problem if zzz.js is not called during the launch of Acrobat)

  • How to split a file into two small file

    Hi All,
              I want to raed a file from FTP server.Then i have to split a file into two small file.File format look like this.
             R01!service_order!item_guid!resource_guid!assignment_guid
             R02!Service_order!product_id!product_discription!quantity
             R02!Service_order!product_id!product_discription!quantity
             R02!Service_order!product_id!product_discription!quantity
    i want split file into 2 file,according to header and item details.one table containt header information (label R01) and second table containt (label R02).
    can anybody help me for this.how can i split into 2 file.
    Thanks
    Vishwas Sahu

    Create 2 internal tables. sat it_header, it_detail
    Check for 1st 3 characters and if it is R01 then send it into it_header and if it comes out to be R02 then send it to it_detail.
    Once done... You can either attach these tables into mail as two seperate files
    Or you can download each internal table using GUI_DOWNLOAD.
    Hope this helps!!
    Kanchan

  • How to split a PDF document into several documents

    Hallo!I am using Adobe 7 at the office.
    Sometimes I receive large PDF documents (+1000 pages) whereby I only need a few pages for my reports.
    I would like to split these large PDFs into smaller PDFs.
    How can I achieve this?
    Thanks.

    Thanks.
    In my Documents menu,there is no option of Extract Pages.The options that appear are as below
    1)Digital Signatures
    2)Security
    3)Security Settings
    4)Trusted Identities
    5)Accessibility Quick Check
    6)Use local fonts
    Where else can I find the Extract pages option ?
    Thanks.

  • Publishing large files into several small ones?

    Hello everyone.
    I have a project, almost 16 mb large. It;s quite large and the users have to wait a bit to get the tutorial.
    I tried this. I split the porject into different projects like 1. menu, 2. description, 3. practice. and then I link the projeect menu to description, practice and so on. So it's working fine! I think this is a good solution to stop the students boredom. Now there is a little problem on this.... THE TABLE OF CONTENTS. For every project there is a new table of contents.
    So, How can I do to have the same table of contents in all the projects? or better yet, How can I do to publish the whole project but like streaming, I mean instead of loading the 16mb I want it loads deppending on the slide the student is. Is it possible????
    Thanks a million!
    Ben

    Hi there
    There are many variables at stake here, such as Captivate version as well as how you are presenting the TOC.
    If you are using Captivate 3, perhaps explore the MenuBuilder application.
    If you are using Captivate 4 or 5, You might investigate using the Aggregator application.
    Cheers... Rick
    Helpful and Handy Links
    Captivate Wish Form/Bug Reporting Form
    Adobe Certified Captivate Training
    SorcererStone Blog
    Captivate eBooks

  • How to split a PE1 project into two smaller projects?

    I have a 1hr 36 min. project in PE1.  I want to split it into two different projects of about 48 min. each and burn two DVDs.  My intent is to get a better MPEG resolution for these smaller projects.
    Can I select half of the timeline, cut it and paste it into a new project?  Would the effects be preserved?  I have a week of work invested in this project and I don’t want to screw it up!
    Thanks
    Fred J.

    FredJ,
    Welcome to the forum.
    I agree with both Neale and Steve, though it might at first appear that they are saying two different things.
    The bit-rate in the Transcoding to MPEG-2 will be determined by the Duration of the Timeline and the capacity of the blank media, whether DVD-5, or DVD-9. In most versions of PrE, this bit-rate will be a function of the Quality Slider, but the ultimate bit-rate for the combined video and audio is set in the DVD-specs. One cannot exceed about 8 b/s.
    Now, with your Duration, there might be a very slight increase in the bit-rate, were you to take Neale's advice and break your Project into two parts, however, I think that his advice to study the result of your entire Timeline is good, as I doubt that one could tell the differences, unless you have a great deal of fast motion, of either the camera, or the subject, and then it's likely that the quality would appear to be the same to the human eye.
    Steve is correct in that the result will have to be within the DVD-specs, and will only be 720x480, at up to that max. bit-rate. That is as good as it gets.
    For the ultimate test, I would take Neale's suggestion on Burning to Folder one step further. Once that is done, you can first test your Project with a DVD software program on your computer. BUT, be aware that you are viewing on a higher-rez, progressive computer monitor, and its rez will exceed that of a TV and that of a DVD-Video disc. Thus, it is not a perfect test. To get an idea of how the DVD will look on a set-top player, hooked to a TV, you can either, also burn to a DVD RW (rewritable disc) to test on a set-top player, or you can use the free burning utility, ImgBurn, to burn to a DVD RW and test. The reason for the Rewritable media is so that you can reuse it for testing. You will NOT be using this disc for delivery, but just for testing. Now, if you feel that very slight decrease in bit-rate is noticed, you can go back to his suggestion on how to split the Project, and then produce a multi-disc. set for the Project.
    Also, the ultimate quality and also playability of the DVD-Video will be enhanced if you use quality blank media. I strongly recommend Verbatim, or Taiyo Yuden blank media. Brands like Memorex, TDK, recent Ritek and ALL "store-brands," are to be avoided. One is also best served by buying slower speed media, as PrE will measure the speed of the media and the speed of the drive and try to get you the fastest possible burn. It does not allow you to set the speed of the burn manually. Most people feel that stepping down from a max. burn speed produces a better DVD. I routinely will drop the burn speed (in other software) to about 1/2 of the max., and have had thousands of perfect DVD's. One can set the burn speed in the above mentioned ImgBurn utility.
    To distill the above: try it and see if your Project isn't perfect now, and if not, then break it apart into two segments. I doubt that you could tell the difference.
    Good luck,
    Hunt

  • How to split Large file into Multiple small files..

    Hi,
       My source file is simple  XML structure...and target side also i need to send in XML files  .. but in the source file I'm getting all the data at a time.. so source file  is more than 1000 records.. but i want to process  50 records at a time...
    bu using FCC (RecordSet per Message)  we can   solve this.. but I dont want to  do any File conversion.. i want to send  in XML file only...
    for this.. how we can handle....
    Regards
    Jain

    Jain,
    Please see the below screenshots.
    http://www.flickr.com/photos/23855877@N07/2991137391/sizes/o/
    http://www.flickr.com/photos/23855877@N07/2991137441/sizes/o/
    http://www.flickr.com/photos/23855877@N07/2991988028/sizes/o/
    http://www.flickr.com/photos/23855877@N07/2991988084/sizes/o/
    For No, Name, City Map Directly.
    In the example, I've given 5 records to split. If you want 50 records to split, then instead of 5 give 50 in the constant.
    raj.

  • How to Split Master File into Multiple Small Files?

    Sorry if this has been addressed - I'm having a hard time finding the answer.
    I'm using FCE 4.0. I taped 4 hours of material and need to deliver the footage to someone in discrete chunks. I tried to do in/out capture but for some reason that wasn't working - something to do with the timecode. So I did full tape dumps.
    So now I have 4 huge files (4 miniDV tapes) that are too big to deliver as-is. I used DV Start/Stop Detect to set markers, then used that to create sub-clips. But of course this doesn't actually affect the master scratch files.
    What's the best way to convert these sub-clips to individual mov files? If I do an export of each file ("Using QuickTime Conversion..."), don't I risk losing information or possibly quality? Isn't there some way to highlight all my sub-clips in the bin and say "Mega-Chop Activate!" or something?
    Or, taking a step or two back, if there's another way I should've approached this, please let me know. There'll be more. Plenty more.
    Thank you.

    I'm burning mov source to DVD for FC editing by someone else.
    Your second set of questions actually gives me some ideas - that's exactly what I'm trying to figure out.
    As an example, let's say 1 tape, i.e. 1 master file, holds 5 interviews. I want to deliver 5 individual files/clips, say 3 on DVD A, 2 on DVD B. (Assume for the sake of argument that the math works out and there's no other way to deliver this.)
    - Does creating a different project for each "chunk" result in a different file in the scratch folder that can be burned to DVD?
    - Does "Print to Video" create QT files? I thought this output back onto tape.
    - By "Export to QuickTime" are you referring to Export->QuickTime Movie (as opposed to Export->Using QuickTime Conversion)?
    - Does Export->QuickTime Movie result in lossy conversion or does it automatically retain the original capture quality?
    - Is there a way to do all 5 exports at once or must they be done individually?
    Thanks for the fast response!

  • How to split a large PDF into many smaller PDFs

    In my wanderings, I couldn't find an answer to this question. Thus my post.
    I have a large, 20 page, pdf. I'd like to split that pdf into 10 two page pdfs. How can I do it?
    The 20 pager is a pdf of a number of account statements. The account statements varying in length from 1 to 3 pages. I'd like to split the pdf so I end up with one pdf per account.
    In advance, thank you for your help

    Hi.
    It's simple: open the PDF, go to File, Print, and in the print dialog select Copies & Pages, enter the range you want, click PDF/Save as PDF.
    Good Luck.
    MacMini G4 1.25GHz 1GB   Mac OS X (10.4.9)  

  • ITunes makes my CD's small. How Can I convert DVD's into a small file too?

    I bought my wife an iBook and would like her to be able to watch a movie just like she does the music. I've used Mac the Ripper to get it onto the computer, but I don't want it to be a 4 GB or more file. I've been able to use Matinee to select them, but isn't there a way to make them into the equivilant of an MP3... am I thinking of an MPEG 4.
    If so, is commercial software the only way available to do this.... I have Quicktime Pro 7. Does that do the conversion?
    Thanks, I hope this is a clearly written question.
    Dave

    you can export using the export from the menu in quicktime.
    But if you want to re-encode a DVD you could use something like Forty Two
    http://www.kaisakura.com/fortytwo.php
    For similiar apps do a search on versiontracker.com
    That creates a gorgeous 700-1 GB divx (mpeg4)

  • Compressing a large file into a small file.

    So i have a pretty large file that i am trying to make very small with good quality. the file before exporting it is about 1gig. I need to make it 100mbs. Right now i've tried compressing it with the h.264 compressing type, and i am having to go as low as 300kbits. I use aac 48 for the audio. It is just way to pixelated to submit something like this. But i guess i could make the actual video a smaller size something like 720x480 and just letterboxing it to keep it widescreen? Any hints on a good way to make this 21 minute video around 100mbs?

    There are three ways to decrease the file size of a video.
    1. Reduce the image size. For example, the change of a 720x480 DV image to a 320x240 will decrease the size by a factor of 4
    2. Reduce the frame rate. For example, changing from a 30 fps to 15 fps will decrease the size by a factor of 2
    3. Increase the compression/ change code. This is the black magic part of online material. Only you can decide what's good enough.
    x

  • How to split one big master clip into many?

    Hi,
    This is probably a simple question for you pros. Thank you for reading.
    I have film that I've telecined onto a DV. However, FCP imported a one hour tape as one big master clip. Is there a way I can split this master clip into several small clips so I can organize my project?
    Does that make sense?
    Thank you in advance,
    Nik

    Since you telecined onto DV I guess there are no Date&Time gaps between scenes, so you cannot use DV Start/Stop Detect. Then the only way I can think of is to do it manually: open the clip in the viewer, select the first scene by setting its IN and OUT points, edit to the timeline, back to the viewer select the next scene setting a new pair of IN and OUT points, edit to the timeline, etc.
    If you prefer you can move each new clip to the browser, and collect them together into a bin, before editing them to the timeline.
    Piero

  • How to break up a large .java file into several?

    Hi,
    I have a pretty large .java file containing many private methods. I rather not have to always work in this very large file. Is there a way to separate this into several smaller files, but to maintain the same relationship of all these private methods being part of the same class?
    Thanks in advance,
    Steve

    I thought that would be the answer. This is my first
    Java app. It uses Swing and I use NetBeans as my
    IDE.
    I knew it was getting too large, but I was trying to
    avoid having to reimplement the whole thing. I have a
    few more features to add and I can see this file
    growing by another 300-400 lines.You'll find it a lot simpler to write the second time round. You really don't want to have classes that big
    I do in fact have a couple other .java files where I
    created separate classes. Its just that I really need
    to rethink or redesign this whole thing.You do. Sounds like you've got one class that does too many things. What does this big class do? Adding new features shouldn't bloat your code this way

  • How can I divide one big long track into several smaller ones?

    I have many mp3"s I imported or downloaded in my Library of lectures, sermons and speeches.
    How can I divide one big long track into several smaller ones?
    Any input would be great.

    lakergrl wrote:
    How do I split one very long track into several tracks (audio journal split into each day)
    http://www.bulletsandbones.com/GB/GBFAQ.html#exportsections
    (Let the page FULLY load. The link to your answer is at the top of your screen)

Maybe you are looking for

  • Schedule view in Calendar

    Up to OS10.9, there is an option to show calendar events in a column, and event details in an adjacent column. Days without events were skipped. This was called "Schedule View". After upgrading to Yosemite, this option has disappeared. I find it very

  • How to shift Verical scroll bar from right to left??

    hi.. I have added a JTable to a JScrollPane. This adds a verical scroll bar to the right of my table. Now I want to have this vertical scroll bar added to the left of my table. is it possible? if yes then suggest how??

  • Drag 'n' Drop???

    I just noticed that for some reason some of the songs in certain albums on iTunes are not in numerical order. It does not simply let me "drag and drop" the songs in the order they should be in. I've tried everything I can think of to rearrange them a

  • R/3 and SRM Pricing

    The condition type from R/3 are not transferred to SRM. In a Extended Classic scenario, how do we Create PO in SRM and handover to Vendor if we are unable to configure the complex R/3 conditions / Pricing Procedure in SRM ? Thanks in advance. Regards

  • Problems with autofill when editing address book entries

    When i try to change eg miller to Miller, anna to Anna etc 1) the initial letter remains lower case and 2) even worse, another iller/nna is added on to the end - milleriller, annanna etc. I've tried deleting the whole name and starting again - no joy