Getting Fielddefs

Discussion of open issues, suggestions and bugs regarding SDAC (SQL Server Data Access Components) for Delphi, C++Builder, Lazarus (and FPC)
Post Reply
Guest

Getting Fielddefs

Post by Guest » Sun 06 Feb 2005 16:19

In dbGo you can assign a storedprocecure name to TADOStoredProc and go myAdoSP.FieldDefs.Update and it will obtain the list of fielddefs for the stored procedure. Is there an equivalent for SDAC as the ADO technique doesn't work.

Thanks in advance.

Richard

Ikar
Posts: 1693
Joined: Thu 28 Oct 2004 13:56

Post by Ikar » Mon 07 Feb 2005 09:54

This technique is applicable for SDAC. Please send us small complete sample and include script to create StoredProc

Ikar
Posts: 1693
Joined: Thu 28 Oct 2004 13:56

Post by Ikar » Wed 16 Feb 2005 12:10

The problem is in incorrect setting of StoredProc name. Instead of 'Ten Most Expensive Products' you should use 'Ten Most Expensive Products;1'

The easiest way to fill FieldDefs:

Code: Select all

 MSStoredProc1.Connection.Open;
 MSStoredProc1.StoredProcName := 'Ten Most Expensive Products;1';
 MSStoredProc1.FieldDefs.Update;

Post Reply