How to do this Order by ?
Hi all,
I have simple query to show the output, however, when I try to order the result, it does not shown the way that I have expected.
My SQL query is :-
SELECT BOM_level,BI_ITEM_CODE
FROM (
SELECT LEVEL BOM_LEVEL, BOM_CODE, BOM_ITEM_CODE, BOM_GRADE_CODE_1,
BOM_COPY_BOM,BOM_EFF_FROM,ITEM_FLEX_01,
BOM_GRADE_CODE_2, BOM_UOM_CODE, DECODE(BOM_DYNAMIC_QTY_YN_NUM, 2, NVL(PRIOR BI_QTY_BU,1) * BOM_QTY_BU, 1, 100) BOM_QTY_BU,
BI_ITEM_CODE, BI_GRADE_CODE_1, BI_GRADE_CODE_2,
BOM_DYNAMIC_QTY_YN_NUM, BI_BOM_CODE, BI_UOM_CODE,
BI_RM_REF_PERC, BI_RM_REF_PERC_YN_NUM, DECODE(BOM_DYNAMIC_QTY_YN_NUM, 1, DECODE(BI_RM_REF_PERC_YN_NUM, 2, DECODE(BI_QTY_BU, 0, BI_RM_REF_PERC, NULL, BI_RM_REF_PERC, BI_QTY_BU), BI_QTY_BU), 2, NVL(PRIOR BI_QTY_BU,1) * BI_QTY_BU ) BI_QTY_BU,
BI_MAX_VARIANCE, BI_LOWEST_LEVEL_YN, BI_ITEM_TYPE,
'M',
BOM_RM_REF_PERC_YN_NUM
FROM OM_BOM, OM_BOM_ITEM_DETAIL, OM_ITEM_PLANT_PROPERTY_HEAD,
OM_ITEM_PLANT_PROPERTY_DETAIL, OM_ITEM
WHERE BOM_CODE = BI_BOM_CODE
AND IPH_SYS_ID = IPD_IPH_SYS_ID
AND IPH_PLANT_CODE = IPD_IPH_PLANT_CODE
AND IPH_ITEM_CODE = IPD_IPH_ITEM_CODE
AND IPH_GRADE_CODE_1 = IPD_IPH_GRADE_CODE_1
AND IPH_GRADE_CODE_2 = IPD_IPH_GRADE_CODE_2
AND IPH_ITEM_CODE = ITEM_CODE
AND NVL(ITEM_FRZ_FLAG_NUM,2) = 2
AND IPH_APP_CODE_NUM = 1
AND BOM_ITEM_CODE = IPH_ITEM_CODE
AND BOM_CODE = BI_BOM_CODE
AND NVL(BOM_DEVELOPMENT_YN_NUM, 2) = 2 commented by vellingiri.n on 22/06/2007 for enabling the development BOM
AND NVL(BOM_FRZ_FLAG_NUM, 2) = 2
AND IPD_ATTR_CODE = 'DFLT_BOM_CODE'
AND IPD_ATTR_VALUE IS NOT NULL
AND BOM_CODE = IPD_ATTR_VALUE
CONNECT BY PRIOR BI_ITEM_CODE = BOM_ITEM_CODE
AND PRIOR BI_LOWEST_LEVEL_YN = 'N'
--START WITH BOM_CODE = :PWH_BOM_CODE
START WITH BOM_CODE = :REP_VALUE_1
--AND BOM_ITEM_CODE = :PWH_ITEM_CODE
--AND BOM_GRADE_CODE_1 = :PWH_GRADE_CODE_1
--AND BOM_GRADE_CODE_2 = :PWH_GRADE_CODE_2
--WHERE BI_LOWEST_LEVEL_YN = 'Y'
ORDER BY BOM_LEVEL, BOM_ITEM_CODE;
and the result shown :-
BOM_LEVEL BI_ITEM_CODE
1 30-42-009-X
1 10-20-025
1 30-16-001
1 F1-80-117
1 30-32-010
1 21-76-024
1 CW20R-EL-01
2 10-28-001-1
2 10-30-051
2 30-56-289
2 E0-70-001
2 31207101
2 31207201
2 32200150
2 51300023
2 51300024
2 10-06-148
The order by has ordered the bom_level column but the bi_item_code are not properly order. How to make it possible that both column also order correctly ?
URGENT!!!help.
Thanks.
Lim
What makes this urgent? Is the data center on fire? If so call 911.
It isn't urgent enough to post a sort order
It isn't urgent enough to post an explain plan
It isn't urgent enough to post a version number
Speaking for myself ... I won't help anyone who claims their problem is urgent so consider an apology and provide appropriate information.
Similar Messages
-
How to change the order of download options as per our convience in obiee
hi frineds,
How can i change the order of the download options in obiee dashboard ?
like if you press download option you see
download to excel
download to excel 2000
download data
download webpage(mhtml)
how to change this order.????????The download options are setup in OracleBI\web\msgdb\messages\viewscontrolmessages.xml
- Search for the tag *<WebMessage name="kmsgEVCDownloadLinks">* that contains the download links within the hyperlink tag
- Each hyperlink tag is a download option
- Reorder as you require
- The actual text that gets displayed as a link can also be customized by editing the entry for a message such as kmsgEVCLinkDownloadExcel in the OracleBI\web\msgdb\l_en\messages\viewmessages.xml [the customization is locale specific]
- Restart the presentation server -
All,
I had created a Line chart graph with three measures (Total Employees, Total Promotion and Total Hires) for last 12 months. Chart legend is displaying this order, Total Employees, Total Promotions and Total Hires. But my requirement is , Legend supposed to be display this order, Total Hires, Total Employees and Total Promotions. How to change this order in Graph?Hi
Pull up a Column and click in the fx and there write the below formula
Case when column Type ="Total Hire' then '1'
when column Type = 'Total Employee' then '2'
when column Type ='Total Promotion' then '3'
else null end
Then sort the column in asc order and then hide the column
You will find that the original measure column is sorted as required
Regards
Debo
Edited by: Debo Roy on Sep 8, 2010 8:03 PM
Edited by: Debo Roy on Sep 8, 2010 8:21 PM -
How to program a midi foot controller on Mainstage? Does anyone knows how to program the foot controller with exclusive solo channel in order not to dance "tip tap" while from clean guitar I go to crunch or solo? How to do this programming on Mainstage?
I basically managed to learn how to invert parameters which allows me to be as default in the clean guitar channel and if I switch the first button on the midi foot controller I switch to crunch, but at this point I tryied so hard to programm the second and third button to switch, only through a button in one step, to a third channel for distorsion or a 4th channel for solo guitar but I couldn't figured out how this work can be done!
I would appreciate if anyone could help or share this experience with others who are experiencing the same problem.
Cheers.
F.I cannot seem to get mainstage to recognize my FCB either. I am using IFCB. Anyone figure this out?
Thanks,
Eric -
When uploading a cd onto itunes on my imac it has choosen to copy the original cd into 4 seperate cds and mix up the track order, particularly annoying as this is a mixed cd (Guy Gerber, fabric 64) . Any ideas why when everthing else copies perfectly and how to rectify this problem?
See Grouping tracks into albums.
tt2 -
I've erased and formatted the hard drive accordingly in order to reinstall OS X. everything went fine until about half way through the install. it just seems to stop. how long should this take? should i do something else to speed it up?
About all you can do is wait until it finishes or you get an error message.
-
My mail will not delete. When I move it to trash and then delete it, within a few minutes it has all bounced back in again. Checked my preference settings and all seems to be in order. Any ideas how to resolve this frustrating problem?
That sounds like a compatibility issue with an add-on that you have installed, as reported by a number of users in both Firefox 22 and Firefox 23 over the last couple of months. If you would provide a listing of your installed extensions ''(as you were prompted to do when creating this thread)'' maybe one of us can advise you which extension is the mot likely culprit. You will need to re-install Firefox 23 to do further diagnostic testing.
As far as the compatibility of Firefox 23 and Win XP SP3, Mozilla has verified they are compatible and not one user ''(including me on two separate PC's)'' has reported a problem with compatibility. -
I delete an individual message but the time I received the message is still showing next to the persons name in my inbox instead of going back into the correct date/time order. Anyone know how to fix this?
SOLUTION
Open "terminal" on your mac and type the following:
defaults write com.apple.mail IgnoreSortOrderWhenSelectingAfterDelete 1
(copy and past the whole line)
This will stop that behaviour in mail.
It works on most opperating systems.
mine is.
Mac OSx 10.7.2 Lion
Cheers -
When I insert a disk, a disk icon does not appear on my desktop, nothing happens and there is no option to eject. I have to restart in order to eject the disk. Any ideas on how to fix this problem?
-
Hi
I am trying to print off a CD cover with the running order of songs as it appears on the CD.
It prints things off ok but only alphabetical lists of songs.
I do not know how to get the songs into the correct order and print them off.
Does anyone know how to do this? Or does it only print off songs alphabetically?
Hope you can help.
Cheers!Greetings,
I've never seen this issue, and I handle many iPads, of all versions. WiFi issues are generally local to the WiFi router - they are not all of the same quality, range, immunity to interference, etc. You have distance, building construction, and the biggie - interference.
At home, I use Apple routers, and have no issues with any of my WiFi enabled devices, computers, mobile devices, etc - even the lowly PeeCees. I have locations where I have Juniper Networks, as well as Aruba, and a few Netgears - all of them work as they should.
The cheaper routers, Linksys, D-Link, Seimens home units, and many other no name devices have caused issues of various kinds, and even connectivity.
I have no idea what Starbucks uses, but I always have a good connection, and I go there nearly every morning and get some work done, as well as play.
You could try changing channels, 2.4 to 5 Gigs, changing locations of the router. I have had to do all of these at one time or another over the many years that I have been a Network Engineer.
Good Luck - Cheers,
M. -
Hello,
I ordered a White Galaxy Note 4 recently. I need to change the color to BLACK. Unfortunatley Verizon makes it near impossible to change or cancel orders. I need to do this ASAP. The problem is I cannot call them, I am currently in another country. I refuse to believe that this order cannot be changed without calling them. How can I change this online? I need to do this ASAP so I can get the same ship by date.
I do not know why this has to be so difficult, I am starting to regret ordering from Verizon, because Amazon makes it so easy. Could somebody help? ThanksThanks for reaching out, Dmajs! I'd love to help look into options. I've sent you a direct message, feel free to reply when you have an opportunity. Thanks!
YosefT_VZW
Follow us on Twitter @VZWSupport -
I'm trying to order a calendar off iphoto and have never had any issues, now it wont allow me to input a canadian address for ordering help help help this is an xmas gift and i have no idea how to fix this have tried numerous things
No I didn't even read through your post, to long.
You said that "No matter what program I try to install, as soon as the installer opens it crashes". Were you talking about the install for this/these 3D programs or ANY program? As it is worded it sounded like ANY program. That tells me there is a problem with your Mac, software or hardware.
Now you say others install programs, which is it. Programs other then the 3D ones install or no programs install?
Could simply be your Mac is to old to run these programs and the installer knows that. You never said what model or year Mac it is. -
am trying to set my background setting to change when ever I log in, I clicked on both 'change picture' and 'random order' boxes as my settings, but when ever I log in it has the same background as before. Does any body know how to fix this?
You have to enter the Apple ID and password. You are running into the Activation Lock
iCloud: Find My iPhone Activation Lock in iOS 7
Is there a way to find my Apple ID Name if I can't remember it?
Yes. Visit My Apple ID and click Find your Apple ID. See Finding your Apple ID if you'd like more information.
How do I change or recover a forgotten Apple ID Password?
If you've forgotten your Apple ID Password or want to change it, go to My Apple ID and follow the instructions. SeeChanging your Apple ID password if you'd like more information. -
I never downloaded the movie how do i cancel this order?
i never downloaded this movie how do i cancel this order?
All purchases are considered final, but you can try the 'report a problem' link to contact iTunes Support and see if they will refund or credit you : http://reportaproblem.apple.com
If the 'report a problem' link doesn't work then you can try contacting iTunes Support via this page : http://www.apple.com/support/itunes/contact/ - click on Contact iTunes Store Support on the right-hand side of the page, then Purchases, Billing & Redemption -
When I try to order a book in iPhoto it says I have empty frames on pages. But I don't. Any advice on how to correct this so I can order this book? Thanks.
You do have one or more empty photo frames. Most often it will be a full page photo page missing behind a placed full page photo. To find it you need to go through you'd book and look behind each full page photo
LN
Maybe you are looking for
-
Used "Reset Firefox" because of persistent problem with flash freezing Firefox.
-
Is 2009 imac 27 i7 compatible with maverick
I'm about to purchase a 2009 imac but don't want a massive outdated paperweight. Is this comp still able to be updated with the current Opp systems?
-
AdvancedMedia Sample doesn't run video (MediaPlayer)
Hi! Running the AdvancedMedia sample from JavaFX everything works OK. Using MediaPlayer class it shows the flash video from http://download.oracle.com/otndocs/products/javafx/oow2010-2.flv The problem is if I try to read other flash video... There is
-
Bonjour, je posède un PowerBook G3, qui me pose bien des soucis !!!! lorsque je l'allume il ne s'allume qu'après le 8 ou 10 ième reboot , la il fonctionne corectement ( que ce soit sur le secteur ou avec ça batterie). quelqu'un a t 'il une idéé d'ava
-
Is it possible to have a button to delete rows in a static table? Each row is different but certain rows may not be needed depending on customer and was wondering if rows in a static table can be deleted. Help on this is very much appreciated...tha