Thank you all for the replies. Maybe I didn't explain my requirement clear enough, sorry about that.
I would like to set up alternative dialing routes by press * first then the number, in the case the primary route is degraded or stopped working. (# is o.k also.) However, it has to be able to select the right gateway based on the number it is dialed. For example, I use SP1 and SP2 as the primary routes for domestic and international calls, respectively. Say GW3 and GW4 as for the secondly routes. If I dial * with an domestic number, I would like it go to GW3. If I dial * with 011xxxxxxxxxxxx, I would like it go to GW4. In SPA3102, it can be done as: <*:>1[2-9]xxxxxxxxx<:@gw3> and <*:>011xxxxxxxxxxxx<:@gw4>. However, I don't know if it can be done in Obi also. Associate * or # with one of the GWs will not work.