Building SQL Dynamic WHERE Condition???


Author
Message
Edhy Rijo
E
StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)StrataFrame VIP (4.6K reputation)
Group: StrataFrame Users
Posts: 2.4K, Visits: 23K
Hi all,
I normally will build a MS-SQL Stored Procedure to get the data from all my reports, but in this case, I am working on a project that would have a gazillion filter conditions.  We are re-writing an application from a Visual FoxPro and the way this was handle was by using the old good VFP macro expansion technique by testing each conditions in the query or filter form and building the "WHERE - filter" string.

I can easily replicate that kind of logic using and SqlCommand object, but was wondering if there was a much better way to build this dynamic query?  I have not looking at the Browser Dialog source but I would imagine it uses a more generic object oriented approach to build the query and grab the data.

As always any suggestion is greatly appreciated.

Thanks!!!

Edhy Rijo

GO

Merge Selected

Merge into selected topic...



Merge into merge target...



Merge into a specific topic ID...





Similar Topics

Reading This Topic

Login

Explore
Messages
Mentions
Search