Home Datapipelines
New Blog Posts: Merging Reports - Part 1 and Part 2

Using a SQL statement instead of data pipeline

edited February 2008 in Datapipelines
Is it possible to define the data for a report or subreport through a SQL
query rather than having to assign a data pipeline?

Thanks,

David

Comments

  • edited February 2008
    Hi David,

    The idea of a DataPipeline is that it simply provides a connection from the
    report to dataset (or SQL Query). It is the mechanism RB uses to retrieve
    data from your database.

    What exactly are you trying to accomplish?

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited February 2008
    Nico,

    Thanks for your reply. I figured out in the data tab of the report how to
    create a query. In the data settings, I defined the connection to my SQL
    server database. The problem I have now is that I am prompted for the
    username/password when running the report. How can I get around this?

    BTW, I am testing the demo version of RB 10 Pro to see if it will allow me
    to easily create reports.

    Thanks,

    David
  • edited February 2008
    Hi David,

    Thanks for the clarification.

    Yes, creating queries in the data tab (DADE) is an easy and efficient way to
    connect a report to your data. Under the covers however, ReportBuilder is
    automatically creating the basic components needed (i.e. TQuery connected to
    a TDataSource connected to a TppDBPipeline). I would strongly suggest
    spending some time with the Developer's Guide located in the
    \RBuilder\Developer's Guide\... directory. This will give you an idea of
    what ReportBuilder is capable of as well as teach you the ins and outs of
    the product relatively quickly.

    To answer your question :).

    Since you are using SQL Server, I'm assuming you are connecting with a
    TADOConnection object. When building the ConnectionString, you need to be
    sure you fill in the password edti box and check the "Allow Saving Password"
    checkbox. Next, I believe you need to set the ADOConnection.LoginPrompt
    property to False.

    --
    Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com

    Best Regards,

    Nico Cizik
    Digital Metaphors
    http://www.digital-metaphors.com
  • edited February 2008
    Nico,

    I'm actually using the SDAC components from CoreLab to connect to SQL
    Server. I'm using Windows authentication and the login prompt is turned
    off. All of the queries in my app use this connection and I am never
    prompted for a login. I have browsed the developer's guide and didn't see
    anything about suppressing the login. Maybe someone in the group has had
    this problem before.

    Thanks,

    David

  • edited February 2008

    1. To use the Data workspace (DADE) you will need a plug-in that supports
    the SDAC components. The plug-in will register a new SessionType with RB.

    2. I looked at the Core Lab web page for the SDAC components. Looks like the
    connection component is called TMSConnection. Place a TMSConnection on the
    same form/datamodule as the report and report designer. Configure the
    TMSConnection component with the login params.

    3. Now set Designer.DataSettings.SessionType to reference the SDACSession.

    4. Configure the Designer.DataSettings.DatabaseName to reference the
    TMSConnection component.

    As a similar example that use ADO, check out RBuilder\Demos\EndUser
    Databases\SQL Server\ADO.



    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com

    "

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
  • edited February 2008
    Nard,

    Is this plugin available from Digital Metaphors? I don't see an SDAC plugin
    on the website.

    Thanks,

    David

  • edited February 2008

    We have a list of known plug-ins on our web site - see link below. I do not
    see one for SDAC. Try contacting Core Labs and inquire whether they have one
    available. The creation and maintenance of plug-ins is a community effort.
    The DADE plug-ins are quite boiler plate/cookie cutter - so creating new
    ones is simple. If one does not exists, perhaps you would be willing to
    spend a few hours creating one - we can help with any questions. Start by
    saving daADO.pas to a new name, such as daSDAC.pas. Then modify the class
    names and modify the internals to use the SDAC components rather than the
    ADO components.

    http://www.digital-metaphors.com/download/dade_plugins.html


    --
    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com

    Best regards,

    Nard Moseley
    Digital Metaphors
    www.digital-metaphors.com
This discussion has been closed.