Results 1 to 4 of 4
  1. #1
    Lounger
    Join Date
    Sep 2002
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    cube from txt file (VB 6.0)

    I wish to create a cube file directly from a text file programmatically and not through Excel.

    I have created a dsn / schema.ini file for the text file and I wish to use this dsn as OLE DB provider for OLAP in MDX to create cube file . However I don't know how to write the connection string for such an MDX .

    Thanks in advance.

  2. #2
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: cube from txt file (VB 6.0)

    I think I understood about half of that...

    A DSN is a reference to an ODBC connection. To use an ODBC connection via OLE DB, you use the MSDASQL provider. For example:

    myConnection.ConnectionString = "Provider=MSDASQL;DSN=myCube"

    If you want to use a "native" OLE DB provider, you use similar details as you enter in the Data Sources dialog, but the syntax for the connection string will depend to some extent on the requirements of that particular provider.

    Does this get you a bit further along the path?

  3. #3
    Lounger
    Join Date
    Sep 2002
    Posts
    29
    Thanks
    0
    Thanked 0 Times in 0 Posts

    Re: cube from txt file (VB 6.0)

    msdasql does not come by default in my project/references list . I check this file in system and try to add the same through Browse but without success . I am using OS 98 with Office XP.

    We are able to create generic dsn / schema ini files / dqy files . What I need is to create following directly from a TXT file .

    1. Cube file (.cub)
    2. Office data connection file (odc).

    Microsoft Excel pivot chart object and Microsoft query allows u to create this files. However I wish to do the same through VB program .We do not have any SQL server. There are 2 options.

    1. I use ADOMD control and use create cube/insert into methods to create local cube. I think the syntax you provided is correct but I could not test this.
    2. I use the createcubefile method of MS excel on a pivot chart object. However that also does not work (some general error)

    Has anybody worked on this. Any guidance will be very much helpful.

  4. #4
    Super Moderator jscher2000's Avatar
    Join Date
    Feb 2001
    Location
    Silicon Valley, USA
    Posts
    23,112
    Thanks
    5
    Thanked 93 Times in 89 Posts

    Re: cube from txt file (VB 6.0)

    > msdasql does not come by default in my project/references list

    msdasql is an ADODB provider, so if you have ActiveX Data Objects in your project references, that should be all you need.

    As for how the cube stuff works, I have no experience with that part.

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •