<?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: Getting a list of tables from Access Database in Discussions</title>
    <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9574#M9395</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Eric,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;just to be very clear and more complete, I then used this one:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"SELECT MSysNameMap.Name FROM MSysNameMap WHERE (MSysNameMap.Type = 1)"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for each row (List1 &amp;lt;&amp;lt; append(:Name))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--&amp;gt; works perfect!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you again.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 15 Oct 2014 13:28:03 GMT</pubDate>
    <dc:creator>cyrille_wagner</dc:creator>
    <dc:date>2014-10-15T13:28:03Z</dc:date>
    <item>
      <title>Getting a list of tables from Access Database</title>
      <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9570#M9391</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I'm trying to create a userform in the application builder, using native functionnalities and why not, JSL. I have the ideas and now I need to go on... &lt;SPAN __jive_emoticon_name="happy" __jive_macro_name="emoticon" class="jive_macro jive_macro_emoticon jive_emote" src="https://community.jmp.com/7.0.1.0/images/emoticons/happy.png"&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Firstable, does anyone know how I can get a list of all the tables in my Access Database? Of course that list would be on the userform.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your support, I'm starting manipulate JMP 11.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Sep 2014 07:10:03 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9570#M9391</guid>
      <dc:creator>cyrille_wagner</dc:creator>
      <dc:date>2014-09-18T07:10:03Z</dc:date>
    </item>
    <item>
      <title>Re: Getting a list of tables from Access Database</title>
      <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9571#M9392</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; &lt;A href="http://www.jmp.com/software/whitepapers/pdfs/102427_jmp_odbc.pdf" title="http://www.jmp.com/software/whitepapers/pdfs/102427_jmp_odbc.pdf"&gt;http://www.jmp.com/software/whitepapers/pdfs/102427_jmp_odbc.pdf&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I found this online and it offers step by step instructions for making a connection between a database and JMP and you can take it from there. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Uday&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Sep 2014 16:24:24 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9571#M9392</guid>
      <dc:creator>uday_guntupalli</dc:creator>
      <dc:date>2014-09-18T16:24:24Z</dc:date>
    </item>
    <item>
      <title>Re: Getting a list of tables from Access Database</title>
      <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9572#M9393</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you for your help.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This is a help file which allow you to connect to a database. I would like to create myself a list of all the table names available in my database.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;something like:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;x=list()&lt;/P&gt;&lt;P&gt;for each tabledef in my_database&lt;/P&gt;&lt;P&gt;x1&amp;lt;&amp;lt;get tabledef.name;&lt;/P&gt;&lt;P&gt;insert into (x, x1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;finally, it's a bit complicate. I would like to automatically create a SQL statement with what is stored in a JMP table. Almost done, I'm sure...&lt;SPAN __jive_emoticon_name="wink" __jive_macro_name="emoticon" class="jive_macro jive_macro_emoticon jive_emote" src="https://community.jmp.com/7.0.1.0/images/emoticons/wink.png"&gt;&lt;/SPAN&gt;. But the step before, I would like to allow users to easily store informations in that JMP table. He has to select in two lists, first the table in the database, then the caracteristic interresting him in this table. Then by clicking "OK" his choice is stored in the JMP table. I can compil then a SQL Statement to get datas from database for all the choices stored in that JMP table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope I am clear... ambitious?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 18 Sep 2014 17:32:03 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9572#M9393</guid>
      <dc:creator>cyrille_wagner</dc:creator>
      <dc:date>2014-09-18T17:32:03Z</dc:date>
    </item>
    <item>
      <title>Re: Getting a list of tables from Access Database</title>
      <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9573#M9394</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Most databases have system views that you can write SQL queries against to get lists of all the tables in the database that match a WHERE clause, etc.&amp;nbsp; I don't have MS Access, but doing some Google searches, something like this may work for you:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;SELECT MSysObjects.Name FROM MSysObjects WHERE (MSysObjects.Type = 1);&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You might also try "&lt;SPAN style="font-family: courier new,courier;"&gt;WHERE (MSysObjects.Type = 6)&lt;/SPAN&gt;" as the WHERE clause.&amp;nbsp; So you could use the JSL &lt;STRONG&gt;Open Database&lt;/STRONG&gt; function to submit that query to MS Access, which would give you a JMP data table with the Access table names in it, which you could then iterate through using &lt;STRONG&gt;For Each Row.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here are links to where I found the MS Access information:&lt;/P&gt;&lt;P&gt;&lt;A href="http://stackoverflow.com/questions/2076745/sql-statement-to-return-all-fields-from-all-tables" title="http://stackoverflow.com/questions/2076745/sql-statement-to-return-all-fields-from-all-tables"&gt;ms access - sql statement to return all fields from all tables - Stack Overflow&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;A href="http://www.perfectparadigm.com/tip001.html" title="http://www.perfectparadigm.com/tip001.html"&gt;Using MsysObjects&lt;/A&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;HTH,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Eric&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 19 Sep 2014 12:17:17 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9573#M9394</guid>
      <dc:creator>Eric_Hill</dc:creator>
      <dc:date>2014-09-19T12:17:17Z</dc:date>
    </item>
    <item>
      <title>Re: Getting a list of tables from Access Database</title>
      <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9574#M9395</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thank you Eric,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;just to be very clear and more complete, I then used this one:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;"SELECT MSysNameMap.Name FROM MSysNameMap WHERE (MSysNameMap.Type = 1)"&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and then:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for each row (List1 &amp;lt;&amp;lt; append(:Name))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;--&amp;gt; works perfect!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you again.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 15 Oct 2014 13:28:03 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/9574#M9395</guid>
      <dc:creator>cyrille_wagner</dc:creator>
      <dc:date>2014-10-15T13:28:03Z</dc:date>
    </item>
    <item>
      <title>Re: Getting a list of tables from Access Database</title>
      <link>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/342923#M59208</link>
      <description>&lt;OL&gt;&lt;LI&gt;Make a module in access and paste this code.&lt;/LI&gt;&lt;LI&gt;Run in debug window&lt;/LI&gt;&lt;LI&gt;Copy the generated table list in the immediate window.&amp;nbsp;&lt;/LI&gt;&lt;/OL&gt;&lt;PRE&gt;Public Sub List_fields_in_tables()
    Dim tdf As DAO.TableDef
    Dim fld As DAO.Field

    For Each tdf In CurrentDb.TableDefs
        If Left(tdf.Name, 4) &amp;lt;&amp;gt; "MSys" Then
            Debug.Print
            Debug.Print
            Debug.Print tdf.Name
            Debug.Print "----------------------------------------"
    
            
            For Each fld In tdf.Fields
                Debug.Print fld.Name &amp;amp; Space(20 - Len(fld.Name)) &amp;amp; fld.Size &amp;amp; Space(10 - Len(Str(fld.Size))) &amp;amp; FDataType(fld.Type)
        
            Next fld
        End If
    Next tdf

