SubSonic Forums
All Your Database Are Belong To Us

Excluding Views, Tables and SPs

Latest post 12-16-2008 3:32 PM by erock. 7 replies.
  • 07-23-2008 10:37 AM

    Excluding Views, Tables and SPs

    Can anyone tell me if you're able to exclude certain tables, views and SPs when it's generating code?

    I'd also like to know if you can stop the ability to access the tables directly and only enable use of stored procedures through subsonic?

     

    Thanks,

    Frankie 

  • 07-23-2008 3:05 PM In reply to

    Re: Excluding Views, Tables and SPs

    You can exclude or exclude tables from getting generated Try SubStage this will make it easier to work with the SubSonic options

     

    You can do includeTableList="^NOT_A_NAME_OF_A_TABLE$" this will make that SubSonic shouldn't generate any tables.

    If I am I because I am I, and You are You because You are You, then I am I, and you are you. But If I am I because You are You, and You are You because I am I, then I am not I and You are not You. -Rabbi of Kotzk

  • 12-16-2008 12:18 PM In reply to

    • erock
    • Top 500 Contributor
    • Joined on 12-16-2008
    • Posts 5

    Re: Excluding Views, Tables and SPs

    I'm trying to exclude all tables and views. I only want stored procs. Does anyone know how to do this?

     

    I've tried the above but it doesn't work. I've also tried excludeTableList="*" and "." and "[a-zA-Z]" and other reg expressions. No workie.

  • 12-16-2008 12:35 PM In reply to

    Re: Excluding Views, Tables and SPs

    maybe something like this 

    excludeTableList=".*"

    If I am I because I am I, and You are You because You are You, then I am I, and you are you. But If I am I because You are You, and You are You because I am I, then I am not I and You are not You. -Rabbi of Kotzk

  • 12-16-2008 2:22 PM In reply to

    • erock
    • Top 500 Contributor
    • Joined on 12-16-2008
    • Posts 5

    Re: Excluding Views, Tables and SPs

    no, that doesn't seem to work. thanks for the guess though.

  • 12-16-2008 2:36 PM In reply to

    • erock
    • Top 500 Contributor
    • Joined on 12-16-2008
    • Posts 5

    Re: Excluding Views, Tables and SPs

    is what i'm asking even supposed to be possible?

  • 12-16-2008 3:18 PM In reply to

    Re: Excluding Views, Tables and SPs

    Yes it should work

    Maybe try includeTableList="^NOT_A_NAME_OF_A_TABLE$"

    If I am I because I am I, and You are You because You are You, then I am I, and you are you. But If I am I because You are You, and You are You because I am I, then I am not I and You are not You. -Rabbi of Kotzk

  • 12-16-2008 3:32 PM In reply to

    • erock
    • Top 500 Contributor
    • Joined on 12-16-2008
    • Posts 5

    Re: Excluding Views, Tables and SPs

    sorry, i think i figured it out. putting something like 'sklfjaslf' in includeTableLisa works fine. I was using SubStage and noticing that when i hit the 'Invoke Providers' button, it was generating a 'Tables', 'Views', and 'Stored Procedures' subfolder. but when i went ahead and actually generated the code, it did exclude all tables, and did stored procedures only, which is what i wanted.


    hope that makes sense and helps somebody else.

    thanks for your help.

Page 1 of 1 (8 items) | RSS