Progress ODBC and ACCESS -7748 error

por | 2 junio, 2011

Para corregir el tamaño de width de progress error column in table has value exceeding its max lenght

> run dbtool to fix widht sql

 

Nota: para hacer los cambios en sqlexp hay que entrar con el usuario sysprogress para tener autorización

 

para: Failure lock

ODBC configuration

Antes crear el usuario sysprogress con mpro

sqlexp sports2000-S 20000 -user sysprogress -password 123456

if you have access to the connection then you can call setTransactionIsolation (Connection.TRANSACTION_READ_UNCOMMITTED), but you normally set it using SQL as well… try to add this before the select statement of your report:

SET TRANSACTION ISOLATION LEVEL READ UNCOMMITTED;

 

Permisos

GRANT DBA TO SYSPROGRESS;

GRANT RESOURCE TO SYSPROGRESS;

SELECT * FROM SYSPROGRESS.SYSDBAUTH;

 

COMMIT;

PERMISOS TABLA:

GRANT SELECT ON PUB.TABLA TO SYSPROGRESS;

COMMIT;

SQLExplorer>SELECT * FROM SYSPROGRESS.SYSDBAUTH;
GRANTEE                          DBA_ACC RES_ACC
——————————– ——- ——-
SYSPROGRESS                      y       y

 

Title: “Reserved error -7748 when attempting to link a OpenEdge 10.1x Database table in Microsoft Access”

Symptoms:
# Reserved error -7748 when attempting to link a OpenEdge 10.1x Database table in Microsoft Access

Cause:
# Bug# OE00129491
# The problem is caused by an issue within Microsoft Access, not the DataDirect driver.

Microsoft Access 2000 calls SQLStatisticsW and SQLGetData for column number 10. Microsoft Access only asks for the data as a two-byte SQL_C_WCHAR, which is insufficient buffer to store the UCS2 character and the null terminator. Thus, the driver returns a warning, “01004 Data truncated”, and returns a null character to Microsoft Access. Microsoft Access then passes error -7748. Setting WorkArounds2=8192 as shown in this KBase’s fix causes Microsoft Access to not pass the error -7748.

Fixes:

Workaround:

WARNING – You should always make a backup of the Registry before making any changes.

To resolve this error, set WorkArounds2=8192 for the affected data source. This can be done by using the Registry Editor (RegEdit).

1. Run RegEdit

2. Locate the ODBC DSN in the Registry:

For a USER Data Source, go to HKEY_CURRENT_USER -> Software -> ODBC -> ODBC.INI -> YourDataSourceName

For a SYSTEM Data Source, go to HKEY_LOCAL_MACHINE -> Software -> ODBC -> ODBC.INI -> YourDataSourceName

For 32-bit applications (ODBC drivers) on 64-bit Windows, (MACHINE) Data Source, go to

HKEY_LOCAL_MACHINE -> Software -> Wow6432Node -> ODBC -> ODBC.INI -> YourDataSourceName

3. Click on the folder for your data source; from the menu choose:
Edit -> New -> String Value

4. Set the name of the new string value to be WorkArounds2

5. Double click on WorkArounds2 in the right hand panel; this will bring up a dialog box with a data value field

6. Change the data value to 8192 (The string value that must be added to Windows XP SP2 and Progress 10.1A02 is WorkArounds2=40960)

7. Click OK

8. Close RegEdit

 

Re: ODBC (Access Denied) ???

Hi,

Go to Progress SQL Explorer. Connect using user defined in you data administration.

Once connected, issue the following statement.

select * from sysprogress.sysdbauth

A list of DBA will be shown to you.

If none of DBA is in your Data Admin user list, create userid using one of the DBA.

Go back to Progress SQL Explorer and connect again using the DBA you have added in the Data Admin.

You should have sufficient priviledges to GRANT/REVOKE to any user.

ie.
GRANT DBA TO ‘newuser’;
GRANT SELECT ON pub.customer TO newuser;
COMMIT;

If you want to be able to access the Sync4J table from the Progress 4GL
all the tables have to be installed into the 'pub' schema area.

Modify $DLC/bin/java_env. Under the Linux section set
$JDKHOME=$JREHOME=$JAVAHOME appropriately and:

LD_LIBRARY_PATH=$JREHOME/lib/$ARCH:$JREHOME/jre/lib/$ARCH:$JREHOME/jre/lib/$ARCH/${THREADS_FLAG}_threads:$JREHOME/jre/bin:$JREHOME/jre/lib/$ARCH/$VMTYPE:$LD_LIBRARY_PATH
export LD_LIBRARY_PATH
PROLIBPATH=$LD_LIBRARY_PATH; export PROLIBPATH

if not already set right.

Next, your user needs to have the right priviledges for the 'pub' schema
area. This depends on
your set-up and situation but the following should always work.

Start the Progress database server with a service port (XXXX). Start a
Progress session, go into
the data dictionary and add users sysprogress with a password. Add a
database user if you do not
already have one. Exit your Progress session.

Start the Progress SQL Explorer.
sqlexp <yourdbname> -S XXXX -users sysprogress -password <your password>

SQLExplorer> grant dba to '<your db user name>';
SQLExplorer> commit;
SQLExplorer> quit

For security reasons you might now want to remove sysprogress as a user from
a 4GL session.

sqlexp <your db name> -S XXXX -users <your db user name> -password <your db
user's password> -infile drop_engine.ddl
sqlexp <your db name> -S XXXX -users <your db user name> -password <your db
user's password> -infile create_engine.ddl
sqlexp <your db name> -S XXXX -users <your db user name> -password <your db
user's password> -infile init_engine.sql
sqlexp <your db name> -S XXXX -users <your db user name> -password <your db
user's password> -infile init_schema.sql

The ddl and sql files needs to be modified.
- Current Schema needs to be set to 'pub'
- 'type' is a reserved word, so I renamed the 'type' column to 'device_type'
- Foreign Keys needs to be defined as the table is defined. This also
affects the order the tables can be defined.