I am trying to download entire dataset for a bioproject using esearch and efetch from the Entrez Utilities.

My syntax is based on syntax posted by @Istvan Albert at https://www.biostars.org/p/111040/#359440, which is

 

>    `esearch -db sra -query PRJNA40075  | efetch --format runinfo | cut
> -d
>      ',' -f 1 | grep SRR | head -5 | xargs fastq-dump -X 10 --split-files`

For the BioProject PRJNA269201 I am interested in, slightly truncated syntax as shown below, creates 144 empty files as expected:

    esearch -db sra -query PRJNA269201  | efetch --format runinfo | cut -d ',' -f 1 | grep SRR | xargs touch

However, when I try the full-length syntax, it behaves differently from what I expected under both scenarios 1 and 2 detailed below:

**Scenario 1**. On head-node of a cluster:

    esearch -db sra -query PRJNA269201  | efetch --format runinfo | cut -d ',' -f 1 | grep SRR | head -2 | xargs fastq-dump --split-files

one file finished download, but it is 5.5G which is way larger than the 1.2GB I expected based on info at this [link][1] - is this difference because of file compression?! How can I download to a much more compressed version for both storage and downstream RNA-Seq analyses?

    

    -rw-rw-r-- 1 aksrao aksrao 1.1G Jan 19 19:47 SRR1726554_1.fastq
    
    -rw-rw-r-- 1 aksrao aksrao 5.5G Jan 19 19:44 SRR1726553_1.fastq

**Scenario 2**. When I try to submit this as a shell script, the STDERR stream (SLURM queue management on UBUNTU cluster) captures the following error message:

> `2019-01-20T02:28:55 fastq-dump.2.8.2 err: param empty while validating`
> `argument list - expected accession`

This same problem was reported on the original post by user @ bandanaschapagain, but it may not have been answered and resolved, hence I am posting this afresh. Could someone please help me? Thank you!
  [1]: https://www.ncbi.nlm.nih.gov/sra/?term=SRR1726553

Download the [RunInfo][1] table and use parallel to download multiple files at once.

    #!/bin/bash
    #change the number after  -j change the number of files to be processed.
    parallel --verbose -j 20 prefetch {} ::: $(cut -f5 SraRunTable.txt ) >>sra_download.log
    wait
    parallel --verbose -j 20 fastq-dump --split-files {} ::: $(cut -f5 SraRunTable.txt ) >>sra_dump.log
    wait
    exit



  [1]: https://www.ncbi.nlm.nih.gov/Traces/study/?WebEnv=NCID_1_74280305_130.14.18.97_5555_1548224368_3125055013_0MetA0_S_HStore&query_key=3