Results 1 to 6 of 6
  1. #1
    Alex17 is offline Novice
    Windows 10 Access 2016
    Join Date
    Jun 2022
    Posts
    3

    Question Unexpected truncate Access MDB fields list



    I have Access .MDB file with 125 fields in one table. If I open this MDB I have seen all 125 fields. If I open the same table by OpenSource MDB Viewer I see data in 125 fields, but catalog of fields is truncated on 50 fields.

    Click image for larger version. 

Name:	ATI_06022022_202546-1.jpg 
Views:	19 
Size:	219.7 KB 
ID:	47963
    I need to open this MDB with my .NET Framework 4.8 program. I make this job by OleDb.OleDbConnection provider with this connection string
    Code:
    Provider=Microsoft.Jet.OLEDB.4.0;Data Source=G:\my.mdb
    Unexpectedly, I can see only first 50 fields of data. Any attempt to read by ADO.NET next field from 50 to 125 is failed.

    Code:
    Input6
     at System.Data.ProviderBase.FieldNameLookup.GetOrdinal(String fieldName)
     at System.Data.OleDb.OleDbDataReader.GetOrdinal(String name)
     at System.Data.OleDb.OleDbDataReader.get_Item(String name)
     at AtiConverter.Module1._Closure$__._Lambda$__12-4(OleDbDataReader X) in G:\Projects\ATI\Access\Converter1\Converter1\AccessRead.vb:line 63
     at AtiConverter.RawSqlQuery.RawSqlQuery[T](OleDbConnection Connection, String SqlQuery, Func`2 RowMapperFunc, Boolean NeedPrint) in G:\Projects\ATI\Access\Converter1\Converter1\RawSqlQuery.vb:line 23
    I'm use ordinary Win 11 with last update.

  2. #2
    June7's Avatar
    June7 is offline VIP
    Windows 10 Access 2010 32bit
    Join Date
    May 2011
    Location
    The Great Land
    Posts
    52,942
    How to attach file: http://www.accessforums.net/showthread.php?t=70301 To provide db: copy, remove confidential data, run compact & repair, zip w/Windows Compression.

  3. #3
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,981
    The 50 field limit may be a limitation of the MDB viewer you are using.
    What happens if you click the Add 50 Rows button again?

    Suggest you contact the developer (if the app is still available for download)
    But why use an MDB viewer rather than open it in Access (full version or runtime)?

    NOTE that there are no equivalent ACCDB viewers to the best of my knowledge
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

  4. #4
    Alex17 is offline Novice
    Windows 10 Access 2016
    Join Date
    Jun 2022
    Posts
    3
    Ha-ha, thank youisladogs.
    I'm idiot. If I click Add 50 row twice, I can see full list of columns.

    Click image for larger version. 

Name:	ATI_06052022_104903_.png 
Views:	12 
Size:	26.5 KB 
ID:	47975

    But my issue is deeper. MDB viewer is only small additional utilities to visualize data. I'm programmer and my job is read data from Access DB for further processing.
    I try to read by ordinary ADO.NET Logic. ADO NET Reader and While RDR.READ

    Click image for larger version. 

Name:	ATI_06052022_105357_1.png 
Views:	12 
Size:	147.8 KB 
ID:	47976

    Maybe, there is special operation when I need to read fields after 50 column. It's possible only 50 column is loading automatically and next 50 need to load by something special operation.
    I try to use JET provider and ACE provider, but I have no result - only 50 column is loaded.

  5. #5
    Alex17 is offline Novice
    Windows 10 Access 2016
    Join Date
    Jun 2022
    Posts
    3
    I'm sorry. It's a my program mistake. ACE provider CAN read more than 50 columns of data. Mistake was in my RowMapperFunction on the screen above, because my program has sophisticated logic and this RowMapping function was build by sophisticated and complex way. Additionally I have seen strange restriction of 50 columns in MDB viewer and go to forum instead going to my own code.

  6. #6
    isladogs's Avatar
    isladogs is offline MVP / VIP
    Windows 10 Office 365
    Join Date
    Jan 2014
    Location
    Somerset, UK
    Posts
    5,981
    Glad you have a solution!
    Colin, Access MVP, Website, email
    The more I learn, the more I know I don't know. When I don't know, I keep quiet!
    If I don't know that I don't know, I don't know whether to answer

Please reply to this thread with any new information or opinions.

Similar Threads

  1. Replies: 14
    Last Post: 11-15-2020, 11:56 AM
  2. Replies: 2
    Last Post: 09-25-2013, 12:40 PM
  3. Replies: 3
    Last Post: 12-26-2011, 10:45 AM
  4. Truncate text
    By jgelpi in forum Programming
    Replies: 3
    Last Post: 07-16-2009, 12:44 PM
  5. truncate (?) values
    By ridgeview80 in forum Access
    Replies: 3
    Last Post: 06-02-2009, 02:19 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Other Forums: Microsoft Office Forums