Serial Number In Abap Query
How can we add <b>Serial Number</b> in SAP Query? There is a field named Counter which gives Total number of count. But i need numbers to be displayed.
Any body can help me?
OK,
So you need to create a Number Range Object (tr SNRO), this create a object like ZNUM.
then, each time you need insert a new record to table only call this FM:
CALL FUNCTION 'NUMBER_GET_NEXT'
EXPORTING
nr_range_nr = '01'
object = 'ZNUM'
IMPORTING
number = itab-field
EXCEPTIONS
interval_not_found = 1
number_range_not_intern = 2
object_not_found = 3
quantity_is_0 = 4
quantity_is_not_1 = 5
interval_overflow = 6
buffer_overflow = 7
OTHERS = 8.
at this point, ITAB-FIELD contains the next number in the range ZNUM.
I hope this help,
X.S.
Similar Messages
-
Serial Number in SAP Query !!!
Hi Gurus
How can we add Serial Number in SAP Query? There is a field named Counter which gives Total number of count. But i need numbers to be displayed with each line item.OK,
So you need to create a Number Range Object (tr SNRO), this create a object like ZNUM.
then, each time you need insert a new record to table only call this FM:
CALL FUNCTION 'NUMBER_GET_NEXT'
EXPORTING
nr_range_nr = '01'
object = 'ZNUM'
IMPORTING
number = itab-field
EXCEPTIONS
interval_not_found = 1
number_range_not_intern = 2
object_not_found = 3
quantity_is_0 = 4
quantity_is_not_1 = 5
interval_overflow = 6
buffer_overflow = 7
OTHERS = 8.
at this point, ITAB-FIELD contains the next number in the range ZNUM.
I hope this help,
X.S. -
How to get the transport request number of ABAP query.
I want to find out last Transport Request number used of a transporting changes Abap query from development to quality system.
Also is it possible to do some comparison on version existing in development and quality for abap query.goto SE03 ..
In Object Directory -> Double click on
Change Object Directory Entries
Enter AQQU(This is for ABAP Query) in the modifiable box ..
press enter ...
Check this check box ... Enter the ABAP query and press F8.
Double click on the Query and in the popup click on the
Lock Overview ...
U'll find the request number ...
Edited by: Srinivas Gurram Reddy on Apr 2, 2008 6:53 PM -
Hi All
I want to create Serial Number(running number like 1,2,3...)
in Rollup Query. But my problem is,I want to create running number all rows except for Toatl row.
EX:
select COMPANY,DEPT,SUM(SALARY) from emp
GROUP BY ROLLUP(COMPANY_NAME,DEPT)
Expected O/P :
SL.No COMPANY DEPT SALARY
1 ABC P 60000
2 ABC A 40000
ABC 100000
3 XYZ P 30000
4 XYZ A 40000
XYZ 70000
170000
How to do the above? Help me..
Regs
KumarSQL> create table emp (company,dept,salary)
2 as
3 select 'ABC', 'P', 60000 from dual union all
4 select 'ABC', 'A', 20000 from dual union all
5 select 'ABC', 'A', 20000 from dual union all
6 select 'XYZ', 'P', 15000 from dual union all
7 select 'XYZ', 'P', 15000 from dual union all
8 select 'XYZ', 'A', 40000 from dual
9 /
Table created.
SQL> select case grouping_id(company,dept)
2 when 0 then row_number() over (order by grouping_id(company,dept),company,dept desc)
3 end sl_no
4 , company
5 , dept
6 , sum(salary)
7 from emp
8 group by rollup(company,dept)
9 order by company
10 , dept desc nulls last
11 /
SL_NO COM D SUM(SALARY)
1 ABC P 60000
2 ABC A 40000
ABC 100000
3 XYZ P 30000
4 XYZ A 40000
XYZ 70000
170000
7 rows selected.Regards,
Rob. -
ABAP query not returning correct number of records
Hi,
I have created an ABAP Query using logical database VFV and nodes VBRK, VBUK and VBRP.
But, after entering values for Sales Organisation ( VBRK-VKORG ), Distribution channel ( VBRK-VTWEG ) and Date ( VBRK-FKDAT), the number of records that I get are very less in number as compared to the actual number in the database.
Please give some pointers to the reason. I have set Lines 60 and Columns length - 83 and selected ALV List.
Regards,
Garima.Hi Garima,
Please Check whether you are selecting all the Key fields in your Query.
Thanks & Regards,
Ashok kumar. -
ABAP query to find delivery number of a sales document
Hi Gurus,
Can anyone help me how can i create an ABAP query to fetch the delivery number of a sales order. What are the tables to be joined.
Through tables I got the solution. From VBAP table I fetched the sales order numbers. I copied the sales order numbers and opened VBFA table. In the preceding documents field I had pasted those sales orders numbers. Then I've selected subsequent document category 'J' to get the deliveries.
But now how to write an ABAP query for this.
regards
rama krishnaHi,
Try to use join query like:
Select vbfa~VBTYP_N INTO CORRESPONDING FIELDS OF TABLE itab from VBFA inner join VBAP
where vbapvbeln = VBFAVBELN.
Regards
Mudit -
Maximum number of records fetched by ABAP Query
Hi Experts,
Please tell me what is the specific maximum numbers of records that can be handled by an ABAP Query.
Thanks in advance.
Regards,
BilalUse a query similar to this.....
SELECT EBELN " Purchasing Document Number
ERNAM " Name of Person who Created
" the Object
LIFNR " Vendor's account number
EKGRP " Purchasing group
BEDAT " Purchasing Document Date
FROM EKKO
PACKAGE SIZE 10000
APPENDING TABLE T_EBELN
WHERE EBELN IN S_EBELN.
ENDSELECT.
Don't forget to write ENDSELECT.
Regards,
Pavan P. -
ABAP QUERY :transport number generation
Friends,
Please help me to generate the Transport request for ABAP query.
I have modified an existing custom ABAP QUERY.
I have followed the following process, but unable to get the transport number.
Goto SQ02. Select the proper query area. Press the transport button in the application bar.
Now u have two options...
1. Download and upload
2. Export and import.
The first option downloads the user/infoset & query on ur local server and then using upload u can bring it into other system. The second option creats transport request and u can use the normal way of transporting to the other system.When i try to do export to generate Transport request, I am getting information.
Export log : List of exported objects
Test export only
InfoSet ZCREDIT (import option REPLACE )
Query ZCREDIT of user group ZCREDIT (import option REPLACE ) -
Hi,
Currently I'm in my trainingperiod and I'm busy with a query to search on serialnumbers to find the needed info with it. Currently I have the next code:
SELECT DISTINCT T1.IntrSerial, T1.ItemCode, T1.ItemName, T1.WhsCode, T1.CardName, T3.CardName
FROM OSRI T1, INV1 T2, OINV T3, SRI1 T4, OCRD T5
WHERE T1.ItemCode = T2.ItemCode
AND T1.CardName = T5.CardName
AND T1.IntrSerial IN
(SELECT IntrSerial
FROM OSRI T1
WHERE T1.IntrSerial = 'm54275f00075' )
'm54275f00075' = a serial number so that's something you don't have to add. I added that line for my own help so I don't have to type a serialnumber each time. To search I use this line: WHERE T1.IntrSerial = '[%0]' FOR BROWSE
Now the problem is that he's giving me many customers when I search on a serial, while this isn't possible. There can only be 1 customer who bought the product with that serial and not like 200. So my question is how do I get the right customer who bought the product that contains the serial I'm searching for?
Any help is appreciated.
Thank you in advance!
Friendly greetings,
MartijnHi Martin,
I would structure the query a bit differently. You don't need to (or I don't understand why you) link the OINV and INV1 tables. Also the information from OCRD are stored in the OSRI table so that link is not needed, but I left it there so you can see my join.
SELECT T1.IntrSerial, T1.ItemCode, T1.ItemName, T1.WhsCode, T1.CardCode, T2.CardName
FROM OSRI T1
LEFT OUTER JOIN OCRD T2 ON T1.CardCode = T2.CardCode
WHERE T1.IntrSerial = 'm54275f00075'
Hope it helps,
Adele -
Hello all,
I want a query for show all the record along with serial number.Here i mentioned a sample table along with data.
COMPCODE
ITEMCODE
ACTIVITY
DESIGNATION
QTY
105
001
A13
D7
50
105
001
A22
D7
44
105
001
A34
7
54
105
001
A45
D7
34
105
001
A45
D8
54
105
001
A52
D13
32
105
001
A52
D14
3
105
001
A61
D2
43
105
002
A12
D1
43
105
002
A25
D1
53
105
002
A35
D5
42
105
002
A35
D4
45
105
002
A35
D3
65
105
002
A44
D2
423
105
002
A55
D3
43
105
002
A62
D4
65
These is the sample table along with data.My requirement is I want show the serial number based on the itemcode and activity.
The final result should be like this
COMPCODE
ITEMCODE
SLNO
ACTIVITY
DESIGNATION
QTY
105
001
1
A13
D7
50
105
001
2
A22
D7
44
105
001
3
A34
D7
54
105
001
4
A45
D7
34
105
001
4
A45
D8
54
105
001
5
A52
D13
32
105
001
5
A52
D14
3
105
001
6
A61
D2
43
105
002
1
A12
D1
43
105
002
2
A25
D1
53
105
002
3
A35
D5
42
105
002
3
A35
D4
45
105
002
3
A35
D3
65
105
002
4
A44
D2
423
105
002
5
A55
D3
43
105
002
6
A62
D4
65
I tried write a query used with row_number() function but i didn't get the exact output.kindly help me for getting this type of outputI see, try dense_rank instead:
SQL> with your_view_resultset as (
2 select 105 compcode, 001 itemcode, 'A13' activity, 'D7' designation, 50 qty from dual union
3 select 105, 001, 'A22', 'D7', 44 from dual union
4 select 105, 001, 'A34', '7', 54 from dual union
5 select 105, 001, 'A45', 'D7', 34 from dual union
6 select 105, 001, 'A45', 'D8', 54 from dual union
7 select 105, 001, 'A52', 'D13', 32 from dual union
8 select 105, 001, 'A52', 'D14', 3 from dual union
9 select 105, 001, 'A61', 'D2', 43 from dual union
10 select 105, 002, 'A12', 'D1', 43 from dual union
11 select 105, 002, 'A25', 'D1', 53 from dual union
12 select 105, 002, 'A35', 'D5', 42 from dual union
13 select 105, 002, 'A35', 'D4', 45 from dual union
14 select 105, 002, 'A35', 'D3', 65 from dual union
15 select 105, 002, 'A44', 'D2', 423 from dual union
16 select 105, 002, 'A55', 'D3', 43 from dual union
17 select 105, 002, 'A62', 'D4', 65 from dual
18 )
19 --
20 --
21 --
22 select t.*
23 , dense_rank() over (partition by t.itemcode order by t.itemcode, t.activity) slno
24 from your_view_resultset t
25 order by t.itemcode, t.activity;
COMPCODE ITEMCODE ACT DES QTY SLNO
105 1 A13 D7 50 1
105 1 A22 D7 44 2
105 1 A34 7 54 3
105 1 A45 D7 34 4
105 1 A45 D8 54 4
105 1 A52 D13 32 5
105 1 A52 D14 3 5
105 1 A61 D2 43 6
105 2 A12 D1 43 1
105 2 A25 D1 53 2
105 2 A35 D3 65 3
105 2 A35 D4 45 3
105 2 A35 D5 42 3
105 2 A44 D2 423 4
105 2 A55 D3 43 5
105 2 A62 D4 65 6
16 rows selected. -
dear all,
we are useing serial number profile. i want to create one query which will includes
material number,
document number,
movement type, with special indicator,
serial number applied.
qty
can anybody suggest me suitable table from which i can grab serial number ( in MIGO) field ?Hi
Have a look on these tables.
SER00 General Header Table for Serial Number Management
SER01 Document Header for Serial Numbers for Delivery
SER03 Document Header for Serial Numbers for Goods Movements
SER04 Document Header for Serial Numbers for Inspection Lot
SER05 Document Header for Serial Numbers for PP Order
SER06 Document Header for Serial Numbers for Handling Unit-Content
SER07 Document Header for Serial Numbers in Physical Inventory
SER08 Document Header for Purchase Order Item Serial Numbers
SERI Serial Numbers
check in table AFPO field ANZSN with respect to AUFNR
Thanks
S.Murali
Edited by: S.Murali on Sep 14, 2009 1:31 PM -
Query about perishable item and serial number entry in RMS
hi ,
can some one help me to explore the below mentioned option RMS
1. how can we mark an item as an perishable item in rms
2. where to enter the serial number for an item in RMS.
regards,
deepakhi erik,
yeah you are right its an unique number which is assigned to the product by the supplier which is not an barcode or PLU. when i tried to find the same i found vpn and LOV like upc , isbn and oracle retail number etc while i am in the process of creating an item.
i would like to know after we create an oracle retail number or the retailer's own sku number if we want to add multiple ean code and unique serial code how can we execute the same in RMS.
eg 1: a brand of a shampoo will have its common sku number but at the same time it can have multiple ean code/bar codes.
eg 2: mobile phones with common sku number can have IMEI and other codes .
regards,
deepak -
ABAP QUERY Report : column number change
Hi friends,
I need to modify the existing ABAP QUERY REPORT.
I have added a new field in the selection screen.
When I execute the query, it(our new filed) is displaying at the end of the columns.
But I want it to be at 8th columns. please help me.
When I try to change the out position to "8"at "Basic list" -> select check box of our field and double clict it, I am getting the following error.
Warning: Overlapping fields
Those fields overlapped by other fields will not be displayed in their entirety.
So I could not display the new field at 8 th column.
Guys. Please help me.Hi
You have to change the position of each field after 8th column
suppose you added your new field at the 8th column position
then all the subsequent fields positions you have to adjust as per their length
You have to do like this to adjust the columns
see the doc on query
http://help.sap.com/saphelp_46c/helpdata/en/35/26b413afab52b9e10000009b38f974/content.htm
http://www.thespot4sap.com/Articles/SAP_ABAP_Queries_Introduction.asp
Step-by-step guide for creating ABAP query
http://www.sappoint.com/abap/ab4query.pdf
ABAP query is mostly used by functional consultants.
SAP Query
Purpose
The SAP Query application is used to create lists not already contained in the SAP standard system. It has been designed for users with little or no knowledge of the SAP programming language ABAP. SAP Query offers users a broad range of ways to define reporting programs and create different types of reports such as basic lists, statistics, and ranked lists.
Features
SAP Query's range of functions corresponds to the classical reporting functions available in the system. Requirements in this area such as list, statistic, or ranked list creation can be met using queries.
All the data required by users for their lists can be selected from any SAP table created by the customer.
To define a report, you first have to enter individual texts, such as titles, and select the fields and options which determine the report layout. Then you can edit list display in WYSIWYG mode whenever you want using drag and drop and the other toolbox functions available.
ABAP Query, as far as I Believe, is the use of select statements in the ABAP Programming. This needs a knowledge of Open SQL commands like Select,UPdtae, Modify etc. This has to be done only by someone who has a little bit of ABAP experience.
To sum up, SAP queries are readymade programs given by SAP, which the user can use making slight modification like the slection texts, the tables from which the data is to be retrieved and the format in which the data is to be displayed.ABAP queries become imperative when there is no such SAP query existing and also when there is a lot of customizing involved to use a SAP Query directly
use either SQ02 ans SQ01
or SQVI tr code
for more information please go thru this url:
http://www.thespot4sap.com/Articles/SAP_ABAP_Queries_Create_The_Query.asp
http://goldenink.com/abap/sap_query.html
Please check this PDF document (starting page 352) perhaps it will help u.
http://help.sap.com/printdocu/core/Print46c/en/data/pdf/BCSRVQUE/BCSRVQUE.pdf
check the below link will be helpful for u
Tutorial on SQVI
once you create query system generates a report starting with AQZZ/SAPQUERY/ABAGENCY2======= assing this report to tr code for the same
Regards
Anji -
Dear Experts,
in my company, due to a SAP external system process it happens quite often that the same material/serial number should be sold, returned and sold again the same day(within several minutes). The external system isn't able to send (IDoc) the required postings in the right order. All sales are collected in only one IDoc - so we try to post the goods issue twice, before its return gets posted. This is not possible, due to the serial number's status ECUS.
Is there a way how I can define a serial number profile that doesn't change the status at all? or can I define a new status, which has no check function?
Or do you have any other good idea how I can solve this problem? ("do not work with serial numbers" is no option, I already asked that )
Any help is appreciated!
Thanks a lot
Kurt D. HessDear Experts,
in my company, due to a SAP external system process it happens quite often that the same material/serial number should be sold, returned and sold again the same day(within several minutes). The external system isn't able to send (IDoc) the required postings in the right order. All sales are collected in only one IDoc - so we try to post the goods issue twice, before its return gets posted. This is not possible, due to the serial number's status ECUS.
Is there a way how I can define a serial number profile that doesn't change the status at all? or can I define a new status, which has no check function?
Or do you have any other good idea how I can solve this problem? ("do not work with serial numbers" is no option, I already asked that )
Any help is appreciated!
Thanks a lot
Kurt D. Hess -
PSE 7 Activation query. Serial number is invalid
Trying to activate an old PSE 7 version on a new PC and serial number is coming up as invalid. Can you assist please
Got the exact same response from the tech guy on the chat. It's terrible support in my opinion.
I have the exact same problem as you and they sent me to this forum to resolve it. C'mon Adode!!!
Photoshop Elements 7 works fine on Windows 8.1 as I am running the trial version it just wont accept my serial number which is valid
Maybe you are looking for
-
I have ms sql server instaled on my comp, and i'm using a system account(and for authentification i have windows only chosen), but cannot connect to it using JDBC. My code is: Class.forName("com.microsoft.jdbc.sqlserver.SQLServerDriver"); con = Drive
-
Time Capsule support for multiple XBoxes?
I've read many posts about how to configure Airport Extreme and Time Capsule devices to support XBox Live, but they all focus on configuring network traffic to support a single XBox by forwarding ports to a static or reserved IP address for the XBox.
-
How to make folder view static on shared volume
I have an external drive connected to a Mac Mini (10.6.8). We use that external drive as our shared network drive. 4 Macs and 2 PCs access the drive. Please tell me how I can alter the ".DS_store" file on the SHARED VOLUME so that each user can ex
-
HD Quick Time Component is missing
Hi, if I import video scenes from my Sony HDR-HC3 on my iMac 5.1 it works great but if I want to do the same thing on my MacBook Pro there seems to be a problem. If I connect my camera a warning appears : " HD Quick Time Component is missing " It als
-
I'm not sure if it is because Spotlight was running (or hanging, I'm not sure whether it was actually doing anything or not) (and I had turned my TM disc to the Private setting in Spotlight) or what, but twice now running Time Machine has frozen ever