• Mindy Hreczuck (9/24/2012)


    Well I'll try to explain better...

    One solution would be to create a UDF instead of a view and pass in a user guid into that UDF which queries the account table based on the fund mapped to that user guid.

    This would require that all selects to the account table would be replaced by selects to the new account UDF, however all the procedures would need a new input parameter that accepts the current user guid to be passed into the UDF.

    This is about as close as we as gotten to a "clean" solution, but its not ideal since we need to modify the code and procedure for the new input param.

    If you post some DDL (CREATE TABLE statement) for the tables and some sample data (series of INSERT INTO statements) for each table, and the expected input/outputs maybe we could come up with something.