End Sub

Private Function FDataType(intType As Integer) As String

    Dim RetString As String
    
    Select Case intType
        Case 1
            RetString = "Boolean"
        Case 8
            RetString = "Date"
        Case 3
            RetString = "Integer"
            
        Case 7
            RetString = "Double"
        
        Case 10
            RetString = "String"
            
        Case 4
            RetString = "Long Integer"
        
        Case Else
            RetString = "Unknown"
            
    End Select
    
    FDataType = RetString

End Function

&lt;/PRE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&lt;span class="lia-inline-image-display-wrapper lia-image-align-inline" image-alt="screen shot.jpg" style="width: 999px;"&gt;&lt;img src="https://community.jmp.com/t5/image/serverpage/image-id/29032i9F92F0EBD9EAA82C/image-size/large?v=v2&amp;amp;px=999" role="button" title="screen shot.jpg" alt="screen shot.jpg" /&gt;&lt;/span&gt;&lt;/P&gt;</description>
      <pubDate>Fri, 18 Dec 2020 05:47:23 GMT</pubDate>
      <guid>https://community.jmp.com/t5/Discussions/Getting-a-list-of-tables-from-Access-Database/m-p/342923#M59208</guid>
      <dc:creator>jarryhead</dc:creator>
      <dc:date>2020-12-18T05:47:23Z</dc:date>
    </item>
  </channel>
</rss>

