Skip to main content
Greg Livingston
Participating Frequently
Sep 20, 2023 8:14 AM UTC

Universe Sql statement on Universe Files

Hi,

I am struggling to run SQL statements (UPDATE) on my universe files.  If we run the same command as a root user then the SQL command is successful.

This would indicate a permissions problem.

Does anyone know which files need to be given permissions to, in order to  allow SQL updates on normal Univere files ?

Thanks,

Greg



------------------------------
Greg Livingston
Universe Practice Lead
OUTsurance Insurance
Centurion GA ZA
------------------------------

    2 replies

    Neil Morris
    Rocketeer
    Sep 20, 2023 11:16 AM UTC

    Hi,

    I am struggling to run SQL statements (UPDATE) on my universe files.  If we run the same command as a root user then the SQL command is successful.

    This would indicate a permissions problem.

    Does anyone know which files need to be given permissions to, in order to  allow SQL updates on normal Univere files ?

    Thanks,

    Greg



    ------------------------------
    Greg Livingston
    Universe Practice Lead
    OUTsurance Insurance
    Centurion GA ZA
    ------------------------------

    Hi Greg,

    Do you get any kind of error message for the non-root user? 

    For a standard UV file, I think you should only need permissions on the file on which the UPDATE is being performed. 

    Although, the UPDATE process does run as a transaction so if TXMEM is exceeded, creating a "cache" file in uvtemp may be required.

    You could try using the 'strace' command as I believe you are running Linux. 

    For example,

    # strace uvsh "UPDATE FILE SET F1 = 'test';"

    and compare the results between the root user and non-root user to see where it is different. 

    Thanks,

    Neil



    ------------------------------
    Neil Morris
    Universe Advanced Technical Support
    Rocket Software
    ------------------------------
    Greg Livingston
    Participating Frequently
    Sep 21, 2023 6:52 AM UTC

    Hi Greg,

    Do you get any kind of error message for the non-root user? 

    For a standard UV file, I think you should only need permissions on the file on which the UPDATE is being performed. 

    Although, the UPDATE process does run as a transaction so if TXMEM is exceeded, creating a "cache" file in uvtemp may be required.

    You could try using the 'strace' command as I believe you are running Linux. 

    For example,

    # strace uvsh "UPDATE FILE SET F1 = 'test';"

    and compare the results between the root user and non-root user to see where it is different. 

    Thanks,

    Neil



    ------------------------------
    Neil Morris
    Universe Advanced Technical Support
    Rocket Software
    ------------------------------

    Hi Neil,

    The error I get is a segmention fault so difficult to debug from there.

    I am giving the "strace" a go.  That could point me in the correct direction.

    Thanks,

    Greg



    ------------------------------
    Greg Livingston
    Universe Practice Lead
    OUTsurance Insurance
    Centurion GA ZA
    ------------------------------