Top 1
String query="select Top 1 from table"
String query="select * from table"i know second one means All the records. whats the meansing of first one ?
does the first one extracts 1 records only ? but i am getting all the records in my resultset. so i am confused by the phrase "Top 1".
can you please simplify it ?
Hi,
"top" is not ansi sql, so you have to take a look into your database documentation.
/Kaj
Similar Messages
-
I also am having a problem with the songs I purchased using the laptop not showing on the desk top itunes, even though it is authorized to do so. The new songs did show up on the iPad iTunes, however. Have no idea why. I thought this happened automatically.
Welcome to the Apple Community.
You can re-download content purchased from the iTunes store (availability varies depending on location) using the purchased option from the Quick Links section in the top right corner of the iTunes homepage in your iTunes application on your computer.
You can re-download content purchased from the iTunes store (availability varies depending on location) using the purchased option which is revealed in the iTunes app on your iOS device by tapping the more button at the bottom of the screen. -
I am adding more memory, should I replace the top two slots with the 4g memory modules, then place 2g memory modules on bottom slots. Does it even matter?
I am adding more memory, should I replace the top two slots with the 4g memory modules, then place 2g memory modules on bottom slots. Does it even matter?
-
How to pass field in Alv Top-of-page
Edited by: Deepak Mathrani on Aug 12, 2008 12:40 PM
<THREAD LOCKED. Please read the [Rules of Engagement|https://wiki.sdn.sap.com/wiki/display/HOME/RulesofEngagement] to discover why>
Edited by: Mike Pokraka on Aug 12, 2008 2:58 PMHi
sample program
*& Report ZNNR_ALVSAMPLE
REPORT znnr_alvsample NO STANDARD PAGE HEADING.
TABLES: ekko.
TYPE-POOLS: slis. "ALV Declarations
*Data Declaration
TYPES: BEGIN OF t_ekko,
ebeln TYPE ekpo-ebeln,
ebelp TYPE ekpo-ebelp,
statu TYPE ekpo-statu,
aedat TYPE ekpo-aedat,
matnr TYPE ekpo-matnr,
menge TYPE ekpo-menge,
meins TYPE ekpo-meins,
netpr TYPE ekpo-netpr,
peinh TYPE ekpo-peinh,
END OF t_ekko.
DATA: it_ekko TYPE STANDARD TABLE OF t_ekko INITIAL SIZE 0,
wa_ekko TYPE t_ekko.
*ALV data declarations
DATA: fieldcatalog TYPE slis_t_fieldcat_alv WITH HEADER LINE,
gd_tab_group TYPE slis_t_sp_group_alv,
gd_layout TYPE slis_layout_alv,
gd_repid LIKE sy-repid.
*Start-of-selection.
START-OF-SELECTION.
PERFORM data_retrieval.
PERFORM build_fieldcatalog.
PERFORM build_layout.
PERFORM display_alv_report.
*& Form BUILD_FIELDCATALOG
Build Fieldcatalog for ALV Report
FORM build_fieldcatalog.
There are a number of ways to create a fieldcat.
For the purpose of this example i will build the fieldcatalog manualy
by populating the internal table fields individually and then
appending the rows. This method can be the most time consuming but can
also allow you more control of the final product.
Beware though, you need to ensure that all fields required are
populated. When using some of functionality available via ALV, such as
total. You may need to provide more information than if you were
simply displaying the result
I.e. Field type may be required in-order for
the 'TOTAL' function to work.
fieldcatalog-fieldname = 'EBELN'.
fieldcatalog-seltext_m = 'Purchase Order'.
fieldcatalog-col_pos = 0.
fieldcatalog-outputlen = 10.
fieldcatalog-emphasize = 'X'.
fieldcatalog-key = 'X'.
fieldcatalog-do_sum = 'X'.
fieldcatalog-no_zero = 'X'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'EBELP'.
fieldcatalog-seltext_m = 'PO Item'.
fieldcatalog-col_pos = 1.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'STATU'.
fieldcatalog-seltext_m = 'Status'.
fieldcatalog-col_pos = 2.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'AEDAT'.
fieldcatalog-seltext_m = 'Item change date'.
fieldcatalog-col_pos = 3.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'MATNR'.
fieldcatalog-seltext_m = 'Material Number'.
fieldcatalog-col_pos = 4.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'MENGE'.
fieldcatalog-seltext_m = 'PO quantity'.
fieldcatalog-col_pos = 5.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'MEINS'.
fieldcatalog-seltext_m = 'Order Unit'.
fieldcatalog-col_pos = 6.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'NETPR'.
fieldcatalog-seltext_m = 'Net Price'.
fieldcatalog-col_pos = 7.
fieldcatalog-outputlen = 15.
fieldcatalog-do_sum = 'X'. "Display column total
fieldcatalog-datatype = 'CURR'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
fieldcatalog-fieldname = 'PEINH'.
fieldcatalog-seltext_m = 'Price Unit'.
fieldcatalog-col_pos = 8.
fieldcatalog-EDIT = 'X'.
APPEND fieldcatalog TO fieldcatalog.
CLEAR fieldcatalog.
ENDFORM. " BUILD_FIELDCATALOG
*& Form BUILD_LAYOUT
Build layout for ALV grid report
FORM build_layout.
gd_layout-no_input = 'X'.
gd_layout-colwidth_optimize = 'X'.
gd_layout-totals_text = 'Totals'(201).
gd_layout-totals_only = 'X'.
gd_layout-f2code = 'DISP'. "Sets fcode for when double
"click(press f2)
gd_layout-zebra = 'X'.
gd_layout-group_change_edit = 'X'.
gd_layout-header_text = 'helllllo'.
ENDFORM. " BUILD_LAYOUT
*& Form DISPLAY_ALV_REPORT
Display report using ALV grid
form display_alv_report.
gd_repid = sy-repid.
call function 'REUSE_ALV_GRID_DISPLAY'
exporting
i_callback_program = gd_repid
i_callback_top_of_page = 'TOP-OF-PAGE'(001) "see FORM
i_callback_user_command = 'USER_COMMAND'
i_grid_title = outtext
is_layout = gd_layout
it_fieldcat = fieldcatalog[]
it_special_groups = gd_tabgroup
IT_EVENTS = GT_XEVENTS
i_save = 'X'
is_variant = z_template
tables
t_outtab = it_ekko
exceptions
program_error = 1
others = 2.
if sy-subrc <> 0.
MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
endif.
endform. " DISPLAY_ALV_REPORT
*& Form DATA_RETRIEVAL
Retrieve data form EKPO table and populate itab it_ekko
form data_retrieval.
select ebeln ebelp statu aedat matnr menge meins netpr peinh
up to 10 rows
from ekpo
into table it_ekko.
endform. " DATA_RETRIEVAL
Form TOP-OF-PAGE *
ALV Report Header *
Form top-of-page.
*ALV Header declarations
data: t_header type slis_t_listheader,
wa_header type slis_listheader,
t_line like wa_header-info,
ld_lines type i,
ld_linesc(10) type c.
Title
wa_header-typ = 'H'.
wa_header-info = 'EKKO Table Report'.
append wa_header to t_header.
clear wa_header.
Date
wa_header-typ = 'S'.
wa_header-key = 'Date: '.
CONCATENATE sy-datum+6(2) '.'
sy-datum+4(2) '.'
sy-datum(4) INTO wa_header-info. "todays date
append wa_header to t_header.
clear: wa_header.
Total No. of Records Selected
describe table it_ekko lines ld_lines.
ld_linesc = ld_lines.
concatenate 'Total No. of Records Selected: ' ld_linesc
into t_line separated by space.
wa_header-typ = 'A'.
wa_header-info = t_line.
append wa_header to t_header.
clear: wa_header, t_line.
call function 'REUSE_ALV_COMMENTARY_WRITE'
exporting
it_list_commentary = t_header.
i_logo = 'Z_LOGO'.
endform. -
I cannot open Pages from the app or from a saved document on the desk top. I get an error: "The application Pages cannot be opened -1712" Any suggestions?
The following previous discussion has a solution that worked for a variety of people with the -1712 error on a variety of applications and may help: The application Safari can't be opened -1712
-
I cant get iTunes to open on my macbook pro, when I click on the icon it shows the iTunes name on the top of the page but the library wont open , and when I click the tabs it doesnt do anything. What can I do? Its driving me insane!!
HELP!!On the iTunes menu bar, click the Window tab. Is itunes selected?
-
Trying to get an old iMac up to be enough for my four year old to go on the internet. Upgraded to panther and put an airport card in. Now problems;
1. It can connect to my airport express, but not if I have the password enabled, then it won't, even if I put the password in.
2. There are 3 hard drives showing on the desk top, with the space divided between them.
3. I've been trying to download an old version of flash, but it never finishes and says it can't write the file or something like that. I kind of think it has to do with the file being to large and since the hard drive is divided, it won't fit.
Let me know if anybody can help and thank you for your time....Your old iMac can only connect to a WEP network, and yours is probably WPA. As far as the partitions are concerned, if you don't need any any of the data on it, use your Panther disc and erase and fomat it as one partition.
-
My family uses a single lap-top as our home computer and several of us have i-pods that we like to synch, using I-tunes. Although we've tried to create separate I-tune accounts, our i-tunes playlists are getting wiped out when one of us deletes songs on our I-pod and it seems as though I-tunes is not distinguishing our distinct accounts and all i-pods are being synched to reflect the latest i-pod anyone makes on their respective account. It appears as though our distinct I-tune accounts are not being loaded on our lap-top when we sign in and unfortunately, when we're in I-tunes, there is nothing to indicate what account is on the screen. For all the glowing appraisals apple-related products usually receive, we are finding i-tunes and its interface with our respective i-pods to be a very, very frustrating experience.
Can anyone shed some light on this for a family of non-techies? Thx
Pegger64You need to create separate Windows user accounts if you want to seperate the behaviour of iTunes for each user. That also means separate iTunes libraries for each user.
Windows is a multi-user operating system but you are not using it properly. iTunes is not a multi-user application. No application is. You can't expect it to treat different users differently when they are all using the same computer user account.
Do you understand what I mean? -
Please change the view in the top sites, the 6.1 upgrade has reverted back to a plain two-dimensional view, which is a little dated. Can I revert back to an older version via my time capsule save? C'mon Apple upgrades supposed to leap into the future not the past. :-(
Please change the view in the top sites, the 6.1 upgrade has reverted back to a plain two-dimensional view, which is a little dated. Can I revert back to an older version via my time capsule save? C'mon Apple upgrades supposed to leap into the future not the past. :-(
-
How can I sync ONLY the top photo in the stack?
I sync various Aperture photo albums to my IPad and iPhone. The problem is that when I have 'stacked' images (eg. one image showing in the album and two other copies 'hidden' underneath), all of the photos in the stack are copied to the ipad and iPhone. So instead of seeing just one version of an image, I see as many as are in the stack. How can I sync ONLY the top photo in the stack?
Thanks for your help!I solved my own problem.
The sync problem seemed to only occur on smart albums. There is a new check box option in Aperture 3 when making a smart album: "sync stack pick only." One click and the problem is solved! -
How To Print Field Value in TOP-OF-PAGE During Line Selection.
How To Print Field Value in TOP-OF-PAGE During Line Selection when double click on field.
(If my memory serves me well (not used for long time ago)
Assign values to system fields sy-tvar0 - sy-tvar9, they will replace the placeholders "&0" through "&9" in the list headers and column headers.
TOP-OF-PAGE DURING LINE-SELECTION.
WRITE: / 'Interactive Report &3'.
WRITE record-vbeln TO sy-tvar3.
Regards,
Raymond -
Well that's pretty much it. The foxfire help page, now that I've upgraded to the newest version says to look for the "foxfire" button at the top left which would be located in the blue bar that instead still tells me what the name of that particular page is that I am viewing, just as it always has but there is no "foxfire button there for me to click on in order to get my bookmarks, my favorites re-imported from IE version 6.0. I actually installed them via the instructions under foxfire version 6.0 a month ago originally without any problem, and then again on version 7.0 after I recently rebuilt this machine using windows 2000 professional and everything got imported Okay except for one file... And of course it was the most important folder, my favorites folder which I had named "business" because it was the folder which contained all my links that I need for "business". So naturally, I am eagerly awaiting a reply to tell me what it is that I need to do. Could it be as simple as I have not re-booted since I upgraded earlier today/yesterday? That actually IS a possibility I suppose because I don't remember re-booting afterward or being told to in or after the process of upgrading. After the upgrade, there simply was not any indication that I needed to. (As I recall anyhow!) It's currently one in the morning and that was twelve hours ago. But I honestly don't think that I was instructed to after clicking on "install" the new version. But if it did tell me to afterward, I'm sure I must have even though I don't remember it as my extensive history with personal computing and installing everything from hardware to software including operating systems tells me that if it had told me to re-boot, I would have.
Thank you in advance,
Eric G.You are on Windows 2000, you do not have a "Firefox" button, and should consider yourself to be fortunate in that you still have menus and don't have to do anything to get the menus back instead of the "Firefox" button. (The same applies to Windows XP users).
Use the "File" menu to get to Import. You are not on Windows 7 or Vista, and don't have to put up with the nonsense added for Aero.
If you want the "Firefox" button you can get it with View -> toolbars -> (uncheck) Menu Bar. The menu bar and the "Firefox" button were supposed to be mutually exclusive (which is impossible in some cases without being incompatible).
Once you are using the "Firefox" button ...
Use the "Alt" key to view the menu bar (temporarily) containing File, Edit, View, History, Bookmarks, Tools, and Help. On Windows 7 and Vista, the menu bar was hidden by default in Firefox 4 and above. These menu items are more or less available under the "Firefox" button which has the most used of the built-in Firefox menu items available in a different format.
To get back to having menus again. "Firefox" button -> Options (second column) -> (check) Menu Bar
You can make '''Firefox 7.0.1''' look like Firefox 3.6.*, see numbered '''items 1-10''' in the following topic [http://dmcritchie.mvps.org/firefox/firefox-problems.htm#fx4interface Fix Firefox 4.0 toolbar user interface, problems (Make Firefox 4.0 thru 8.0, look like 3.6)]. ''Whether or not you make changes, you should be aware of what has changed and what you have to do to use changed or missing features.''
* http://dmcritchie.mvps.org/firefox/firefox-problems.htm#fx4interface -
How to create a table report with alphabetic link at the top
Hello,
I have a db table of users, and have created a report based on this table, however I want to have each aphabet letter at the top of the report so that users can click on the letter and see all records where the username field starts with that letter.
How can I achieve this?
Thanks,Hello user11243298 (please tell us your name),
Your report query would look something like this (assuming page number is 1):
select some_column1, some_column2
from your_user_table
where username like :P1_INITIAL || '%'
For the letters at the top of the report, here's a couple options:
- If you want all letters to appear whether or not there are any rows, you can create a series of buttons or links, one for each letter, and specify the target URL to submit back to the report page, setting the item P1_INITIAL to each letter.
- If you want only letters that have rows, one way is to create a dynamic LOV based on a query like this:
select distinct upper(substr(username, 1, 1)) d, distinct upper(substr(username, 1, 1)) v
from your_user_table
order by upper(substr(username, 1, 1))
Then use that for a select list with submit, again targeting the report page and setting P1_INITIAL to the selected value.
Hope this helps (if it does, please reward it),
John -
Possible to Have ToC Default to Show Only Top Level (collapse sublevels)?
Howdy!
I'll bet I'm not the only one wishing for this. Let's say you're using Captivate 4's Table of Contents feature with a longish movie of Cp slides, which is chunked into bite-size sections content-wise. In the ToC, though, you can't mimic that same organization scheme; at least, the learner would first need to collapse all the ToC folders you've created so they see only the top-level listing.
This can be a critical issue: keeping the at-first-glance list in the ToC brief enough to be inviting to learners, yet allowing learners to drive which details are currently visible.
A movie's topical hierarchy could be along these lines, for example ...
Section 1 - National Brands
What are National Brands?
Why Are They Important to Our Business?
Working with Nat. Brands
Practice Your Knowledge
Section 2 - International Brands
What are International Brands?
Why Are They Important to Our Business?
Working with Intl. Brands
Practice Your Knowledge
You'd like to organize the ToC to show only the section titles (1st level) and to suppress the 2nd-level detail (slide titles) until the learner chooses to expand the folder to see those details.
I've tried things like grouping the slides into sections in the Storyboard view and organizing the slides into sections strictly within the ToC -- both to no avail.
Has anyone solved for this need yet?
I'm all ears, and you'd be doing learners of the world a huge favor.
Thanks!Hi, Jim.
Thanks for being 'on the case' and looking into this so quickly. Your
findings are encouraging, although my user base is generally working with
IE 6 and FP8 or 9.
Since the only thing I may influence is getting IT to help push out FP10,
I'm hoping it's more of a player- than a browser-version issue.
I'll test things out by Monday and let you know the results. Wish me luck!
Dave
From: Jim Leichliter <[email protected]>
To: Dave Tressler <[email protected]>
Date: 03/26/2010 06:02 PM
Subject: Possible to Have ToC Default to Show Only Top Level (collapse
sublevels)?
Dave,
I just tested this on my local web server and it worked fine. I created a
blank project with 8 slides. Created my TOC with grouping... 2 slides in
each group. I turned on self paced learning. I tried with and without the
widget and it picked up where I left off in either case. See
https://docs.google.com/leaf?id=0B86WuEq6SVwRNWIwMjhjODctMjE2Yy00MWE2LWI5YzEtMGQxYzNjOWQ0Z mI2&hl=en.
I published using FP10 and IE8 to view. Notice any difference between
your project and this one?
Thanks,
Jim Leichliter -
Looking for a todo app that puts new todos at the top of the list
I've been using Appigo's ToDo for several years now. It's elegant, fast, intuitive, and feature packed. One of the best things it has is the ability to drag todos around manually and their due dates change.
There is one thing, however, that I wish it did. I would like the new todos to appear at the top of the todo list instead of the bottom, so I do not have to scroll through a long list to check if anything new has shown up.
Are there any todo apps that do things this way?Maybe Clear can do that for you?
Clear by Realmac Software
https://itunes.apple.com/us/app/clear/id493136154?mt=8
Personally I use Due (http://www.dueapp.com/) every day. But that is a reminder, more then a todo app. -
When I try to open safari the icon stats bouncing and then nothing happens other than the cursor turning to a spinning rainbow wheel when it hoovers on the top main menu bar. I have shut down and restart several times. My safari worked yesterday and then today this, but with. I indication of a problem. I can't even get the browser window to open so that I can clear caches or reset anything. When I opened my computer this time I don't even get a bouncing icon. No recognition of selecting the program at all. If I go to spotlight and try to open safari from here I still get no response. Can you help?
Hi ...
If you have moved the Safari application from the Applications folder, move it back.
As far as the cache goes, there's a work around for that when you can't empty the Safari cache from the menu bar.
Go to ~/Library/Caches/com.aple.Safari.Cache.db. Move the Cache.db file to the Trash.
Try Safari.
Mac OS X (10.7.2) < from your profile
If that is corrrect, you need to update your system software. Click your Apple menu icon top left in your screen. From the drop down menu click Software
Update ...
~ (Tilde) character represents the Home folder.
For Lion v10.7x: To find the Home folder in OS X Lion, open the Finder, hold the Option key, and choose Go > Library
Maybe you are looking for
-
Has anyone gone to Europe from the US and used the IPAD charger with only a plug adapter? I want to be sure I won't burn up my IPAD.
-
Validations in OB28 to display message in FB08 and FBRA?
Hi, I need to put a Validation such that transactions FB08 and FBRA should not execute if Document Type (BKPF-BLART) is 'P0'. I wrote the below validation at Line item level in OB28 but it is not working. Would appreciate if someone can tell me where
-
Opening SAP Transactions in a Maximised New Window
Hi, I have an SAP Transaction iview that should open an SAP WinGui Transaction in a maximized new window. I have set the following properties Launch In =1 Height Type = FULL_PAGE Height of External Window = -1 Width of External Window = -1 The new wi
-
ABAP Editor not allowing me to input the code..
Hi Gurus, I am trying to enhance my datasource, but whenever i type cmod and enter the ABAP editor screen, i can not type anything, even though i am in change mode....the screen is with white background and i can not type at all....please help with m
-
Safari & finder crash after waking up
Hello, Since upgrade to 10.8, my iMac crash a few time around sleeping and waking up state, here an exemple : Aug 12 10:35:08 iMac-ofXXXXX kernel[0]: Ethernet [AppleBCM5701Ethernet]: Link up on en0, 100-Megabit, Full-duplex, Symmetric flow-control, D