Closed adarobin closed 6 years ago
Hi @adarobin, can you clarify on the requirements or give an example of the usage? I thought the Start-BqJob
command has -WriteMode WriteTruncate
?
Hi @quoctruong, The Start-BqJob
has -WriteMode WriteTruncate
but it is only available in the parameter set for Copy Jobs, not Query Jobs.
PS /Users/adarobin> Start-BqJob -Query -QueryString "SELECT * FROM ``foo``" -Destination $destTable -WriteMode WriteTruncate
Start-BqJob : Parameter set cannot be resolved using the specified named parameters.
At line:1 char:1
+ Start-BqJob -Query -QueryString "SELECT * FROM ``foo``" -Destination ...
+ ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
+ CategoryInfo : InvalidArgument: (:) [Start-BqJob], ParameterBindingException
+ FullyQualifiedErrorId : AmbiguousParameterSet,Google.PowerShell.BigQuery.StartBqJob
@adarobin We've implemented the feature. It will be out in the next time the module is released!
@adarobin Version 1.0.1.3 of the module (which is available on the PowerShellGallery) has this fix.
It would be useful if Start-BqJob implemented the WriteMode flag for Query Jobs. I'd like to be able to pass
-WriteMode WriteTruncate
to some of my Queries.