New to Data Dynamics-how to create schema?

Posted by: kiran3010p on 3 August 2017, 3:56 pm EST

  • Posted 3 August 2017, 3:56 pm EST

    Hello,



    I m new to this Data Dynamics.

    I m using SqlServer2005.

    with the fallowing command



    DataDynamics.Analysis.SchemaGenerator -c "Provider=SQLOLEDB;Initial Catalog=HA126_New;Data Source=sileru;User Id=sa;Password=lsi" -q "select id,first_name,last_name from patient;" -p "OLE DB" "c:\TEST.schema"



    in command prompt I come to know

    the creation of scema.

    But I m not able to create schema.

    Plz help me..



    Regards,

    Kiran P

  • Replied 3 August 2017, 3:56 pm EST

    Kiran,

    Do you get any error message while running the above command in DOS command prompt? I would suggest you to change the Provider to "SQLOLEDB" from "OLE DB" and then try to create the schema. Also take a look at this KB article.

    Regards,
    Aashish
  • Replied 3 August 2017, 3:56 pm EST

    IDbConnection dbcon = new OleDbConnection(constr);
    dbcon.Open();

    GrapeCity.ActiveAnalysis.DataSources.RdDataSource datasource = new GrapeCity.ActiveAnalysis.DataSources.RdDataSource();

    datasource.ConnectionType = GrapeCity.ActiveAnalysis.DataSources.ConnectionType.OleDb;
    datasource.ConnectionString = constr;
    datasource.QueryString = sql;

    System.IO.FileInfo myAutoSchema = new System.IO.FileInfo(@"C:\temp\MyAutoSchema.schema");
    GrapeCity.ActiveAnalysis.Schema.SchemaBuilder sb = GrapeCity.ActiveAnalysis.Schema.SchemaBuilder.AutoGenerate("The Schema Name", dbcon, sql);
    sb.SaveSchema( myAutoSchema );

    datasource.CustomSchemaFile = myAutoSchema.FullName;
    datasource.Connect();

Need extra support?

Upgrade your support plan and get personal unlimited phone support with our customer engagement team

Learn More

Forum Channels