If you are not sure whether the subquery returns a list of distinct values or not, you can use he DISTINCT keyword in the subquery. Otherwise, Oracle will raise a run-time error. Note that the subquery must return a list of unique values. When you use a subquery in the pivot_in_clause, Oracle uses all values returned by the subquery for pivoting. The XML string for each row contains aggregated data corresponding to the implicit GROUP BY value of that row e.g., number of orders ( ORDERS) and total sales ( SALES). For each value specified in the pivot_in_clause, the subquery returns a single XML string column. The XML output format is not the same as non-XML pivot one. To view XML in the output grid of from the SQL Developer, you follow these steps to set it up:ġ) From the Tool menu, select PreferencesĢ) Under Database > Advanced, check the option Display XML Value in Grid
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |