Wednesday, January 06, 2010
While developing reports in OBIEE, I found myself making the same action over and over again: Styling a column, clicking on "Copy Cell Format", going through all other columns and pasting the format. A better way to do this kind of actions in one shot is by changing the Request XML. Let's say you applied style to the first column and you want to copy it to the other columns. This is how you'll do this:
  1. In the report editor, click on the Advanced tab.
  2. Copy the Request XML.
  3. You'll need to edit the xml in a text editor which supports macros. My favorite is Notepad++. Paste the xml in the text editor.
  4. Now you'll have to learn by yourself how the XML is built. Don't worry, it's very simple. Note that each column is a xml element called saw:column and the style is stored in its child element called saw:displayFormat.
  5. Start recording the macro and copy the desired elements to the next column. After that, stop the recording. Pay attention to where the keyboard cursor is before and after the recording.
  6. Place the keyboard cursor in the desired place and run the macro several times as much as the columns you need to update. The shortcut to do it in Notepad++ is Ctrl+Shift+P.
  7. Paste the xml back in the report: Go back to the page where you copied the xml from, paste the new xml and click on "Set XML". That's it.
Learning the schema of the Request XML, you can do many other customizations to your report in one click. You'll see another example in my future post about searching all columns in one click. Thinking about this approach, you may find that it can help you to make your work shorter and cleaner.
 |  | 
Wednesday, January 13, 2010 11:09:42 PM (Jerusalem Standard Time, UTC+02:00)
I'd recommend Microsoft's free XML Notepad for this kind of thing.
Right tool for the right job, sometimes XML Notepad is better at copying nodes etc.
I use it side by side with Notepad++ :-)
Thursday, May 13, 2010 5:50:31 PM (Jerusalem Daylight Time, UTC+03:00)
hi

I cannot find the schema of the Request XML. could you tell me where is it ?
jz
Thursday, May 13, 2010 8:12:18 PM (Jerusalem Daylight Time, UTC+03:00)
Hi jz,

In the request editing mode, go to the advanced tab.

Miky.
Friday, May 14, 2010 12:15:17 PM (Jerusalem Daylight Time, UTC+03:00)
Hi Miky,

I can see the request xml in advanced tab,it' possible to see / define the XML (saw:criteria, saw:columns, saw:views etc). but I want to get the schema of the request xml. Do you know the location of XSD/DTD?

Jz
jz
Friday, May 14, 2010 4:14:45 PM (Jerusalem Daylight Time, UTC+03:00)
You can generate the XSD for yourself from the xml. try this: http://www.hitsw.com/xml_utilites/
All comments require the approval of the site owner before being displayed.
Name
E-mail
Home page

Comment (HTML not allowed)