Need a generic data type to hold any string
Hi,
I m trying to write a program which can log data from any table into a Trace Z table.
I have used
FIELD-SYMBOLS: <line>.
to get the line of that table. But now I want to dynamically know what are the field names of this line structure and the data in it. And then write it as a string to the trace Z table
form log_table_data tables rt_any_table
using rv_statement type string.
data: v_line type string,
v_char_line type char255.
FIELD-SYMBOLS: <line>.
loop at rt_table ASSIGNING <LINE>.
v_char_line = <LINE>. - Terminating at this statement
ASSIGN <LINE> to v_line casting type string.
endloop.
endform.
Thanks for reading
Hi,
if you are interested in generic programming in ABAP then this [presentation|https://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/b332e090-0201-0010-bdbd-b735e96fe0ae] is full of information. There is a class CL_ABAP_STRUCTDESCR with method GET_COMPONENTS. This method returns a list of components of table or structure. So you will be able to loop over every field in the table and convert each field into string.
Cheers
Similar Messages
-
What is "g" data type? Is it STRING?
Hi Experts,
Simple and basic doubt,.....
What is "g" data type? Is it STRING?
Like these, when I get in future for others, Where Can I see them, I tried in SE11, and F4, but did not figure it out!!
thanqthanq
my other thread:
This is production issue.
I have given menu>extras->ONLY ONE serial #s to the item of 10 of quantity 3/material in the out bound delivery.
Then, pressed the PGI. worked fine.
In next, in another case, I created another delivery for the same material, of the qunatity is 3, but different serial #s,-.....assigned 2 different serial #s.
then, am getting DUMP.
from ST22 the Dump is,
In the FM of CHECK_STRING_SUCCESSOR of with in "PROCESS_STRINGS_FOR_PRINT" .
The reason for the exception is:
You attempted to pass the field "I_SPECIAL_CHARS" to the formal parameter
"I_SPECIAL_CHARS"
but the formal parameter "I_SPECIAL_CHARS" can accept only fields of
type "C". The field "I_SPECIAL_CHARS" has the type "g".
So, let me know that,
1 - Why its happening ONLY when assigned more than 1 serail #, How to fix it?
2 - Is there any SAP NOTE?? -
Getting Data Types of Eloqua - any REST BULK API?
Is there an api which lists all the data types used for the fields of eloqua entities?
From the examples that list the entity metadata I could see that there are data types like "YESNO", "Date" and "string" for entiy's fields.
I will need a list of all data types that eloqua can have for any of its fields.
I am going to be using the BULK API to import and export eloqua elements through java.There is currently no endpoint for this.
There are four data types available for contacts and accounts - Date, Large Text, Numeric (float), Text. Custom objects can these four data types plus a fifth - Number (integer). -
Hi :
I am developing a applicaition in apex i have a reqirement like this i have created a check box, Check box will normally have check and uncheck values which is like 0 and 1
now i need to create a table to hold these values if i check it must hold 1 if i uncheck it must hold 0 to the data base
how to design a table with suitable data type to this please suggest
Please give me both create table and how to insert into table also
:p16_check is the check box item
I tryed like this but this didnt work to me
Create table Check // Createa table syntax
Board Number(2)
Insert into Check (Board) values (:p16_check) // Insert table Syntax
Thanks
SudhirThis is really an Apex question for the Oracle Application Express (APEX).
There's nothing wrong with storing 0, 1 in your NUMBER(2) column (a NUMBER(1) would do). In the Apex form you need to define the properties of the checkbox to say what values represent checked and not checked (by default I think it is Y and N, which won't work with your number).
Regards Nigel -
Need to determine data type of free characteristic in multiprovider
Hi,
I need to determine the data type (e.g. numeric vs alpha numberic) of a free characteristic in a multiprovider. Can this be accomplished in BEx Query Designer?
If not, can it be accomplished in RSA1? How?
Thanks,
Kevinits not possible via Query designer..
give that object name if it is infoobject then you can get via RSD1 -
Need Help with data type conversion
Hello People,
I am new to java, i need some help with data type conversion:
I have variable(string) storing IP Address
IPAddr="10.10.103.10"
I have to call a library function which passes IP Address and does something and returns me a value.
The problem I have is that external function call in this library excepts IP Address in form of a byte array.
Here is the syntax for the function I am calling through my program
int createDevice (byte[] ipAddress).
now my problem is I don't know how to convert the string IPAddr variable into a byte[] ipAddress to pass it through method.Class InetAddress has a method
byte[] getAddress() You can create an instance using the static method getByName() providing the IP address string as argument. -
Need to know data type which could take the result of - data TYPE RAW.
Hello,
I have the following Req:
I need to make a RFC call from one SAP system to SAP Banking Services system to retrieve Contract ID.
But the field contract id happens to be of TYPE RAW. (16 characters)
So my problem is - I need to know the data type could take the result (contract id) of that RFC call.
As the declration -> data: v_con_id Type RAW --> isn't a valid syntax.
Please help in this regard.
Thanks
AnoopHi
Check this link for RAW data type
http://help.sap.com/saphelp_46c/helpdata/en/9d/ab1b0f055b11d2806500c04fadbaa1/content.htm
As you have mentioned about the declration ->
data: v_con_id Type RAW --> isn't a valid syntax.
lets try another one assign a variable to RAW data TYPE and inturn assign v_con_id to that variable.
var_raw(16) type RAW,
v_con_id type var_raw(16).
I am though not sure just try out
Revert for clarification
Thanks and Regards
Srikanth.P -
I need to read data from MQ? any example of OFSML ?
I need to read data from MQ so what I should know about this MQ properties ?? such ip,name,....
I'm new in MQ programming
and it can be over internet or local network only ?
I will used the OFSML
any one know any thing about OFSML or any example ?? Open Financial Services XML interface
(http://dts.temenos.com/ofsml/)It's not possible to read from a file without using classes from the core API*. You'll have to get clarification from your instructor as to which classes are and are not allowed.
[http://java.sun.com/docs/books/tutorial/essential/io/]
*Unless you write a bunch of JNI code to replicate what the java.io classes are doing. -
Advice needed for using date type in leave quota generation.
Requirement: Seniority for quota generation of long service leave must be based on date "02" in IT0041.
Although all the relevant config has been done using the date type 02, the quota is still being generated based on date type 01.
My Question: What is required to make this scenario work?
Thanks
Maureen.Validity/Deduction
Validity: Valid From = Date type 02 -1Days; Valid To = Date Type 02 999Months
Deduction: From = Start of Val +1Day, To = End of Val +999 Months
Base Entitlement:
Rule: 002
Sequence 001; Seniority = 0 - 5 years; Constant= 5 days; Related to = Accrual period
Sequence 002; Seniority = 5 - 999 years; Constant=10 days; Related to = Accrual period
Selection Rules:
Applicability: default values
Accrual Period: Rel to date type = 02; Length = 60 Months
Base Entitlement: Rule = 002; Key for seniority = For exact day
Accrual Entitlement: No pro-rata calc
Transfer time: Upon accrual
All fields not mentioned are standard defaults.
Employee:
IT0041
Date Type 01 = 01/09/2005
Date Type 02 = 06/04/1995
IT0000
Current position: Begda: 01/02/2009 - 31/12/9999
Previous position: Begda: 01/03/2008 = 31/01/2009
Testing by running Time Evaluation till 31/09/2012
Result:
5 days accrued on 05/04/2010
IT2006: Deduction from = 06/04/2009 To 31/12/9999; Validity from = 05/04/2009 To 31/12/9999
Please note I've used different dates in an attempt to clearly illustrate the problem. Hope it doesn't serve to confuse.
Thanks for the help. -
How to convert a dynamic data type to array of strings
I want to perform a serial communication between two
computers that I´ll call them A and B. The computer A (transmitter)
will send a signal (sinusoidal) to computer B (receiver). I´m using a
VISA Serial Communications Set (VISA Configure Serial Port.vi, VISA
Write.vi, VISA Read.vi and VISA Close.vi). VISA Write accepts
only string data type and VISA Read reads only string data type, but
the signal that I generated (on transmitter) is dynamic data and I need
to perform this conversion to run my program sucessfully. How can I
perform this conversion?!Hi Rafael,
You can configure the From DDT Express VI to convert your dynamic data to any number of different types. By default, the Express VI will convert to a 1D array of numerics...however, you can configure it (either when you first drop it, or by double-clicking it) to convert to a 2D array of numerics...additionally, you can configure it to convert based on channel data being in columns or rows. I have attached another screenshot that shows converting the dynamic data into a 2D numeric array.
I hope this helps.
-D
Darren Nattinger, CLA
LabVIEW Artisan and Nugget Penman
Attachments:
FromDDT2D.jpg 164 KB -
What is the best data type to store XML string
Hello all,
If we want to store a XML string in oracle database table for some other program use what is the best data type that we can use in the table to store this XML string..
Is it VARCHAR? or can we use BLOB type
Anybody to help please
Message was edited by:
user483578If your XML data will not be larger than 4000 characters then use VARCHAR2 else CLOB. I don't see a need to use BLOB (unless your XML data contains binary information).
-
LinkedList<Integer> i=new LinkedList();
How is it compile properly ?Mrjavan wrote:
No everything is run properly.Yes, but the compiler gives you a warning about the third line:
$ javac Foo.java
Note: Foo.java uses unchecked or unsafe operations.
Note: Recompile with -Xlint:unchecked for details.
$ javac -Xlint:unchecked Foo.java
Foo.java:8: warning: [unchecked] unchecked conversion
found : java.util.HashMap
required: java.util.HashMap<java.lang.Integer,java.lang.String>
HashMap<Integer,String>hmap3=new HashMap();
^
1 warning
$To summarize:
In the first line, you declare the full parameterized type in the instanciation, but discard it because your variable only has the raw type. So you're doing useless work.
In the second line you declare the full parameterized type in both the variable declaration and the instanciation. That's the correct way. Now the compiler can check access to hmap2 for type correctness.
In the third line you declare the full parameterized type in the variable declaration, but use a raw type for the instanciation. Here the compiler gives you a warning that it can't check the assignment at runtime. Don't do that.
Note that at runtime all 3 will behave exactly the same, because of type erasure (google that term). -
Can "SPML Web Service Complex Data Type field" take multiple values ?
In Generic Technology Connector's -SPML design parameters section, Can we give multiple values in SPML Web Service Complex Data Type field?
If not, how can i call methods directly instead of calling them through a values of the "name" attribute of the "complexType" element in SPML Web Service Complex Data Type?
I need 'SPML Web Service Complex Data Type' to hold multiple values.And based on the request it has to initiate appropriate method of action.
Presently i have three methods add,modify and delete which i am calling through a single value of the "name" attribute of the "complexType" element in SPML Web Service Complex Data Type.
I want to replace this single value with multiple menthods , so that a direct interaction between the method,OIM and target can be established.
Edited by: 821054 on 16/02/2011 04:23Thanks Robert.
You'll need to create your own interface to the webapp database for those kind of data operations
by this, are you speaking of the internal BC database which stores web app schema data? That would be great if it were possible to update that programmatically because I need to use the List (Checkbox List) field type (for the search functionality), but I need to supply the checkbox options from a web app rather than by manually updating the list entered in the Fields view of the web app settings (shown below).
I'm curious if anyone else has tried this?
Again, my reason for needing to use the List (Checkbox List) field type is that the page which processes searches knows to expect a comma separated list for this field type and then appears to be parsing out the individual values for searching out web app items with 1 or more matching values. You're right that text fields (string and multiline) just check for 'string contains' matches, and this would be ok if I was only ever needing to search just one value at a time. Here's an example of what I might do:
Web App item field value (as recorded against the List (Checkbox List) field type:
8294877,8294878
Web App Search value (for this same field):
8294879,8294877,8294885
The search would return this web app item because the field contains 2 (1 or more) individual values even though they were entered into the search field in a different order. If this web app item were just a Text (string or multiline) field, the searched value is not a substring of the web app item's stored value, so it would not find a match. Hence the need to use Checkbox List field type.
The web app will have thousands if not 10s of thousands of records, so dumping them all into one big array or object and searching on the front-end won't be practical (though it works great on smaller datasets). -
Hello,
I've posted a project at some commercial sites to find someone to help me doing it, but couldn't find any. I thought that it might be impossible doing this type of projects. The following is what was posted expecting someone could help/lead me doing it myself or at least providing any valuable hints, Thank you in advance.
Looking for an Oracle expert to do the software part of a project.
A data to be populated in Oracle database, but unfortunately Oracle doesn't support the required data type to hold it.
An expert has to create custom data type with all required procedures/functions to manipulate the data(Read/Update/Insert/Delete), and provide a method to incorporate the solution in Oracle developer suite to model it.(To use it inside designer tools)
The solution should allow someone to Create a column in a table to hold (for example) three bits in every row(record), mostly used in the project is three bits, but need the solution to be open and customizable to any number from one up to 21. Viewing/entering the data in a record could be as binary string. Saving in a table physically should be in sampling way to save space.
The functions/procedures for manipulating the data should be based on record level and block level(several records of one column with start/end points). For record manipulations a binary string should be used, and for block manipulations a sampled structure should be used.
Thank you for your time.
Platforms:
Oracle Database 9i and above.
Oracle Developer Suite 9i and above.
*/not sure what exactly do you mean by custom data type in SQL? if you mean if there is a user defined data type in oracle thru PL/SQL yes there is. by using the %Type you need not to declare the variable data type explicitly. all you need to do is associate the variable to the column name of the table and use the %Type. see this example below.
SQL> declare
2 vEmpno emp.empno%Type;
3 begin
4 select empno
5 into vEmpno
6 from emp
7 where ename = 'FORD';
8 dbms_output.put_line('employee no: '||vEmpno);
9 end;
10 /
employee no: 7902
PL/SQL procedure successfully completed
SQL> or if you are looking for a collection of data types see this link about OBJECT TYPES -
I am using this code:
DROP TABLE "SYSTEM"."DATE_TBL";
CREATE TABLE "SYSTEM"."DATE_TBL"
"JEDAN" DATE,
"DVA" VARCHAR2(50 BYTE),
"TRI" VARCHAR2(50 BYTE)
TRUNCATE TABLE date_tbl;
ALTER SESSION SET NLS_DATE_FORMAT="DD-MM-YYYY HH24:MI:SS";
DECLARE
CURSOR c1 IS
SELECT * FROM LDAP_DATA;
event_rec c1%ROWTYPE;
BEGIN
OPEN c1;
LOOP
FETCH c1 INTO EVENT_REC;
EXIT WHEN (c1%NOTFOUND);
INSERT INTO DATE_TBL VALUES (
to_date( event_rec.eventtime, 'mm/dd/yyyy HH12:mi:ss PM' ),
event_rec.sourceIP,
event_rec.sourceport);
END LOOP;
CLOSE c1;
END;
select * from date_tbl
when I do the last SELECT order I get this in SQL Developer:
JEDAN DVA TRI
26-04-0010 16:02:38 127.0.0.1 46132
And that is the result I want do get.
BUT, when I export table I get this result:
JEDAN DVA TRI
26.04.10 16:02:38,000000000 127.0.0.1 46132
How can I remove these nine zeros in column JEDAN (type DATE)?Hi,
fibonacci wrote:
The thing is that I want to have column with DATE type that holds dates.
I want to do export in CSV format, but I have nine zeros. I do this - right click on the table -> export -> csv
Is there any other way to export data from table in CSV format where I could use your suggestion?Is this some SQL Developer utility you're using?
It sounds like it automatically applies a standard format to all DATEs, but the same format is designed to handle TIMESTAMPs (which can include fractions of a second) as well.
There's probably a way to tell SQL Developer to use the format you want, 'DD.MM.YY HH24:MI:SS', as its default format, but I don't know what that is. Try posting a question in the SQL Developer forum:
SQL Developer
A work-around is to convert the DATE to a string, using TO_CHAR. I'm sure the tool won't try to re-format strings. You may need to create a view that has the formatted VARCHAR2 in place of the DATE. (Do NOT actually change the table to make the column a VARCHAR2; I mean use a query or a view to produce a VARCHAR2 column where your real table has a DATE.)
How can I create my own scheme? I have Oracle XE 10g and I am using SQL DeveloperLog in as SYSTEM. Use the CREATE USER command to make a new user, and the GRANT command to give it some basic privileges.
For example:
CREATE USER fibonacci
IDENTIFIED BY leonardo
DEFAULT TABLESPACE users
GRANT CONNECT, RESOURCE TO fibonacci;After that, log in as FIBONACCI (password LEONARDO) to create tables, and do most anything else.
The only time you should connect as SYSTEM is to to things like the commands above.
Maybe you are looking for
-
How do you write sideways in Pages?????
How do you write sideways in pages w/ the page upright?
-
PDF Output Settings for Word Email Merge?
Hi all, I'm using Acrobat X's integration in Word to do an email merge of PDFs. There are images in my template that need their quality maintained. So far, I've been unable to find a setting that affects the "Merge to Adobe PDF" script. I've created
-
How to avoid "unchecked cast" warnings
Hi all, here is my code: private Vector<String> vector1; private Vector<String> vector2=new Vector<String>(); vector1=(Vector<String>)vector2.clone(); ...How can i avoid "unchecked cast" warnings, while compiling with "-Xlint:unchecked" option.
-
Changing the catalog profile when creating a QN FROM ACTION BOX in transaction QM02
Hi All, When I create a quality notification from the action box in transaction QM02, the catalog profile is fetched from the material master. I want this changed so that the catalog profile is always copied from the QN being preocessed in QM02. (cur
-
I'm considering purchasing a iPad (I currently have a iPhone4s and love it) A huge part of work deals with editing pdfs, from what I can tell this will not work on the iPad. Does anyone know if this is correct?