Data Sourse - Invalied Table Name in UDO'S
hi,
in my code, i am using udo's.i created an udo with only one master table. the udo is assigned to SRF file. when retriving data from the table it showing Error "Data Sourse - Invalied Table Name"
my code to fill the matrix is
xoConditions = New SAPbouiCOM.Conditions
xoCondition = xoConditions.Add
xoCondition.BracketOpenNum = 1
xoCondition.Alias = "U_RStatus"
xoCondition.Operation = SAPbouiCOM.BoConditionOperation.co_EQUAL
xoCondition.CondVal = "Y"
xoCondition.BracketCloseNum = 1
DBDS("@" & enAddOnTableName.cst_NhclRoundoff).Query()
For i = 0 To DBDS("@" & enAddOnTableName.cst_NhclRoundoff).Size - 1
Me.FormMatrix(enControlName.cst_Matrix).AddRow()
DBDS("@" & enAddOnTableName.cst_NhclRoundoff).Offset = i
Next i
Edited by: Nageswar Venkat on Aug 7, 2008 12:56 PM
Nageswar,
Try to put a message box and see what the name of the table is coming up.. as u have specified "@" in ur code.. if the table name comming up already has an @, then it will be an invalid table rite..?
Regards,
Vasu Natari.
Similar Messages
-
Data source - Invalid table name [66000-7]
Hi,
I created UDO with master table and child table and when I tried to execute on it a dbdatasource query I got this error Data source - Invalid table name [66000-7]. When I tried this query on system table it works perfectly, so I don't know where is the problem (it looks like DBDataSources.Query doesn't work on user tables).
My code:
oDBDataSources = oForm.DataSources.DBDataSources.Add("@MyTable");
oConditions = (SAPbouiCOM.Conditions)(SBO_Application.CreateObject(BoCreatableObjectType.cot_Conditions));
oMatrix = (SAPbouiCOM.Matrix)(oForm.Items.Item("mtx_dzial").Specific);
oCondition = oConditions.Add();
oCondition.BracketOpenNum = 1;
oCondition.Alias = "U_MyDate";
oCondition.Operation = BoConditionOperation.co_BETWEEN;
oCondition.CondVal = "2008/10/01";
oCondition.CondVal = "2008/10/06";
oCondition.BracketCloseNum = 1;
oDBDataSources.Query(oConditions);
Regards
ElaHi
Look here the working example...
Hope it can help you.
Public Sub SBO_CreateForm()
Dim oForm As SAPbouiCOM.Form
Try
Dim sUniqueID As String = "O99_" & Microsoft.VisualBasic.Format(Now.Millisecond, "0000")
Dim sFormXmlFile As String = "MY_FORM_FILE.xml"
' Search for this function on this forum...
Call ReplaceUIDandLoadToB1(sFormXmlFile, sUniqueID)
oForm = SBO_Application.Forms.Item(sUniqueID)
Call Matrix_SetConditions(oForm)
oForm.Visible = True
Catch ex As Exception
If Not oForm Is Nothing Then
oForm.Close()
oForm = Nothing
End If
Finally
System.GC.Collect() 'Release the handle to the table
End Try
End Sub
Private Sub Matrix_SetConditions(ByRef oForm As SAPbouiCOM.Form)
Dim oMatrix As SAPbouiCOM.Matrix
Dim oConditions As SAPbouiCOM.Conditions
Dim oCondition As SAPbouiCOM.Condition
Try
oMatrix = oForm.Items.Item("mtx00").Specific
If oMatrix Is Nothing Then Throw New Exception("ERROR!...")
oConditions = SBO_Application.CreateObject(BoCreatableObjectType.cot_Conditions)
' ++++++++++++++++++++++++++++++++++++++++++++
If Not sItem1.Equals("") And Not sItem2.Equals("") Then
'// AND (P.U_CodItem BETWEEN '" & s1.Trim & "' AND '" & s2.Trim & "')"
oCondition = oConditions.Add
oCondition.BracketOpenNum = 1
oCondition.Alias = "U_CodItem"
oCondition.Operation = co_BETWEEN
oCondition.CondVal = sItem1
oCondition.CondEndVal = sItem2
oCondition.BracketCloseNum = 1
Else
If Not sItem1.Equals("") Then
'// AND P.U_CodItem = '" & s1.Trim & "'"
oCondition = oConditions.Add
oCondition.Alias = "U_CodItem"
oCondition.Operation = co_EQUAL
oCondition.CondVal = sItem1.Trim
End If
If Not sItem2.Equals("") Then
'// AND P.U_CodItem = '" & s1.Trim & "'"
oCondition = oConditions.Add
oCondition.Alias = "U_CodItem"
oCondition.Operation = co_EQUAL
oCondition.CondVal = sItem2.Trim
End If
End If
' other conditions ....
'// Execute the query with the conditions collection
oForm.DataSources.DBDataSources.Item("@O99_MY_TABLE_NAME_HERE").Query(oConditions)
oMatrix.LoadFromDataSource()
oMatrix.SelectionMode = BoMatrixSelect.ms_Single
Catch ex As Exception
' log exception here
Finally
If Not oConditions Is Nothing Then If oConditions.Count > 0 Then glo_Conditions = oConditions
System.GC.Collect()
End Try
End Sub
In the xml file of my form I have added dbdatasource:
<datasources>
<dbdatasources>
<action type="add">
<datasource tablename="@O99_MY_TABLE_NAME_HERE"/>
</action>
</dbdatasources> -
Purchase Order released date field and table name
Hi,
Please tell me the Purchase Order released date field and table name.
Regards
DeepakHi,
Table : EKKO.
Fields : FRGKE,FRGZU.
You can get release date of PO from CDHDR table.
give object value as your po number and check.dont forget to give leading zeros.
The udate will be date field and transaction will be me29n for relaesed po. -
Hi Expert,
I am developing FI Voucher, in this voucher, I will be print vendor invoice created through FB60, I want to print due date on voucher which is stored in document but i can't get field name and table name for due date. Please tell me in which sap standard table, due date is stored.
Thanks in Advance......
Regards,
Prasann Limkar
SAP FI Certified ConsultantHi Prasann,
You go to table name BSIK/BSEG
Pass Company Code, Document number, Fiscal Year & Account type = K (Vendor)
Find out the below
1. Base line date (On the day start for calculation)
2. Day1(Number day's will not consider as due as far as payment terms is concerned)
(If you want you can take Payment terms also)
Example.
Base line date is 29.03.2014
Day1 is 30 day's
(Till 30 day's it will not go for Due)
Due will be start on 28.04.2012
If you add 38 day's it is today date 05.06.2014
Number of Arrears are 38
In the logic for base line date you have to add Day1 no. day's then next day's on-wards to till date is overdue date.
Ravi Polampalli -
Import Data using Full Table Name
Is there a way to run the import data wizard so when pulling data from a csv it generates an insert statement not only using the table name but using the Oracle Schema name -- ie fully qualified table name?
Hi Nilanjan,
I need help ASAP.
About this dump-load task, how does it works? Because I was checking out a package called Import SQL and this one only imports data from a table, however this table has to be allocated within the database that is being used, and I right? Are these 2 related somehow?
Does this task order BPC to find data from a SQL Table (allocated in a different server, different instance for SQL) and import it to SQL Fac2 table?
Can you help me with a simple explanation what do I need to do to run this task? The page help.sap.com talks shows a section within DumpLoad Task Usage which is called Importing Into SQL Server...
* Processing the Application using DumpLoad -
Importing into SQL
You can use DumpLoad to process the application as a standalone procedure, or with data import, export, or clear.
Prerequisites
The DumpLoad task (OsoftTaskDumpLoad2008.dll) is registered with Microsoft SSIS. See Registering Custom Tasks.
Procedure
1.Open a package or create a new package in Microsoft SSIS on the Planning and Consolidation server. i already did this for the DumpLoad task ... should I do this for the Import SQL task also ?
2.Select the task and add it to the package. WHAT DOES SELECT THE TASK MEAN?
3.Open the task, and choose Data Management None .
4.Enter the application set, application, and user ID.
Im getting confused, can you please provide more details about the whole procedure. Thanx in advance
Velázquez -
ShLife Exp.Date Refer the table name
Hi,
i have Billing Document Against some data fetch .VFDAT-ShLife Exp.Date Field where is the table refer.
Easy Table Advise me.
Regards,
JJHi JJ
Check the MDKP , MDTB Tables to retrieve your required data
Regards
Srinath -
REgd How to find appropriate data sourses for given tables in Inve Mngt
Experts!
M completely new to Inventory Mngt where i needto extract data from R/3,
they 've given me some tables, but i dont know how to find appropriate data
sourses for that tables
those are
MKPF,MSEG
EKKO,EKPO
EKBE,EKET
How to find right data sourses when table names given in any module??
pls guide me,
'll assign the points.
thanks
SrujanHi,
2LIS_03_BX is the initialization of your stocks; you'll need to perform the setup procedure for extracting this data.
Usually this DSource is used to bring the stocks positions at a given time; from this given time you'll then extract deltas from BF and UM so your stocks are always:
BX + BF(Delta) + UM(delta).
Hope this clears your doubts...
Olivier. -
How to fetch the data from databse table and get the required output
Hi,
I have made a project that connects CEP to database table but i m getting some problem in fetching the data from database.
From the following code :
If the where condition is removed then the application runs fine but i am still not able to fetch the data from the table because it is not showing any output.
Can anyone please suggest me that how to write WHERE statement correctly and how i will be able to see the output.
Following is the config.xml for processor:
======================================
<?xml version="1.0" encoding="UTF-8"?>
<wlevs:config xmlns:wlevs="http://www.bea.com/ns/wlevs/config/application"
xmlns:jdbc="http://www.oracle.com/ns/ocep/config/jdbc">
<processor>
<name>JDBC_Processor</name>
<rules>
<query id="q1"><![CDATA[
SELECT STOCK.SYMBOL as symbol, STOCK.EXCHANGE as exchange
FROM ExchangeStream [Now] as datastream, STOCK
WHERE datastream.SYMBOL = datastream.SYMBOL ]]></query>
</rules>
</processor>
<jms-adapter>
<name>JMS_IN_Adapter</name>
<jndi-provider-url>t3://CHDSEZ135400D:7001</jndi-provider-url>
<destination-jndi-name>jms.TestKanikaQueue</destination-jndi-name>
<user>weblogic</user>
<password>welcome1</password>
</jms-adapter>
</wlevs:config>
Following is the assembly file:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:osgi="http://www.springframework.org/schema/osgi"
xmlns:wlevs="http://www.bea.com/ns/wlevs/spring" xmlns:jdbc="http://www.oracle.com/ns/ocep/jdbc"
xmlns:spatial="http://www.oracle.com/ns/ocep/spatial"
xsi:schemaLocation="
http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans.xsd
http://www.springframework.org/schema/osgi
http://www.springframework.org/schema/osgi/spring-osgi.xsd
http://www.bea.com/ns/wlevs/spring
http://www.bea.com/ns/wlevs/spring/spring-wlevs-v11_1_1_3.xsd
http://www.oracle.com/ns/ocep/jdbc
http://www.oracle.com/ns/ocep/jdbc/ocep-jdbc.xsd
http://www.oracle.com/ns/ocep/spatial
http://www.oracle.com/ns/ocep/spatial/ocep-spatial.xsd">
<wlevs:event-type-repository>
<wlevs:event-type type-name="StockEvent">
<wlevs:properties>
<wlevs:property name="SYMBOL" type="byte[]" length="16" />
<wlevs:property name="EXCHANGE" type="byte[]" length="16" />
</wlevs:properties>
</wlevs:event-type>
<wlevs:event-type type-name="ExchangeEvent">
<wlevs:class>com.bea.wlevs.event.example.JDBC_CEP.ExchangeEvent</wlevs:class>
</wlevs:event-type>
<wlevs:event-type type-name="StockExchangeEvent">
<wlevs:properties>
<wlevs:property name="symbol" type="byte[]" length="16" />
<wlevs:property name="price" type="byte[]" length="16" />
<wlevs:property name="exchange" type="byte[]" length="16" />
</wlevs:properties>
</wlevs:event-type>
</wlevs:event-type-repository>
<bean id="readConverter" class="com.bea.wlevs.adapter.example.JDBC_CEP.Adapter_JDBC" />
<bean id="outputJDBCBean" class="com.bea.wlevs.bean.example.JDBC_CEP.OutputBean_JDBC">
</bean>
<wlevs:adapter id="JMS_IN_Adapter" provider="jms-inbound">
<wlevs:listener ref="ExchangeStream" />
<wlevs:instance-property name="converterBean"
ref="readConverter" />
</wlevs:adapter>
<wlevs:processor id="JDBC_Processor" advertise="true">
<wlevs:listener ref="OutputChannel" />
<wlevs:table-source ref="STOCK" />
</wlevs:processor>
<wlevs:channel id="ExchangeStream" event-type="ExchangeEvent" advertise="true">
<wlevs:listener ref="JDBC_Processor" />
</wlevs:channel>
<wlevs:channel id="OutputChannel" event-type="StockExchangeEvent"
advertise="true">
<wlevs:listener ref="outputJDBCBean" />
</wlevs:channel>
<wlevs:table id="STOCK" event-type="StockEvent"
data-source="StockDs" table-name="STOCK" />
<wlevs:table id="STOCK_EXCHANGE" event-type="StockExchangeEvent"
data-source="StockDs" table-name="STOCK_EXCHANGE" />
</beans>
ExchangeEvent.java:
package com.bea.wlevs.event.example.JDBC_CEP;
public class ExchangeEvent {
public String SYMBOL;
public String symbol;
public String exchange;
public ExchangeEvent() {
public String getSYMBOL() {
return SYMBOL;
public void setSYMBOL(String sYMBOL) {
SYMBOL = sYMBOL;
public String getSymbol() {
return symbol;
public void setSymbol(String symbol) {
this.symbol = symbol;
public String getExchange() {
return exchange;
public void setExchange(String price) {
this.exchange = price;
Adapter Class:
package com.bea.wlevs.adapter.example.JDBC_CEP;
import com.bea.wlevs.adapter.example.JDBC_CEP.MyLogger;
import com.bea.wlevs.adapters.jms.api.InboundMessageConverter;
import java.text.DateFormat;
import java.util.Date;
import com.bea.wlevs.adapters.jms.api.MessageConverterException;
import com.bea.wlevs.event.example.JDBC_CEP.ExchangeEvent;
import javax.jms.JMSException;
import javax.jms.Message;
import javax.jms.TextMessage;
import java.util.ArrayList;
import java.util.List;
import java.util.Random;
public class Adapter_JDBC implements InboundMessageConverter{
@SuppressWarnings("unchecked")
public List convert(Message message) throws MessageConverterException, JMSException {
Random rand = new Random();
int unique_id = rand.nextInt();
DateFormat dateFormat;
dateFormat = DateFormat.getTimeInstance();
dateFormat.format(new Date());
MyLogger.info(unique_id + " CEP Start Time is: " + dateFormat.format(new Date()));
System.out.println("Message from the Queue is :"+ message);
TextMessage textMessage = (TextMessage) message;
String stringMessage = textMessage.getText().toString();
System.out.println("Message after getting converted into String is :"+ stringMessage);
String[] results = stringMessage.split(",\\s*"); // split on commas
ExchangeEvent event1 = new ExchangeEvent();
event1.setSYMBOL(results[0]);
List events = new ArrayList(2);
events.add(event1);
return events;
Output Bean Class :
package com.bea.wlevs.bean.example.JDBC_CEP;
import com.bea.wlevs.ede.api.StreamSink;
import com.bea.wlevs.event.example.JDBC_CEP.ExchangeEvent;
import com.bea.core.datasource.DataSourceService;
public class OutputBean_JDBC implements StreamSink{
public void onInsertEvent(Object event) {
if (event instanceof ExchangeEvent) {
ExchangeEvent cacheEvent = (ExchangeEvent) event;
System.out.println("Symbol is: " + cacheEvent.getSymbol());
System.out.println("Exchange is: " + cacheEvent.getExchange());
System.out.println(DataSourceService.class.getClass());
Kindly let me know if you need further info.Do you have StockDs configured in your server config.xml?
I think the query should look more like this:
SELECT stocks.SYMBOL, stocks.EXCHANGE
FROM STOCK as stocks, ExchangeStream [Now] as datastream WHERE stocks.SYMBOL = datastream.SYMBOL
Thanks
andy -
I was writing a program to move data from an Access database on to a different database.
The existing access data base has table names with spaces and SQL queries do not recognize such names! Any suggestions?i think single quotes ' is the generally accepted way
of doing this. [] may work in access but other
databases not so well.Not at all!
Single quotes are used to identify string literals inside a SQL statement. The double quotes are used to quote object names which either contain special characters (e.g. spaces) or would otherwise be rejected because they are reserved words (e.g. using SELECT as a column name only works with double quotes).
Thomas -
Using sql query as a table name
hello,
I have a table(say table1) which is storing the names of some other tables. I want to access the name of a table from table1 using sql query and then use the result of this query as the table name to access the data from
retrieved table name. How can I do this ?
ex:
select * from (select tablename from table1 where tableid='1');
I want to do something likw this. How can I do this?I want to access the name of a table from table1 using sql query and then use the result of this query as the table name to access the data from retrieved table name. How can I do this ?e.g. like this:
SQL> with table1 as (
select 'emp' tablename from dual
select extractvalue(x.column_value, 'ROW/ENAME') ename
from table1, xmltable('ROWSET/ROW' passing dbms_xmlgen.getxmltype('select * from ' || tablename)) x
ENAME
SMITH
ALLEN
WARD
JONES
MARTIN
BLAKE
CLARK
SCOTT
KING
TURNER
ADAMS
JAMES
FORD
MILLER
14 rows selected. -
How to import legacy data into apex tables
Hi All,
Please tell me How to import legacy data into apex tables.
Thanks&Regards,
RaghuSQL WorkshopUtilitiesData Workshop...
you can import the data from already exported as (text/csv/xml) data
Note: the table name and column name should be equal if the table already Existing table. -
2005 PL07 User define table name size changed?
Hi everyone,
I just upgrade Add-on from SBO 2004 to SBO 2005 PL07, there is a problem, when a DBDatasource bind to an User difine table, if the UDT name length <=7, the code runs good under, but under 2005 PL07, when UDT name Length >7, an error "Data source - Invalid table name" shows when code runs to the statement "oDBDataSource.Query(oConditions)".
who knows what's the reason of this problem, is this by the UDT name longer than SBO 2005 PL07 SDK constraint or other reasons.
Thanks in advance!
KathyHi Kathy,
I haven't experienced this error, but it looks like Barend has. I am not sure if he has solved his problem, but it seems to be the same. His table name is also longer than 7 characters. Look at this post posted a couple of days ago:
SBO 2005 DBDatasource
Hope it helps,
Adele -
Can't see data in data tab when there is a "." in table name
Hi,
I have a problem with SQL Developer 2.1 (this works with 1.5).
When there is a dot (".") in table name, we can't see data in data tab (we have no synonyms so it's not same bug).
If I try to export data on same table, in "WHERE" tab, I can see sample !
Any idea ?
Thankslogged
Bug 9393866 - datatb shows no columns for table name containg [dot]
-Raghu -
How-To Find the R/3 Table Name for a BW Data Source
Hi there,
Please advice how can I find the respective table name in R/3 for a particular BW DataSource ?
P/S : I would like a technical how-to instead of referring the table names at HELP.SAP.COM
For instance, for my Standard Business Content Info Cube 0CCA_C03(CO-OM-CCA: Statistical Key Figures) which extracts from BW Data Source: 0CO_OM_CCA_4
My question is, how can I find out which specific tables in SAP R/3 is this Data Source pulling the data from ?Hi Dinesh,
Data Source: 0CO_OM_CCA_4
1) In my R/3, I ran SE16 : Table -> ROOSOURCE
2) OLTPSOURCE -> 0CO_OM_CCA_4
3) EXMETHOD = F1
(Hence, I assume the Extraction Method is a Function Module)
4) So, Function Module = BWOM_RS_GET_CTRSTA
5) Run SE37 in R/3
How do I find out the specific tables in this Function Module ?
Would you please list them for me, so I can further refer to the individual tables ? -
Hi
I like to know the table name for the field Delivery dateHi Mahesh,
The table is: LIKP (SD Document: Delivery Header Data)
Delivery Date Field : LFDAT
Hope this helps you.
Regards,
Chandra Sekhar
Maybe you are looking for
-
Can you create a digital negative from a digital positive in Aperture?
Hi everyone, I'm wanting to make some cyanotypes and have converted images to B&W, but need to covert these to digital negatives so I can have them printed on acetate. Is it possible to create a digital negative in Aperture? Thanks, Andrew
-
RE: printout of P.R.
Hi guru's, My end user requirement is to get a printout of a P.R. with its P.R. No. (there is no problem in getting printout, but he wants with P.R. No. Can anybody please advise. thanks tuljasingh.
-
Stop Cursor moving on Return?
How can I stop the cursor moving when pressing Return on a completed cell in a simple Spreadsheet. I fill a cell up, then press return and the cell below comes alive. How can I stop this from happening as default system or indeed as a system peculiar
-
Float subtraction not working properly
just run the following code the expected answer is 98.720283 but its giving 98.720276 This small is difference is making a lot problem in my program. why is it happening?? isnt it a simple subtraction?? class Test public static void main(String args[
-
How do you access visual voice mail?
I have it, but don't get on screen notifications. I get an annoying email that I should log into my voice mail.