void dlgIndexBase::OnSelectComboCol(wxCommandEvent &ev)
{
    if (cbType)
    {
        if (cbType->GetValue().Length() > 0)
        {
            cbOpClass->Clear();

            wxString sql = wxT("SELECT opcname FROM pg_opclass ");
            sql+= wxT("WHERE opcintype=");
            sql+= NumToStr(cbColumns->GetOIDKey(cbColumns->GetCurrentSelection()));
            sql+= wxT("AND opcmethod=") + cbType->GetStringKey(cbType->GetCurrentSelection())
                + wxT(" AND NOT opcdefault")
                + wxT(" ORDER BY 1");
            pgSet *set=connection->ExecuteSet(sql);
            if (set)
            {
                while (!set->Eof())
                {
                    cbOpClass->Append(set->GetVal(0));
                    set->MoveNext();
                }
                delete set;
            }
        }
    }

    OnSelectCol();
}
Ejemplo n.º 2
0
void dlgIndexBase::OnSelectComboCol(wxCommandEvent &ev)
{
	if (cbType)
	{
		wxString method = wxEmptyString;

		if (cbType->GetValue().Length() == 0)
		{
			method = cbType->GetStringKey(1);
		}
		else
		{
			method = cbType->GetStringKey(cbType->GetCurrentSelection());
		}

		cbOpClass->Clear();

		wxString sql = wxT("SELECT opcname FROM pg_opclass ")
		               wxT("WHERE opcmethod=") + method +
		               wxT(" AND NOT opcdefault")
		               wxT(" ORDER BY 1");
		pgSet *set = connection->ExecuteSet(sql);
		if (set)
		{
			while (!set->Eof())
			{
				cbOpClass->Append(set->GetVal(0));
				set->MoveNext();
			}
			delete set;
		}
	}

	OnSelectCol();
}
Ejemplo n.º 3
0
void dlgTrigger::OnSelectComboCol(wxCommandEvent &ev)
{
	OnSelectCol();
}
Ejemplo n.º 4
0
void dlgTrigger::OnSelectListCol(wxListEvent &ev)
{
	OnSelectCol();
}
void dlgIndexBase::OnSelectListCol(wxListEvent &ev)
{
    OnSelectCol();
}