I am trying to execute Bigquery command line through my shell script. For eg :
#!/bin/bash
bq mk -t 'projectid':'datasetid'.'TEMP_table1'
Above script works fine. But my requirement is to pass table name randomly that I need to create. so, I execute below commands in my shell script :
#!/bin/bash
Tablename=$1
echo $Tablename
bq mk -t 'projectid':'datasetid'."$(Tablename)"
When I run it as ./test.sh 'Temp_table' command fails with error :
./test.sh: line 13: Tablename: command not found BigQuery error in mk operation: Cannot determine table described by financelcr:datasetid