• Banner 201707

    INTRODUCING

    Fast, highly accurate platform for data mining and predictive analytics

  • Banner 201707

    INTRODUCING

    Fast, highly accurate platform for data mining and predictive analytics

Download Now Instant Evaluation
Get Price Quote

How to access data in relational databases via ODBC

*************
SPM 6.6 (TreeNet TN 6.4) or greater supports data access to Microsoft SQL Server, Oracle, MySQL and other RDMS via ODBC interface.

Since SQL Queries cannot be entered via standard Windows ODBC dialog data source selection dialog, one has to use command line to open data directly from SQL Server.

*************

Below is a brief description how to do this:
The syntax is:USE "odbc://odbc_connection_spec[;//sql_query]"

The quotes are required around the argument. sql_query parameter
is optional unless data source does contain multiple tables.
Below are some examples which connect to MS Access single-table
dataset and an MS SQL Database. Line wraps are for clarity.

Example 1. Connect to MS Access database myTable.mdb

USE "odbc://DSN=MS Access Database;DBQ=C:\Datasets\myTable.mdb
DefaultDir=C:\Datasets;DriverId=25;FIL=MS Access;
MaxBufferSize=2048;PageTimeout=5;UID=admin;"

Example 2. Connect to MS SQL Server database MyData,
table MyTable

USE "odbc://Driver={SQL Server Native Client 10.0};Server=localhost\
MSSQLSERVER_INSTANCENAME;Database=MyData;Trusted_Connection=yes;//
select top 100 * from [MyData].[dbo].[MyTable]"

Please note that you have to specify the columns explicitly. "Select *" queries are not supported.

Data can be saved to a database via ODBC. Use the following syntax:

SAVE "odbc://odbc_connection_spec[;//table_name]"

Quotes are required around the argument. must be the name
of the table and the connection string must determine the database.
Below are some examples which connect to MS Access single-table
dataset and an MS SQL Database. Line wraps are for clarity.

Example 1. Save to MS Access database myTable.mdb

SAVE "odbc://DSN=MS Access Database;DBQ=C:\Datasets\myTable.mdb
;DefaultDir=C:\Datasets;DriverId=25;FIL=MS Access;
MaxBufferSize=2048;PageTimeout=5;UID=admin;"

Example 2. Save to MS SQL Server database MyData, table MyTable

SAVE "odbc://Driver={SQL Server Native Client 10.0};Server=localhost\
MSSQLSERVER_INSTANCENAME;Database=MyData;Trusted_Connection=yes;//MyTable

If data table already exists the data will be appended to it.

[J#352:1602]

Tags: Frequently Asked Questions, FAQs, Support, SPM, Salford-Systems

  • SPM Version 8 Just Released!

    SPM Version 8 Just Released!

    NEW Salford Predictive Modeler software suite.

    Read more

  • Environmental Forecasting

    Environmental Forecasting

    Forecast the evolution of environmental outcomes using changes in habitat and climate as predictors.
  • Sports Analytics

    Sports Analytics

    "Discover the undisclosed predictors to successful athletic performance using modern decision trees."
  • Targeted Marketing

    Targeted Marketing

    Enabling you to get appropriate prospective customers more efficiently than any other marketing strategies.
  • Text Mining

    Text Mining

    Derive high-quality information from text to improve your understanding of behaviours and patterns.
  • Bioinformatics

    Bioinformatics

    "Increase your probability of solving formal and practical challenges arising from the analysis of biological data."
  • Bioinformatics

    Bioinformatics

    Learn how to make knowledge-driven decisions that can revolutionize your business performance.
  • Financial Services

    Financial Services

    Analyze your spending and financial investments to help influence a profitable future for your company
  • Industrial Optimisation

    Industrial Optimisation

    Overcome retail challenges and achieve new levels of predictive accuracy, profitability and reliability.
  • Music

    Music

    Predict musical score groupings, composers that complement each other and what song listeners prefer to listen to.
  • Retail Analytics

    Retail Analytics

    Make smarter decisions to help manage your business more effectively and efficiently.
  • SPM Version 8 Just Released!

    SPM Version 8 Just Released!

    Salford Systems' applications span every major industry and business function

    Read more

  • Environmental Forecasting

    Environmental Forecasting

    Forecast the evolution of environmental outcomes using changes in habitat and climate as predictors.
  • Sports Analytics

    Sports Analytics

    Discover the undisclosed predictors to successful athletic performance using modern decision trees.
  • Targeted Marketing

    Targeted Marketing

    Enabling you to get appropriate prospective customers more efficiently than any other marketing strategies.
  • Text Mining

    Text Mining

    Derive high-quality information from text to improve your understanding of behaviours and patterns.
  • Bioinformatics

    Bioinformatics

    Increase your probability of solving formal and practical challenges arising from the analysis of biological data.
  • Business

    Business

    Learn how to make knowledge-driven decisions that can revolutionize your business performance.
  • Financial Services

    Financial Services

    Analyze your spending and financial investments to help influence a profitable future for your company
  • Industrial Optimisation

    Industrial Optimisation

    Overcome retail challenges and achieve new levels of predictive accuracy, profitability and reliability.
  • Music

    Music

    Predict musical score groupings, composers that complement each other and what song listeners prefer to listen to.
  • Retail Analytics

    Retail Analytics

    Make smarter decisions to help manage your business more effectively and efficiently.

Get In Touch With Us

Request online support

Ph: 619-543-8880
9685 Via Excelencia, Suite 208, San Diego, CA 92126