Desktop version

Main > Forum > 1C:Enterprise Platform > 1C:Enterprise. Mobile platform > 1C for mobile connect to SQL SERVER

Forum

Search UsersRules
1C for mobile connect to SQL SERVER
#1
Just came
Points:: 0
Joined:: Sep 16, 2014

I don't know connect from 1C for mobile to SQL SERVER2008R2.

Code:

Code
   ConnectString = "Provider=SQLOLEDB;Data Source=10.43.10.231\SQLEXPRESS;Initial Catalog=WHD;User ID=sa;Password=123456";

   СonnectADO = New COMObject("ADODB.Connection");
   СonnectADO.ConnectionString = ConnectString;
   СonnectADO.Open();

   RS = New COMObject("ADODB.Recordset");
   Try
       RS.Open("SELECT * FR OM dbo.FLIGHT WH ERE EXPIMP = 'IMP' AND FLIDATE>'01/01/2013'", СonnectADO );
      Except
        Message ("Không thể kết nối tới CSDL");
        Return;
   EndTry;

Pls. help me.

Profile
#2
Guest
Points::
Joined::

Hello, Ha Thien Thach.

If I understood you correctly, you want to select some data from MS SQL database from the mobile device, right?

If so, you are unable to do this directly as you are not connected to it. You need to create a web service that will select data from the database in your main infobase. Then you could make requests to that web service from your mobile application.

Profile
Subscribe
Users browsing this topic (guests: 1, registered: 0, hidden: 0)



© 1C LLC. All rights reserved
1C Company respects the privacy of our customers and visitors
to our Web-site.