[Spacewalk-list] Spacewalk 1.2 and postgresql sql syntax error

Michal Bruncko michal.bruncko at zssos.sk
Wed Dec 1 22:03:10 UTC 2010


Hi Michael,

thank you! that was very fast and perfect response! :)

thanks again

michal

On 1. 12. 2010 22:03, Michael Mraka wrote:
> Michal Bruncko wrote:
> % Hello,
> %
> % I'am receiving in periodical intervals following RHN Traceback about
> % sql syntax error.
> % I am using spacewalk 1.2 with posgresql db on fedora13. the problem
> % seems lies in /usr/lib/python2.6/site-packages/spacewalk/server/rhnVirtualization.py
> % but I do no what is wrong with that piece of SQL code.
> % Can anybody helps me with this?
> ...
> % SQL Error generated: ('syntax error at or near "name"\nLINE 8:
> % rvii.name             name,\n            ^\n', 0, '\n
>
> Hi Michal,
>
> postgresql doesn't like this column alias.
> I've fixed it in master, please try apply this patch
> http://git.fedorahosted.org/git/?p=spacewalk.git;a=commitdiff;h=22f55da385a604c5362949728feceb79bb476c19
>
> % SELECT\n                rvi.id           rvi_id,\n
> % rvi.host_system_id host_system_id,\n
> % rvi.virtual_system_id virtual_system_id,\n
> % rvi.confirmed         confirmed,\n               rvit.label
> % instance_type,\n rvii.name             name,\n
> % rvii.memory_size_k memory_size_k,\n                rvii.instance_id
> % instance_id,\n             rvii.vcpus            vcpus,\n
> % rvis.label          state\n            FROM\n rhnVirtualInstanceInfo
> % rvii,\n                rhnVirtualInstanceType rvit,\n
> % rhnVirtualInstanceState rvis,\n rhnVirtualInstance rvi\n
> % WHERE\n ((rvi.uuid=%(uuid)s and\n                  NOT EXISTS
> % (SELECT 1\n
> ...
>
> Regards,
>
> --
> Michael Mráka
> Satellite Engineering, Red Hat
>
> _______________________________________________
> Spacewalk-list mailing list
> Spacewalk-list at redhat.com
> https://www.redhat.com/mailman/listinfo/spacewalk-list

-- 
Ing. Michal Bruncko, CCNP
Linux systems and network administrator

Coupled school of business and services Ruzomberok
Slovak Republic




More information about the Spacewalk-list mailing list