SHOW OFFERS¶
Provides information about all offers added to a listing.
Syntax¶
SHOW OFFERS [ LIKE '<pattern>' ] IN LISTING <listing>
Parameters¶
LIKE 'pattern'Optionally filters the command output by object name. The filter uses case-insensitive pattern matching, with support for SQL wildcard characters (
%and_).For example, the following patterns return the same results:
... LIKE '%testing%' ...... LIKE '%TESTING%' .... Default: No value (no filtering is applied to the output).
IN LISTING listingThe listing associated with the offer you want shown.
Output¶
The command output provides offer properties and metadata in the following columns:
Column |
Description |
|---|---|
|
The offer name. |
|
Offer status, one of:
|
|
The date and time the offer state was last updated. |
|
The preferred date for consumer listing access, one of:
|
|
Comments about the offer added by the provider. |
|
The total contract value. |
|
The contract type, one of:
|
|
The contract duration in months. |
|
The preferred invoicing start date, one of:
|
|
The date and time invoicing started. |
|
Specifies a default offer is included with the pricing plan, one of:
|
|
The offer name visible to consumers. |
|
The date and time the offer expires. |
|
Additional pricing plan parameters, one of:
|
|
The pricing plan associated with the offer. |
|
The date and time consumers lose access to the listing. |
|
The date and time consumers can access the listing. |
|
The offer discount. |
|
The consumer the offer targets. |
|
The terms of service associated with the offer. |
|
Additional information about the offer. |
|
The date the offer was last updated. |
Access control requirements¶
Privilege |
Object |
Notes |
|---|---|---|
CREATE LISTING |
Account |
Only the ACCOUNTADMIN role has this privilege by default. The privilege can be granted to additional roles as needed. |
For instructions on creating a custom role with a specified set of privileges, see Creating custom roles.
For general information about roles and privilege grants for performing SQL actions on securable objects, see Overview of Access Control.
Usage notes¶
To post-process the output of this command, you can use the pipe operator (
->>) or the RESULT_SCAN function. Both constructs treat the output as a result set that you can query.For example, you can use the pipe operator or RESULT_SCAN function to select specific columns from the SHOW command output or filter the rows.
When you refer to the output columns, use double-quoted identifiers for the column names. For example, to select the output column
type, specifySELECT "type".You must use double-quoted identifiers because the output column names for SHOW commands are in lowercase. The double quotes ensure that the column names in the SELECT list or WHERE clause match the column names in the SHOW command output that was scanned.
Examples¶
Show all the offers with names that start with myoffer in mylisting:
SHOW OFFERS LIKE 'MYOFFER%' IN LISTING MYLISTING;