PostgreSQL Tablespace Creation Problem

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • robintwos
    New Member
    • Nov 2007
    • 24

    PostgreSQL Tablespace Creation Problem

    I am not able to create a tablespace in PostgreSQL. what should i mention for Location field. What ever i mention, it gives me error saying Table Space location must be an absolute path.

    Thanks in Anticipation
  • rski
    Recognized Expert Contributor
    • Dec 2006
    • 700

    #2
    Originally posted by robintwos
    I am not able to create a tablespace in PostgreSQL. what should i mention for Location field. What ever i mention, it gives me error saying Table Space location must be an absolute path.

    Thanks in Anticipation
    Give a full path for the location of a tablespace

    Comment

    • robintwos
      New Member
      • Nov 2007
      • 24

      #3
      Originally posted by rski
      Give a full path for the location of a tablespace
      I tried giving full path also. like C:\tablespace. Still i am not successful

      Comment

      • rski
        Recognized Expert Contributor
        • Dec 2006
        • 700

        #4
        Originally posted by robintwos
        I tried giving full path also. like C:\tablespace. Still i am not successful
        show the full query you write

        Comment

        • robintwos
          New Member
          • Nov 2007
          • 24

          #5
          I could create the TS in postgres user. But i was trying to create another TS outside postgres user. which is failing.

          I believe i can't create TS in another user . But still was trying to confirm

          This was the SQL i used to create TS in postgres

          CREATE TABLESPACE "SampleTS"
          OWNER postgres
          LOCATION 'C:/Documents and Settings/postgres/SampleTS';

          And to create TS in another user , which is failing with an error saying "Could not set permissions on directory"

          CREATE TABLESPACE "SampleTS1"
          LOCATION 'C:/Documents and Settings/Administrator/SampleTS';

          Comment

          • rski
            Recognized Expert Contributor
            • Dec 2006
            • 700

            #6
            Originally posted by robintwos
            I could create the TS in postgres user. But i was trying to create another TS outside postgres user. which is failing.

            I believe i can't create TS in another user . But still was trying to confirm

            This was the SQL i used to create TS in postgres

            CREATE TABLESPACE "SampleTS"
            OWNER postgres
            LOCATION 'C:/Documents and Settings/postgres/SampleTS';

            And to create TS in another user , which is failing with an error saying "Could not set permissions on directory"

            CREATE TABLESPACE "SampleTS1"
            LOCATION 'C:/Documents and Settings/Administrator/SampleTS';

            User must have 'write right' to this directory.

            Comment

            Working...