How to execute dynamic query

Posts   
 
    
Prabha
User
Posts: 8
Joined: 28-Feb-2007
# Posted on: 28-Feb-2007 05:46:58   

Hi I am using LLBLGEN PRO 1.0 with VB.NET and database as SQL server. I want to know how to specify and execute a database view at runtime. Similerly i should able to specify the table name and columns at runtime.confused

daelmo avatar
daelmo
Support Team
Posts: 8245
Joined: 28-Nov-2005
# Posted on: 28-Feb-2007 07:00:47   

Apparently you would need Dynamic Lists. Please read the LLBLGen Pro v1.0.x Documentation at sections: Generated code - Adapter - Using views and lists - Usings dynamic lists (for Adapter) and Generated code - SelfServicing - Using views and lists - Usings dynamic lists (for SelfServicing)

Good luck!

David Elizondo | LLBLGen Support Team
Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 28-Feb-2007 07:09:08   

Please elaborate more.

And specify which LLBLGen Pro runtimeLibrary you are using. Guidelines: http://www.llblgen.com/TinyForum/Messages.aspx?ThreadID=7722

Also post the database view SQL code.

Prabha
User
Posts: 8
Joined: 28-Feb-2007
# Posted on: 28-Feb-2007 10:31:10   

LLBLGEN PRO Version 1.0.2005.1 Database Sql server 2000 Runtime version v1.1.4322

I have a list of views in the database. I want to specify(From frontend) the name of the view and the conditions only at runtime.

For example the view: Customer_Details_VW has the SQL

SELECT CUSTOMERCODE,CUSTOMERNAME,ADDRESS FROM TBL_CUSTOMER_DETAILS

For this view i will specify the name (Customer_Details_VW ) at runtime.So the code has to be in such a way that it should take the view name at runtime and execute.

Walaa avatar
Walaa
Support Team
Posts: 14995
Joined: 21-Aug-2005
# Posted on: 28-Feb-2007 14:47:30