PgSqlDatasource Select Parameter Source

PgSqlDatasource Select Parameter Source

Postby beopuppy » Fri 13 Mar 2009 00:32

Hi,

I use dotConnect for PostgreSQL version 4.0.16.0 in an ASP.NET environment. I would like to use the PgSqlDataSource control on my pages to create Master/Detail pages. I am able to bind the PgSqlDataSource to A GridView and select, update, insert, delete records just fine using the Gridview. Now I want to build a Master/Detail page, with a Master Grid bound to PgSqlDatasource 1, a Detailsview bound to PgSqlDatasource2. I want to enable the user to select a record in the GridView, then use the selected ID as parameter in PgSqlDatasource2.

The problem I have is the source for the select parameter for PgSqlDatasource2. If I would be using an SQLDatasource, I can specifiy the source of the select parameter. In this case, I would specify the GridView as the source control of the select parameter for the second datasource.

Can the PgSqlDatasource do something similar without having to bind the control in code to the select parameter value?
beopuppy
 
Posts: 2
Joined: Wed 17 Dec 2008 16:59
Location: Florida, USA

Postby Shalex » Mon 16 Mar 2009 15:19

Unfortunately, a control can be bound in the code only. E.g.:
Code: Select all
            ConnectionString="User Id=postgres;Password=postgres;Host=localhost;Database=postgres;Persist Security Info=True;Schema=public;"
        OldValuesParameterFormatString="Original_{0}"
        SelectCommand="select * from emp where deptno = :deptno">
       
                            PropertyName="SelectedValue" Type="Int32" />
       

   

Shalex
Devart Team
 
Posts: 7777
Joined: Thu 14 Aug 2008 12:44

PgSqlDatasource Select Parameter Source

Postby beopuppy » Mon 16 Mar 2009 16:12

Thanks Guys, this actually works just fine for me. I actually tested it out and it works great.
beopuppy
 
Posts: 2
Joined: Wed 17 Dec 2008 16:59
Location: Florida, USA


Return to dotConnect for PostgreSQL