<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: section access using database connection in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/section-access-using-database-connection/m-p/1671028#M50734</link>
    <description>&lt;P&gt;Quick update - I was able to get the script to execute and working using the database method.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;section access;&lt;/P&gt;&lt;P&gt;LOAD upper("ACCESS") as ACCESS,&lt;BR /&gt;upper("USERID") as USERID,&lt;BR /&gt;upper(ACCESSID) as ACCESSID;&lt;BR /&gt;SQL SELECT "ACCESS",&lt;BR /&gt;"USERID",&lt;BR /&gt;ACCESSID&lt;BR /&gt;FROM etc&lt;/P&gt;&lt;P&gt;section application;&lt;/P&gt;&lt;P&gt;LOAD upper(ACCESSID) as ACCESSID,&lt;BR /&gt;ORGANIZATION as Organization;&lt;BR /&gt;SQL SELECT ACCESSID,&lt;BR /&gt;ORGANIZATION&lt;BR /&gt;FROM etc&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
    <pubDate>Thu, 30 Jan 2020 17:34:31 GMT</pubDate>
    <dc:creator>124psu</dc:creator>
    <dc:date>2020-01-30T17:34:31Z</dc:date>
    <item>
      <title>section access using database connection</title>
      <link>https://community.qlik.com/t5/App-Development/section-access-using-database-connection/m-p/1671015#M50731</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I am able to get the section access up and running using the inline method. I want to transition this over to a database method so that way I can control the users through the database instead going into the script and adding/deleting rows from the inline.&amp;nbsp;&lt;/P&gt;&lt;P&gt;Here is my working script for the "&lt;EM&gt;&lt;STRONG&gt;&lt;FONT color="#0000FF"&gt;IN LINE&lt;/FONT&gt;&lt;/STRONG&gt;&lt;/EM&gt;" method:&lt;/P&gt;&lt;P&gt;SECTION ACCESS;&lt;/P&gt;&lt;P&gt;LOAD * INLINE [&lt;/P&gt;&lt;P&gt;upper("access") as ACCESS,&lt;BR /&gt;upper("userid") as USERID,&lt;BR /&gt;upper("accessid") as ACCESSID&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;LOAD * INLINE [&lt;/P&gt;&lt;P&gt;ACCESS, USERID, ACCESSID&lt;BR /&gt;ADMIN, INTERNAL\SA_SCHEDULER, *,&lt;BR /&gt;ADMIN, ABC\124psu, *,&lt;BR /&gt;USER, ABC\124psu, M,&lt;BR /&gt;USER, ABC\124psu, A,&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;SECTION APPLICATION;&lt;/P&gt;&lt;P&gt;LOAD * INLINE [&lt;/P&gt;&lt;P&gt;ACCESSID, Organization&lt;/P&gt;&lt;P&gt;M, Marketing&lt;BR /&gt;A, Accounting&lt;BR /&gt;IT, IT&lt;BR /&gt;];&lt;/P&gt;&lt;P&gt;In this case, for testing purposes, I will only see data for Marketing and Accounting. And this is exactly what I want to achieve.&lt;/P&gt;&lt;P&gt;I've created 2 tables in my database to have the same column and values as the inline method above. When I bring these tables in, my script looks something like this ..&lt;/P&gt;&lt;P&gt;----------&lt;/P&gt;&lt;P&gt;section access;&lt;/P&gt;&lt;P&gt;LIB CONNECT TO 'demoDB(124psu)';&lt;/P&gt;&lt;P&gt;LOAD "ACCESS",&lt;BR /&gt;"USERID",&lt;BR /&gt;ACCESSID;&lt;BR /&gt;SQL SELECT "ACCESS",&lt;BR /&gt;"USERID",&lt;BR /&gt;ACCESSID&lt;BR /&gt;FROM "SAT"."USER_SECTION_ACCESS";&lt;/P&gt;&lt;P&gt;section application;&lt;/P&gt;&lt;P&gt;LOAD ACCESSID,&lt;BR /&gt;ORGANIZATION;&lt;BR /&gt;SQL SELECT ACCESSID,&lt;BR /&gt;ORGANIZATION&lt;BR /&gt;FROM "SAT"."USER_ORGANIZATION";&lt;/P&gt;&lt;P&gt;after executing the script I get this error message - "&lt;SPAN&gt;Access was denied after reload. Check that the user that reloads the script is included in the section access part of the script."&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN&gt;After some research, this usually stems from not including the internal scheduler and myself as an admin with an "*" but I have all those in place in my database tables.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;I expect this to work the same as the inline method since I have the same column and values as the inline method. What am I missing here?&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 03:24:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/section-access-using-database-connection/m-p/1671015#M50731</guid>
      <dc:creator>124psu</dc:creator>
      <dc:date>2024-11-16T03:24:16Z</dc:date>
    </item>
    <item>
      <title>Re: section access using database connection</title>
      <link>https://community.qlik.com/t5/App-Development/section-access-using-database-connection/m-p/1671028#M50734</link>
      <description>&lt;P&gt;Quick update - I was able to get the script to execute and working using the database method.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;section access;&lt;/P&gt;&lt;P&gt;LOAD upper("ACCESS") as ACCESS,&lt;BR /&gt;upper("USERID") as USERID,&lt;BR /&gt;upper(ACCESSID) as ACCESSID;&lt;BR /&gt;SQL SELECT "ACCESS",&lt;BR /&gt;"USERID",&lt;BR /&gt;ACCESSID&lt;BR /&gt;FROM etc&lt;/P&gt;&lt;P&gt;section application;&lt;/P&gt;&lt;P&gt;LOAD upper(ACCESSID) as ACCESSID,&lt;BR /&gt;ORGANIZATION as Organization;&lt;BR /&gt;SQL SELECT ACCESSID,&lt;BR /&gt;ORGANIZATION&lt;BR /&gt;FROM etc&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 30 Jan 2020 17:34:31 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/section-access-using-database-connection/m-p/1671028#M50734</guid>
      <dc:creator>124psu</dc:creator>
      <dc:date>2020-01-30T17:34:31Z</dc:date>
    </item>
  </channel>
</rss>

