Description Usage Arguments Details Value See Also Examples
Check validity of fields of a query against a provider.
1 | verifyQuery(provider, Q, verbose = TRUE)
|
provider |
Character string indicating a provider. |
Q |
Character string indicating fields of a query. |
verbose |
Logical indicating if problems should be printed out. If FALSE only return the logical result. |
This functions check fields of the query Q
against those expected by
the provider indicated by provider
. If all fields check ok
then TRUE
is returned,
otherwise the result is FALSE
. If verbose
is TRUE
then the
first error found will be printed.
Note that, even though the query is valid, the providor may not have data for the specified combination of fields, in which case a data request will not return data.
As of February 2015, the WB provider is not responding to queries in the same way as it indicates they should be, so this utility is not very useful with this provider. That is, even if the declared structure is FREQ.SERIES.REF_AREA, you have to build the WB query as REF_AREA.SERIES.
TRUE/FALSE returned invisibly
getProviders
,
getFlows
,
getDimensions
,
getCodes
1 2 3 4 5 6 7 8 9 10 11 | ## Not run:
print(verifyQuery('IMFx', 'PGI.CA.*.*.*.*'))# returns FALSE
print(verifyQuery('IMF', 'PGI.CA.*.*.*.*', verbose = FALSE)) # returns TRUE
print(verifyQuery('IMF', 'PGI.CAN.*.*.*.*'))# returns FALSE
#print(verifyQuery('NBB', 'HICP.000000.*.*'))
#print(verifyQuery('NBB', 'HICP.000000.BE.M'))
## End(Not run)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.