Hello, pgAdmin team! I'm use pgadmin3 1.22.0.
So, I have 2 patches, that allows you to create Casts and Conversion. 1. Casts. - I create function integer_to_text(INTEGER value) that returns TEXT value; - I click on casts icon in pgadmin tree; - Next, I specify IN type (integer) and OUT type (text) - I open function combobox at this panel, but I don't find some functions (i.e. integer_to_text). So, the patch dlgCast.patch fix it. 2. Conversion. - I click on conversions in pgadmin tree; - Next, I specify conversion name as test_conversion; - On next panel I specify input and output encodings; - Function's combobox is not available, and I can't specify functions for execution and enter the names. So, the patch dkgConversion.patch fix it. Please, correct me if I'm not right. Thank you. -- Best regards, Dmitry Voronin
--- pgadmin3-1.22.0.orig/pgadmin/dlg/dlgCast.cpp +++ pgadmin3-1.22.0/pgadmin/dlg/dlgCast.cpp @@ -157,7 +157,7 @@ void dlgCast::OnChangeType(wxCommandEven wxT(" JOIN pg_namespace n ON n.oid=pronamespace\n") wxT(" WHERE proargtypes[0] = ") + GetTypeOid(cbSourceType->GetGuessedSelection()) - + wxT("\n AND proargtypes[1] = 0") + + wxT("\n AND pronargs = 1") wxT("\n AND prorettype = ") + GetTypeOid(cbTargetType->GetGuessedSelection());
--- a/pgadmin/dlg/dlgConversion.cpp +++ b/pgadmin/dlg/dlgConversion.cpp @@ -98,12 +98,7 @@ wxT(" FROM pg_proc p\n") wxT(" JOIN pg_namespace n ON n.oid=pronamespace") wxT("\n WHERE prorettype = ") + NumToStr(PGOID_TYPE_VOID) + - wxT("\n AND proargtypes[0] = ") + NumToStr(PGOID_TYPE_INT4) + - wxT("\n AND proargtypes[1] = ") + NumToStr(PGOID_TYPE_INT4) + - wxT("\n AND proargtypes[2] = ") + NumToStr(PGOID_TYPE_CSTRING) + - wxT("\n AND proargtypes[3] = ") + NumToStr(PGOID_TYPE_CSTRING) + - wxT("\n AND proargtypes[4] = ") + NumToStr(PGOID_TYPE_INT4) + - wxT("\n AND proargtypes[5] = 0"); + wxT("\n AND pronargs = 5"); pgSet *set = connection->ExecuteSet(qry); if (set)
-- Sent via pgadmin-support mailing list (pgadmin-support@postgresql.org) To make changes to your subscription: http://www.postgresql.org/mailpref/pgadmin-support