How to get Data from SAP B1 through Journal Entries objects (Excel VBA)
Hi Genius
i had try to login SAB B1 thorugh MS Excel VBA code and it worked well. but i need some questions regards getting the data from after login. that means i want the Posting date, Transaction No, account code, debit and credit amount from Journal entries posted in a particular day through MS excel VBA into excel sheets 1 cell A1:E1
how i get it if any possible ways to do that
here my code to login
Public Sub login()
Sheets("Login").Select 'access the login tab
Worksheets("Login").Range("B1").Activate 'put focus on cell B1 (manager)
B1UserID = Trim(ActiveCell.Value2) 'set Businsss One user
ActiveCell.Offset(1, 0).Activate
B1Password = Trim(ActiveCell.Value2) 'set Business One password
ActiveCell.Offset(1, 0).Activate
sqluser = Trim(ActiveCell.Value2) 'set SQL user
ActiveCell.Offset(1, 0).Activate
sqlpass = Trim(ActiveCell.Value2) 'set SQL password
ActiveCell.Offset(1, 0).Activate
Db = Trim(ActiveCell.Value2) 'set Database name
ActiveCell.Offset(1, 0).Activate
Server = Trim(ActiveCell.Value2) 'set Server name
Set company1 = New SAPbobsCOM.Company 'initialate DI company object
company1.DbServerType = dst_MSSQL2005
company1.Server = Server
company1.DbUserName = sqluser
company1.DbPassword = sqlpass
company1.CompanyDB = Db
company1.UserName = B1UserID
company1.Password = B1Password
'connect to the database
lRetCode = company1.Connect
If lRetCode <> 0 Then
sErrMsg = company1.GetLastErrorDescription
MsgBox (sErrMsg)
Else
MsgBox ("Connected to: " & company1.CompanyName)
End If
End Sub
pls help me
advance thanks to solvers
Gordons way is the easiest - just query the OJDT table for journal entry headers and JDT1 for journal entry lines if needed.
But if you want to work with the business objects:
'Journal entry
Dim oJE As SAPbobsCOM.JournalEntries
Set oJE = company1.GetBusinessObject(oJournalEntries)
oJE.GetByKey(1234)
Dim postingDate as String
postingDate = oJE.DueDate
'etc etc
Similar Messages
-
How to get date from html form through php to show table from oracle sql
I have a form method post.Also an input date like input date (html 5,the one that picks the date from a window below)
I want to take the date the user inputs and use it in a php which contains a contains a select statement that is like that $stid = DBExecute($conn, "select customer_name,product_name,order_date,quantity and ends like this.. and order_date>='".$_POST['date']."'");
Then i have echo "<table....
And while ($row = oci_fetch_array($stid, OCI_ASSOC)) {......
But I have a problem on that. No results shown. Why?
Does anybody know to help me?
What value the date input gives in HTML5 and in which format? How can i fix that?There's not enough info posted to help. Do some googling. Do some debugging - add some 'var_dump' calls in PHP to check everything
e.g. var_dump($_POST);
And never, ever, ever do concatenation like you do with $_POST to build up a query string. This is a major "SQL Injection" security risk.
instead, use an OCI8 bind variable. See PHP: OCI8 - Manual -
How to extract data from SAP in FDM 11121
I came across some documents from version 11113, says there is a SAP adapter, however ,when I check 11121 there's no such adapter, does anyone know how to extract data from SAP in FDM 11121?
I download a package from Bristlecone, but I dont see any xml files in it, just a bunch of dll and I didn't find any instructions on how to set up/configure in FDM, it just explained how to register in SAP app server and client.
Hyperion 11113 has readme on sap adapter(Hyperion Readme Template), but I cannot find the same readme file in 11121, all I can find is ERP Integration Adapter document. any idears where I can find at least a readme document? -
How to get data from a USB-UIRT device using Labview?
How to get data from a USB-UIRT device using Labview?
I'm trying to get data from a USB-UIRT device, is it posible with Labview?
I really appreciate your help,
thanksYou may want to contact the developer of the device for the API and DLL.
http://65.36.202.170/phpBB2/viewforum.php?f=3 -
How to Pull data from sap r/3 tables to oracle tables
how to fetch data from sap r/3 tables & data pulled to oracle table .
GIVE THE APPROPRITE ANSWER FOR THIS.
THANKS IN ADVANCE.
If it is useful for me , i am giving point.
regards ,
Navita
Edited by: NAVITA YADAV on Mar 7, 2008 2:07 PM
Edited by: NAVITA YADAV on Mar 7, 2008 2:08 PMYou need to perform some native SQL to fetch data. Before doing this connection must be exists b/w your R/3 and Oracle server.
Basis team will help you to have connection.
Check the connection name in the table DBCON.
Check the below code to handle native SQL.
SELECT SINGLE DBMS
FROM DBCON
INTO DBTYPE
WHERE CON_NAME = DBS.
IF DBTYPE = 'ORA'.
TRY.
EXEC SQL.
CONNECT TO :dbs
ENDEXEC.
ERROR Handling for Native SQL *************
IF SY-SUBRC <> 0.
MESSAGE `Docusphere connection failed.` TYPE 'I'.
EXIT.
ENDIF.
EXEC SQL PERFORMING loop_output.
OPEN C1 FOR
SELECT UK1, UK7, uk6, uk9, uk22, uk23, uk25 "field names of Oracle table
FROM IIS_DOCS_AP10D
WHERE ( UK2 = 'ZFIINVOICE' OR UK2 = 'ZFIPAYREQ' ) AND
UK19 = 'E' AND
UK20 IS NULL
ENDEXEC.
DO.
CLEAR W_OUTPUT.
EXEC SQL.
FETCH NEXT C1 into :wa1-arc_doc_id, :wa1-bukrs, :wa1-belnr, :wa1-gjahr, :wa1-wi_id, :wa1-ARCH_METHOD, :wa1-barcd.
ENDEXEC.
enddo.
Reward points if helpful................. -
HOW to retrive data from SAP Tabel
Hi Friends,
1)Can you please explain how to retrive data from SAP table(example AFRU).
2) we had requriment based on the qunatity , Product name and date we need to display KPI's .KPI is based no products manfactured per day with some conditions
Regards
SrikanthHi Udayan,
I want to retrive SAP Table data from xMII.can you please explain elabarately how to call "RFC_READ_TABLE" from xMII.
please do the needful
Thanks
Srikanth -
i have three tables A,B,C. there is one to many relation between A and B. and one to many relation existed between table b and c . how will get data from these three tables
check if this helps:
select * --you can always frame your column set
from tableA a
left join tableB b on a.aid=b.aid
left join tableC c on c.bid=b.bid
This is just a general query. However, we can help you a lot more, if you can post the DDL + sample data and required output.
Thanks,
Jay
<If the post was helpful mark as 'Helpful' and if the post answered your query, mark as 'Answered'> -
How to extract data from SAP 4.7 and upload data to SAP ECC 6.0
Hi,
How to extract data from SAP 4.7 and upload data to SAP ECC 6.0? Can i use BDC,BAPI,LSMW? Help me please.hi
good
both works not possible simultaneously.
If you want to do it in two separate task than you can use the GUI_UPLOAD function module to fulfill your requirement.
thanks
mrutyun^ -
How to read data from a file that was formatted by excel?
Hi everyone, I'm familiar with java.io and the ability to read from files, can anyone tell me how to read data from a file that was formatted by excel? Or at least give me some web references so that I can learn about it?
http://jakarta.apache.org/poi/hssf/index.html
HSSF stands for Horrible Spreadsheet Format, but it still works! -
How to get data from Oracle using Native SQL in SAP.. Problem with date
Hi Masters.
I'm trying to get data from an Oracle DB. I was able to connect to Oracle using tcode DBCO. The connetion works fine
I wrote this code and it works fine without the statement of where date > '01-09-2010'
But i need that statement on the select. I read a lot about this issue, but no answer.
My code is (this code is in SAP ECC 6.0)
DATA: BEGIN OF datos OCCURS 0,
id_numeric(10),
component_name(40),
comuna(10),
record_id(10),
status,
sampled_date(10),
END OF datos.
DATA: c TYPE cursor.
EXEC SQL.
connect to 'LIM' as 'MYDB'
ENDEXEC.
EXEC SQL.
SET CONNECTION 'MYDB'
ENDEXEC.
EXEC SQL PERFORMING loop_output.
SELECT ID_NUMERIC, COMPONENT_NAME, COMUNA, RECORD_ID, STATUS, SAMPLED_DATE
into :datos from lims.SAMP_TEST_RESULT
where date > '01-09-2010'
ENDEXEC.
EXEC SQL.
disconnect 'MYDB'
ENDEXEC.
How can i get the data from that date?? If i delete the where statemet, the program works well, it takes 30 mins and show all the data, I just need the data from that date.
Any help
RegardsPlease refer the example in this link which deals with Oracle date format.
You can finnd a command DECODE which is used for date formats. If you have a look at whole theory then you will get an idea.
Link:[Bulk insert SQL command to transfer data from SAP to Oracle|http://sap.ittoolbox.com/groups/technical-functional/sap-dev/bulk-insert-sql-command-to-transfer-data-from-sap-to-oracle-cl_sql_connection-3780804] -
Any helpful materials or sample on how to get data from lotus in SAP?
I have some experience on get data from Biztalk (Microsoft Middleware). In that case, i could using "call FMxxxx DESTINATION rfc". the destination with type TCP/IP is created via SM59.
and how about lotus ?
thsI have some experience on get data from Biztalk (Microsoft Middleware). In that case, i could using "call FMxxxx DESTINATION rfc". the destination with type TCP/IP is created via SM59.
and how about lotus ?
ths -
How to get data from Oracle to SAP
Hi All,
I want to get data from Oracle to my internal table in SAP,
I worked on puting the data from SAP to Oracle, it's working fine...
Can anybody suggest the code for accessing from Oracle with 4 primary keys in oracle.
regards
manishhi
good
there is two things in sap open sql and native .if you ll use the open sql than you can access any database.
thanks
mrutyun -
How to Access data from SAP Content Server through SAP Portal
Hi Experts,
I want to aceess the data from SAP Content server through portal. Currently I am working on LSO business package. The SAP content server should work like Webdav as we uses KM as webdav.
I am trying to use this URL into the CMS address but it is not working
http://XXX-XXX-XXXX:1090/ConTentServer/ContentServer.dll?adminContRep&operation=docIdList&contRep=ZADGAS_LSO
Is there any other procedure for acceesing the DATA from SAP content server. ?
Thanks,
AhmadIf your Content Server is being used by DMS, then you can use the DMS Connector for KM. This connector allows all documents stored in DMS to be accessed in Portal as if they are stored in KM. For more info see this:
http://help.sap.com/saphelp_erp60_sp/helpdata/en/42/d289b446076bb2e10000000a1553f6/frameset.htm
Andrew -
How to get data from PDF form?
PDF forms can send data in url like GET or POST method. Is it possible to get data from url, like in PHP http://sever/file.php?item1=value1&item2=value2&item3=value3
In APEX url have specific construction and I don't know how to get value of items (1...3)
Please let me help to find simple method of geting data from URL.
Best Regards,
MarkThe APEX URL syntax is detailed here
http://download.oracle.com/docs/cd/E14373_01/appdev.32/e11838/concept.htm#BCEDJBEH
How to get it from PDF is another matter...
I'm working on an app that downloads PDFs with a Large amount of data as a blob, takes that blob and changes it to XML, then goes through the xml to validate each section of data and then add it into the schema that my apex app is referencing....
I didn't write the original code but I do know that it isn't a quick thing to implement and includes using some uploading some java jar files to your schema and writing some custom java code.
Someone else may be able to help with grabbing PDF data into the URL for the amounts of data you want to pass to apex.
Gus..
REWARDS: Please remember to mark helpful or correct posts on the forum, not just for my answers but for everyone!
Edited by: Gussay on Sep 21, 2009 5:52 PM -
Getting Data from SAP ECC & BI to Crystal Reports and then Broadcasting.
Hi,
I need to get the data from SAP ECC & BI to Crystal reports and then after formating data in Crystal reports, my requierment is to send via email (Broadcasting). Is there any option to Broadcast from Crystal reports?
I read Ingo Hilgefort blogs, but I need in detail steps such as to verify Integration Kit is installed or not and also how to create connections in between SAP ECC and Crystal. What are the Security setups(User IDs and Authorizations) involved?
What is best option for email/broadcasting for Crystal Reports?
Your help is appreciated.
Thanks.
SVK.Hi,
I would suggest you then start with the installation and user guide fr the SAP Integration Kit.
Ingo
Maybe you are looking for
-
I need the MPEG-2 Encoder Code for Premier Elements 3.0.2
I am trying to burn a DVD and all I need it that code. It asks me to copy the key code it supplies and follow the hyperlink on the same window. However when I follow the hyperlink the website says Activation for this version is no longer supported.
-
Does anyone here knows if it is possible to put a new line in a dateformat? I need to do this duo to layoutreasons. Apparently something like DD/MM/YY <br> HH24:MI:SS, doesn't work. Thanx. Barteld
-
Position Management Procedure--4001-60A
Dear All, I am trying to understand how the system is valuing the positions for a Fx Foreard Transactions.The Position Management Procedure is 4001.Step 1:Rate valuation 1000.Step2:Type 7-Swap Accrual Step 3:Type 8:Swap Valuation. Can body Explain me
-
Hi can anyone help here?I have an Audigy 2 ZS that worked fine in XP with powerdvd etc, for spdif output. In vista 64 I couldn't get any sound if i selected spdiff. I installed a codec pack and a windows update kb936225. My sound then worked fine. I
-
The application folder has a question mark on it and it will not open?
the application folder has a question mark on it and it will not open?