Automate Tally Integration Tasks from PowerShell

Jerod Johnson
Jerod Johnson
Director, Technology Evangelism
Are you in search of a quick and easy way to access Tally data from PowerShell? This article demonstrates how to utilize the Tally Cmdlets for tasks like connecting to Tally data, automating operations, downloading data, and more.

The CData ADO.NET Provider for Tally is a standard ADO.NET Provider that make it easy to accomplish data cleansing, normalization, backup, and other integration tasks by enabling real-time access to Tally.

ADO.NET Provider

The ADO.NET Provider provides a SQL interface for Tally; this tutorial shows how to use the Provider to retrieve Tally data.

Once you have acquired the necessary connection properties, accessing Tally data in PowerShell can be enabled in three steps.

Set the following connection properties to connect to Tally Instance:

  • Url: Set this to the URL for your Tally instance. For example: http://localhost:9000.
  1. Load the provider's assembly:

    
    [Reflection.Assembly]::LoadFile("C:\Program Files\CData\CData ADO.NET Provider for Tally\lib\System.Data.CData.Tally.dll")
        
  2. Connect to Tally:

     
    $conn= New-Object System.Data.CData.Tally.TallyConnection("Url='http://localhost:9000/'")
    $conn.Open()
    
  3. Instantiate the TallyDataAdapter, execute an SQL query, and output the results:

    
    $sql="SELECT Name, Address from Company"
    
    $da= New-Object System.Data.CData.Tally.TallyDataAdapter($sql, $conn)
    $dt= New-Object System.Data.DataTable
    $da.Fill($dt)
    
    $dt.Rows | foreach {
    	Write-Host $_.name $_.address
    }
      

Ready to get started?

Download a free trial of the Tally Data Provider to get started:

 Download Now

Learn more:

Tally Icon Tally ADO.NET Provider

Rapidly create and deploy powerful .NET applications that integrate with Tally data including SalesOrders, PurchaseOrders, Accounts, and more!